summaryrefslogtreecommitdiffstats
path: root/Modules/clinic
diff options
context:
space:
mode:
authorMax Bachmann <oss@maxbachmann.de>2023-03-09 21:09:12 (GMT)
committerGitHub <noreply@github.com>2023-03-09 21:09:12 (GMT)
commitc6858d1e7f4cd3184d5ddea4025ad5dfc7596546 (patch)
tree6c5261397eca871567bb29b31cfe02c92f6d3b58 /Modules/clinic
parentca066bdbed85094a9c4d9930823ce3587807db48 (diff)
downloadcpython-c6858d1e7f4cd3184d5ddea4025ad5dfc7596546.zip
cpython-c6858d1e7f4cd3184d5ddea4025ad5dfc7596546.tar.gz
cpython-c6858d1e7f4cd3184d5ddea4025ad5dfc7596546.tar.bz2
gh-102255: Improve build support for Windows API partitions (GH-102256)
Add `MS_WINDOWS_DESKTOP`, `MS_WINDOWS_APPS`, `MS_WINDOWS_SYSTEM` and `MS_WINDOWS_GAMES` preprocessor definitions to allow switching off functionality missing from particular API partitions ("partitions" are used in Windows to identify overlapping subsets of APIs). CPython only officially supports `MS_WINDOWS_DESKTOP` and `MS_WINDOWS_SYSTEM` (APPS is included by normal desktop builds, but APPS without DESKTOP is not covered). Other configurations are a convenience for people building their own runtimes. `MS_WINDOWS_GAMES` is for the Xbox subset of the Windows API, which is also available on client OS, but is restricted compared to `MS_WINDOWS_DESKTOP`. These restrictions may change over time, as they relate to the build headers rather than the OS support, and so we assume that Xbox builds will use the latest available version of the GDK.
Diffstat (limited to 'Modules/clinic')
-rw-r--r--Modules/clinic/posixmodule.c.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/Modules/clinic/posixmodule.c.h b/Modules/clinic/posixmodule.c.h
index dcd25c2..6565f8d 100644
--- a/Modules/clinic/posixmodule.c.h
+++ b/Modules/clinic/posixmodule.c.h
@@ -10988,7 +10988,7 @@ exit:
#endif /* defined(HAVE_GETRANDOM_SYSCALL) */
-#if defined(MS_WINDOWS)
+#if (defined(MS_WINDOWS_DESKTOP) || defined(MS_WINDOWS_APP) || defined(MS_WINDOWS_SYSTEM))
PyDoc_STRVAR(os__add_dll_directory__doc__,
"_add_dll_directory($module, /, path)\n"
@@ -11057,9 +11057,9 @@ exit:
return return_value;
}
-#endif /* defined(MS_WINDOWS) */
+#endif /* (defined(MS_WINDOWS_DESKTOP) || defined(MS_WINDOWS_APP) || defined(MS_WINDOWS_SYSTEM)) */
-#if defined(MS_WINDOWS)
+#if (defined(MS_WINDOWS_DESKTOP) || defined(MS_WINDOWS_APP) || defined(MS_WINDOWS_SYSTEM))
PyDoc_STRVAR(os__remove_dll_directory__doc__,
"_remove_dll_directory($module, /, cookie)\n"
@@ -11120,7 +11120,7 @@ exit:
return return_value;
}
-#endif /* defined(MS_WINDOWS) */
+#endif /* (defined(MS_WINDOWS_DESKTOP) || defined(MS_WINDOWS_APP) || defined(MS_WINDOWS_SYSTEM)) */
#if (defined(WIFEXITED) || defined(MS_WINDOWS))
@@ -11796,4 +11796,4 @@ exit:
#ifndef OS_WAITSTATUS_TO_EXITCODE_METHODDEF
#define OS_WAITSTATUS_TO_EXITCODE_METHODDEF
#endif /* !defined(OS_WAITSTATUS_TO_EXITCODE_METHODDEF) */
-/*[clinic end generated code: output=1b0eb6a76b1a0e28 input=a9049054013a1b77]*/
+/*[clinic end generated code: output=9495478e51701b8a input=a9049054013a1b77]*/