diff options
author | Christian Heimes <christian@python.org> | 2022-04-23 07:52:16 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-23 07:52:16 (GMT) |
commit | 9b5ca5405e5a2786b5b3acc0de578f80f8dc9e36 (patch) | |
tree | 2b9bbe7cbd0d10c15a459f37c91e17ac27e97dff /configure.ac | |
parent | 0daa99f68b7b9f02b37a2f34508f33ae66d95fc4 (diff) | |
download | cpython-9b5ca5405e5a2786b5b3acc0de578f80f8dc9e36.zip cpython-9b5ca5405e5a2786b5b3acc0de578f80f8dc9e36.tar.gz cpython-9b5ca5405e5a2786b5b3acc0de578f80f8dc9e36.tar.bz2 |
gh-84461: Add sys._emscripten_info, improve docs and build (gh-91781)
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 81 |
1 files changed, 27 insertions, 54 deletions
diff --git a/configure.ac b/configure.ac index 9b60b98..82211f4 100644 --- a/configure.ac +++ b/configure.ac @@ -2954,6 +2954,9 @@ then BLDSHARED="$LDSHARED" fi ;; + Emscripten|WASI) + LDSHARED='$(CC) -shared' + LDCXXSHARED='$(CXX) -shared';; Linux*|GNU*|QNX*|VxWorks*|Haiku*) LDSHARED='$(CC) -shared' LDCXXSHARED='$(CXX) -shared';; @@ -6585,43 +6588,19 @@ AC_DEFUN([PY_STDLIB_MOD_SET_NA], [ dnl Modules that are not available on some platforms dnl AIX has shadow passwords, but access is not via getspent() dnl VxWorks does not provide crypt() function -AS_CASE([$ac_sys_system/$ac_sys_emscripten_target], - [AIX/*], [PY_STDLIB_MOD_SET_NA([_scproxy], [spwd])], - [VxWorks*/*], [PY_STDLIB_MOD_SET_NA([_scproxy], [_crypt], [termios], [grp])], - [Darwin/*], [PY_STDLIB_MOD_SET_NA([ossaudiodev], [spwd])], - [CYGWIN*/*], [PY_STDLIB_MOD_SET_NA([_scproxy], [nis])], - [QNX*/*], [PY_STDLIB_MOD_SET_NA([_scproxy], [nis])], - [FreeBSD*/*], [PY_STDLIB_MOD_SET_NA([_scproxy], [spwd])], - [Emscripten/browser*], [ - PY_STDLIB_MOD_SET_NA( - [_ctypes], - [_curses], - [_curses_panel], - [_dbm], - [_gdbm], - [_multiprocessing], - [_posixshmem], - [_posixsubprocess], - [_scproxy], - [_tkinter], - [_xxsubinterpreters], - [fcntl], - [grp], - [nis], - [ossaudiodev], - [pwd], - [resource], - [readline], - [spwd], - [syslog], - [termios], - ) - ], - dnl Some modules like _posixsubprocess do not work. We build them anyway - dnl so imports in tests do not fail. - [Emscripten/node*], [ +AS_CASE([$ac_sys_system], + [AIX], [PY_STDLIB_MOD_SET_NA([_scproxy], [spwd])], + [VxWorks*], [PY_STDLIB_MOD_SET_NA([_scproxy], [_crypt], [termios], [grp])], + [Darwin], [PY_STDLIB_MOD_SET_NA([ossaudiodev], [spwd])], + [CYGWIN*], [PY_STDLIB_MOD_SET_NA([_scproxy], [nis])], + [QNX*], [PY_STDLIB_MOD_SET_NA([_scproxy], [nis])], + [FreeBSD*], [PY_STDLIB_MOD_SET_NA([_scproxy], [spwd])], + [Emscripten|WASI], [ + dnl subprocess and multiprocessing are not supported (no fork syscall). + dnl curses and tkinter user interface are not available. + dnl dbm and gdbm aren't available, too. + dnl Emscripten and WASI provide only stubs for pwd, grp APIs. PY_STDLIB_MOD_SET_NA( - [_ctypes], [_curses], [_curses_panel], [_dbm], @@ -6639,24 +6618,18 @@ AS_CASE([$ac_sys_system/$ac_sys_emscripten_target], [spwd], [syslog], ) - ], - [WASI/*], [ - PY_STDLIB_MOD_SET_NA( - [_ctypes], - [_ctypes_test], - [_curses], - [_curses_panel], - [_dbm], - [_gdbm], - [_scproxy], - [_tkinter], - [_xxsubinterpreters], - [grp], - [nis], - [ossaudiodev], - [pwd], - [spwd], - [syslog], + AS_CASE([$ac_sys_system/$ac_sys_emscripten_target], + [Emscripten/browser*], [ + dnl These modules are not particularly useful in browsers. + PY_STDLIB_MOD_SET_NA( + [fcntl], + [resource], + [readline], + [termios], + ) + ], + [Emscripten/node*], [], + [WASI/*], [] ) ], [PY_STDLIB_MOD_SET_NA([_scproxy])] |