summaryrefslogtreecommitdiffstats
path: root/configure
Commit message (Collapse)AuthorAgeFilesLines
* bpo-41100: Support macOS 11 and Apple Silicon (GH-22855)Ronald Oussoren2020-11-081-6/+39
| | | | | | | | | | | Co-authored-by: Lawrence D’Anna <lawrence_danna@apple.com> * Add support for macOS 11 and Apple Silicon (aka arm64) As a side effect of this work use the system copy of libffi on macOS, and remove the vendored copy * Support building on recent versions of macOS while deploying to older versions This allows building installers on macOS 11 while still supporting macOS 10.9.
* bpo-35823: subprocess: Use vfork() instead of fork() on Linux when safe ↵Alexey Izbyshev2020-10-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (GH-11671) * bpo-35823: subprocess: Use vfork() instead of fork() on Linux when safe When used to run a new executable image, fork() is not a good choice for process creation, especially if the parent has a large working set: fork() needs to copy page tables, which is slow, and may fail on systems where overcommit is disabled, despite that the child is not going to touch most of its address space. Currently, subprocess is capable of using posix_spawn() instead, which normally provides much better performance. However, posix_spawn() does not support many of child setup operations exposed by subprocess.Popen(). Most notably, it's not possible to express `close_fds=True`, which happens to be the default, via posix_spawn(). As a result, most users can't benefit from faster process creation, at least not without changing their code. However, Linux provides vfork() system call, which creates a new process without copying the address space of the parent, and which is actually used by C libraries to efficiently implement posix_spawn(). Due to sharing of the address space and even the stack with the parent, extreme care is required to use vfork(). At least the following restrictions must hold: * No signal handlers must execute in the child process. Otherwise, they might clobber memory shared with the parent, potentially confusing it. * Any library function called after vfork() in the child must be async-signal-safe (as for fork()), but it must also not interact with any library state in a way that might break due to address space sharing and/or lack of any preparations performed by libraries on normal fork(). POSIX.1 permits to call only execve() and _exit(), and later revisions remove vfork() specification entirely. In practice, however, almost all operations needed by subprocess.Popen() can be safely implemented on Linux. * Due to sharing of the stack with the parent, the child must be careful not to clobber local variables that are alive across vfork() call. Compilers are normally aware of this and take extra care with vfork() (and setjmp(), which has a similar problem). * In case the parent is privileged, special attention must be paid to vfork() use, because sharing an address space across different privilege domains is insecure[1]. This patch adds support for using vfork() instead of fork() on Linux when it's possible to do safely given the above. In particular: * vfork() is not used if credential switch is requested. The reverse case (simple subprocess.Popen() but another application thread switches credentials concurrently) is not possible for pure-Python apps because subprocess.Popen() and functions like os.setuid() are mutually excluded via GIL. We might also consider to add a way to opt-out of vfork() (and posix_spawn() on platforms where it might be implemented via vfork()) in a future PR. * vfork() is not used if `preexec_fn != None`. With this change, subprocess will still use posix_spawn() if possible, but will fallback to vfork() on Linux in most cases, and, failing that, to fork(). [1] https://ewontfix.com/7 Co-authored-by: Gregory P. Smith [Google LLC] <gps@google.com>
* bpo-38980: Only apply -fno-semantic-interposition if available (GH-22892)Petr Viktorin2020-10-221-0/+36
|
* bpo-38980: Add -fno-semantic-interposition when building with optimizations ↵Pablo Galindo2020-10-211-0/+8
| | | | (GH-22862)
* closes bpo-42030: Remove legacy AIX dynload support (GH-22717)Kevin Adler2020-10-161-6/+0
| | | | | | | | Since c19c5a6, AIX builds have defaulted to using dynload_shlib over dynload_aix when dlopen is available. This function has been available since AIX 4.3, which went out of support in 2003, the same year the previously referenced commit was made. It has been nearly 20 years since a version of AIX has been supported which has not used dynload_shlib so there's no reason to keep this legacy code around.
* bpo-40423: Optimization: use close_range(2) if available (GH-22651)Kyle Evans2020-10-111-2/+2
| | | | | | | close_range(2) should be preferred at all times if it's available, otherwise we'll use closefrom(2) if available with a fallback to fdwalk(3) or plain old loop over fd range in order of most efficient to least. [note that this version does check for ENOSYS, but currently ignores all other errors] Automerge-Triggered-By: @pablogsal
* bpo-41721: Add xlc options (GH-22096)Stefan Krah2020-09-041-1/+4
|
* bpo-19521: Fix parallel build race condition on AIX (GH-21997)Stefan Krah2020-08-291-9/+22
| | | | Patch by Michael Haubenwallner.
* bpo-41340: Removed fallback implementation for strdup (GH-21634)wasiher2020-07-271-13/+0
|
* BPO-41100: Support macOS 11 when building (GH-21113)Ronald Oussoren2020-06-251-1/+1
|
* bpo-40939: run autoreconf to fix configure{,.ac} disparity (GH-21152)Ned Deily2020-06-251-1/+1
|
* bpo-40939: Remove the old parser (Part 2) (GH-21005)Lysandros Nikolaou2020-06-201-1/+1
| | | Remove some remaining files and Makefile targets for the old parser
* bpo-40684: Fix make install for platlibdir=lib64 (GH-20736)Victor Stinner2020-06-091-1/+7
| | | | | | "make install" now uses the PLATLIBDIR variable for the destination lib-dynload/ directory when ./configure --with-platlibdir is used. Update --with-platlibdir comment in configure.
* Python 3.10.0a0 (GH-20198)Pablo Galindo2020-05-191-10/+10
|
* Revert "bpo-26317: Support OBJC and OBJCXX configure command line variables ↵Ned Deily2020-05-181-611/+0
| | | | | | | | | (GH-20176)" (GH-20182) This reverts commit 0da546665075aefbb476e192ed64122d340164f4. The commit is causing make failures on a FreeBSD buildbot. Due to the imminent 3.9.0b1 cutoff, revert this commit for now pending further investigation.
* bpo-26317: Support OBJC and OBJCXX configure command line variables (GH-20176)Ned Deily2020-05-181-0/+611
| | | | | | Add support to the configure script for OBJC and OBJCXX command line options so that the macOS builds can use the clang compiler for the macOS-specific Objective C source files. This allows third-party compilers, like GNU gcc, to be used to build the rest of the project since some of the Objective C system header files are not compilable by GNU gcc. Co-authored-by: Jeffrey Kintscher <websurfer@surf2c.net> Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-40503: PEP 615: Tests and implementation for zoneinfo (GH-19909)Paul Ganssle2020-05-161-0/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the initial implementation of PEP 615, the zoneinfo module, ported from the standalone reference implementation (see https://www.python.org/dev/peps/pep-0615/#reference-implementation for a link, which has a more detailed commit history). This includes (hopefully) all functional elements described in the PEP, but documentation is found in a separate PR. This includes: 1. A pure python implementation of the ZoneInfo class 2. A C accelerated implementation of the ZoneInfo class 3. Tests with 100% branch coverage for the Python code (though C code coverage is less than 100%). 4. A compile-time configuration option on Linux (though not on Windows) Differences from the reference implementation: - The module is arranged slightly differently: the accelerated module is `_zoneinfo` rather than `zoneinfo._czoneinfo`, which also necessitates some changes in the test support function. (Suggested by Victor Stinner and Steve Dower.) - The tests are arranged slightly differently and do not include the property tests. The tests live at test/test_zoneinfo/test_zoneinfo.py rather than test/test_zoneinfo.py or test/test_zoneinfo/__init__.py because we may do some refactoring in the future that would likely require this separation anyway; we may: - include the property tests - automatically run all the tests against both pure Python and C, rather than manually constructing C and Python test classes (similar to the way this works with test_datetime.py, which generates C and Python test cases from datetimetester.py). - This includes a compile-time configuration option on Linux (though not on Windows); added with much help from Thomas Wouters. - Integration into the CPython build system is obviously different from building a standalone zoneinfo module wheel. - This includes configuration to install the tzdata package as part of CI, though only on the coverage jobs. Introducing a PyPI dependency as part of the CI build was controversial, and this is seen as less of a major change, since the coverage jobs already depend on pip and PyPI. Additional changes that were introduced as part of this PR, most / all of which were backported to the reference implementation: - Fixed reference and memory leaks With much debugging help from Pablo Galindo - Added smoke tests ensuring that the C and Python modules are built The import machinery can be somewhat fragile, and the "seamlessly falls back to pure Python" nature of this module makes it so that a problem building the C extension or a failure to import the pure Python version might easily go unnoticed. - Adjustments to zoneinfo.__dir__ Suggested by Petr Viktorin. - Slight refactorings as suggested by Steve Dower. - Removed unnecessary if check on std_abbr Discovered this because of a missing line in branch coverage.
* bpo-40637: Add option to disable builtin hashes (GH-20121)Christian Heimes2020-05-151-0/+42
| | | | | Signed-off-by: Christian Heimes <christian@python.org> Automerge-Triggered-By: @tiran
* bpo-40514: Add --with-experimental-isolated-subinterpreters (GH-19926)Victor Stinner2020-05-051-0/+28
| | | | | | | Add --with-experimental-isolated-subinterpreters build option to configure: better isolate subinterpreters, experimental build mode. When used, force the usage of the libc malloc() memory allocator, since pymalloc relies on the unique global interpreter lock (GIL).
* bpo-40291: Add support for CAN_J1939 sockets (GH-19538)karl ding2020-04-291-2/+2
| | | | Add support for CAN_J1939 sockets that wrap SAE J1939 protocol functionality provided by Linux 5.4+ kernels.
* bpo-40334: Fix builds outside the source directory and regenerate autoconf ↵Pablo Galindo2020-04-231-1/+1
| | | | files (GH-19667)
* bpo-25780: Expose CAN_RAW_JOIN_FILTERS in the socket module (GH-19190)Zackery Spytz2020-04-091-0/+30
| | | Co-Authored-By: Stefan Tatschner <stefan@rumpelsepp.org>
* bpo-38527: fix configure script for Solaris (GH-16845)Arnon Yaari2020-04-011-2/+2
| | | | | On Solaris, the regular "grep" command may be an old version that fails to search a binary file. We need to use the correct command (ggrep, in our case), which is found by the configure script earlier. Automerge-Triggered-By: @pablogsal
* bpo-39761: Fix dtrace build with empty $DFLAGS (GH-18766)Petr Viktorin2020-03-111-1/+1
| | | | | | This fixes a regression introduced in bpo-38960. When DFLAGS was empty, "$DFLAGS" results in an empty argument (""). Without the quotes, an empty variable will be ignored by the shell.
* bpo-1294959: Add sys.platlibdir attribute (GH-18381)Victor Stinner2020-03-101-15/+38
| | | | | | | | | | | | | Add --with-platlibdir option to the configure script: name of the platform-specific library directory, stored in the new sys.platlitdir attribute. It is used to build the path of platform-specific dynamic libraries and the path of the standard library. It is equal to "lib" on most platforms. On Fedora and SuSE, it is equal to "lib64" on 64-bit systems. Co-Authored-By: Jan Matějek <jmatejek@suse.com> Co-Authored-By: Matěj Cepl <mcepl@cepl.eu> Co-Authored-By: Charalampos Stratakis <cstratak@redhat.com>
* bpo-39794: Add --without-decimal-contextvar (#18702)Stefan Krah2020-02-291-0/+26
|
* closes bpo-39619 Fix os.chroot on HP-UX 11.31 (GH-18495)Ian Norton2020-02-141-1/+19
| | | | | | Setting `-D_XOPEN_SOURCE=700` on HP-UX causes system functions such as chroot to be undefined. This change stops `_XOPEN_SOURCE` begin set on HP-UX Co-authored-by: Benjamin Peterson <benjamin@python.org>
* bpo-38960: DTrace build fix for FreeBSD. (GH-17451)David Carlier2020-01-281-2/+1
| | | | | | | | DTrace build fix for FreeBSD. - allowing passing an extra flag as it need to define the arch size. - casting some probe's arguments.
* bpo-39395: putenv() and unsetenv() always available (GH-18135)Victor Stinner2020-01-241-3/+3
| | | | | | | | The os.putenv() and os.unsetenv() functions are now always available. On non-Windows platforms, Python now requires setenv() and unsetenv() functions to build. Remove putenv_dict from posixmodule.c: it's not longer needed.
* bpo-39406: Implement os.putenv() with setenv() if available (GH-18128)Victor Stinner2020-01-221-14/+3
| | | | | If setenv() C function is available, os.putenv() is now implemented with setenv() instead of putenv(), so Python doesn't have to handle the environment variable memory.
* bpo-39160 Align the verbs, grammar and defaults for `./configure --help` ↵Anthony Shaw2020-01-141-52/+74
| | | | (GH-17747)
* bpo-38021: Modify AIX platform_tag so it covers PEP 425 needs (GH-17303)Michael Felt2019-12-151-2/+15
| | | | | | | | Provides a richer platform tag for AIX that we expect to be sufficient for PEP 425 binary distribution identification. Any backports to earlier Python versions will be handled via setuptools. Patch by Michael Felt.
* closes bpo-38713: Expose P_PIDFD in os if it's defined. (GH-17071)Benjamin Peterson2019-11-061-2/+14
| | | https://bugs.python.org/issue38713
* bpo-37415: Fix stdatomic.h header check for ICC compiler (GH-16717)Victor Stinner2019-10-221-15/+6
| | | | | | | | | | | | Fix stdatomic.h header check for ICC compiler: the ICC implementation lacks atomic_uintptr_t type which is needed by Python. Test: * atomic_int and atomic_uintptr_t types * atomic_load_explicit() and atomic_store_explicit() * memory_order_relaxed and memory_order_seq_cst constants But don't test ATOMIC_VAR_INIT(): it's not used in Python.
* bpo-11410: Standardize and use symbol visibility attributes across POSIX and ↵Vinay Sajip2019-10-151-0/+41
| | | | Windows. (GH-16347)
* bpo-38301: In Solaris family, we must be sure to use '-D_REENTRANT' (#16446)Jesús Cea2019-09-281-0/+3
|
* Run autoreconf. (GH-16106)Benjamin Peterson2019-09-131-60/+30
|
* bpo-38110: Use fdwalk for os.closerange() when available. (GH-15224)Jakub Kulík2019-09-111-1/+1
| | | Use fdwalk() on platforms that support it to implement os.closerange().
* bpo-38068: Clean up gettimeofday configure logic. (GH-15775)Benjamin Peterson2019-09-101-31/+0
| | | Assume gettimeofday exists and takes two arguments.
* bpo-34652 again: Remove lchmod from the default AC_CHECK_FUNCS list. (GH-15758)Benjamin Peterson2019-09-091-2/+14
|
* bpo-18049: Sync thread stack size to main thread size on macOS (GH-14748)Ronald Oussoren2019-08-011-0/+2
| | | | | | This changeset increases the default size of the stack for threads on macOS to the size of the stack of the main thread and reenables the relevant recursion test.
* bpo-36044: Reduce number of unit tests run for PGO build (GH-14702)Neil Schemenauer2019-07-221-0/+14
| | | | | | | | | | | | Reduce the number of unit tests run for the PGO generation task. This speeds up the task by a factor of about 15x. Running the full unit test suite is slow. This change may result in a slightly less optimized build since not as many code branches will be executed. If you are willing to wait for the much slower build, the old behavior can be restored using './configure [..] PROFILE_TASK="-m test --pgo-extended"'. We make no guarantees as to which PGO task set produces a faster build. Users who care should run their own relevant benchmarks as results can depend on the environment, workload, and compiler tool chain.
* bpo-34602: Avoid failures setting macOS stack resource limit (GH-14546)Ned Deily2019-07-021-0/+6
| | | | | | | | | | | | | | | | | Under some conditions the earlier fix for bpo-18075, "Infinite recursion tests triggering a segfault on Mac OS X", now causes failures on macOS when attempting to change stack limit with resource.setrlimit resource.RLIMIT_STACK, like regrtest does when running the test suite. The reverted change had specified a non-default stack size when linking the python executable on macOS. As of macOS 10.14.4, the previous code causes a hard failure when running tests, although similar failures had been seen under some conditions under some earlier systems. Reverting the change to the interpreter stack size at link time helped for release builds but caused some tests to fail when built --with-pydebug. Try the opposite approach: continue to build the interpreter with an increased stack size on macOS and remove the failing setrlimit call in regrtest initialization. This will definitely avoid the resource.RLIMIT_STACK error and should have no, or fewer, side effects.
* Bump to 3.9.0a0Łukasz Langa2019-06-041-10/+10
|
* bpo-26826: Expose copy_file_range in the os module (GH-7255)Pablo Galindo2019-05-311-14/+3
|
* autoreconf (GH-13651)Inada Naoki2019-05-301-2/+2
|
* bpo-26836: Add os.memfd_create() (#13567)Zackery Spytz2019-05-291-2/+47
| | | | | | | | | | | | | | | | | | | | * bpo-26836: Add os.memfd_create() * Use the glibc wrapper for memfd_create() Co-Authored-By: Christian Heimes <christian@python.org> * Fix deletions caused by autoreconf. * Use MFD_CLOEXEC as the default value for *flags*. * Add memset_s to configure.ac. * Revert memset_s changes. * Apply the requested changes. * Tweak the docs.
* bpo-32941: Add madvise() for mmap objects (GH-6172)Zackery Spytz2019-05-271-1/+1
| | | | Allow mmap objects to access the madvise() system call.
* bpo-21536: Fix configure.ac for LIBPYTHON on Android/Cygwin (GH-13552)E. M. Bray2019-05-241-3/+5
| | | | Add also missing AC_MSG_RESULT for AC_MSG_CHECKING(MACHDEP).
* bpo-21536: On Cygwin, C extensions must be linked with libpython (GH-13549)E. M. Bray2019-05-241-2/+2
| | | | | | | | | | It is also possible to link against a library or executable with a statically linked libpython, but not both with the same DLL. In fact building a statically linked python is currently broken on Cygwin for other (related) reasons. The same problem applies to other POSIX-like layers over Windows (MinGW, MSYS) but Python's build system does not seem to attempt to support those platforms at the moment.