Commit Graph

73 Commits

Author SHA1 Message Date
Bryan Weber 0860b26a4f
gh-91670: Removes `SO` config variable in `sysconfig.py` (#91671)
* Removes SO config variable in sysconfig

Per @warsaw in https://github.com/python/cpython/issues/63754, this was
deprecated in Python 3.4 and was suggested for removal in Python 3.5.

* Add NEWS

* Update Misc/NEWS.d/next/Library/2022-04-18-15-23-24.gh-issue-91670.6eyChw.rst

Co-authored-by: Éric <merwok@netwok.org>

Co-authored-by: Barry Warsaw <barry@python.org>
Co-authored-by: Éric <merwok@netwok.org>
2022-04-18 14:01:18 -07:00
Miro Hrončok 48d9262699
bpo-45413: Define "posix_venv", "nt_venv" and "venv" sysconfig installation schemes (GH-31034)
Define *posix_venv* and *nt_venv* sysconfig installation schemes
to be used for bootstrapping new virtual environments.
Add *venv* sysconfig installation scheme to get the appropriate one of the above.
The schemes are identical to the pre-existing
*posix_prefix* and *nt* install schemes.
The venv module now uses the *venv* scheme to create new virtual environments
instead of hardcoding the paths depending only on the platform. Downstream
Python distributors customizing the *posix_prefix* or *nt* install
scheme in a way that is not compatible with the install scheme used in
virtual environments are encouraged not to customize the *venv* schemes.
When Python itself runs in a virtual environment,
sysconfig.get_default_scheme and
sysconfig.get_preferred_scheme with `key="prefix"` returns
*venv*.
2022-03-18 10:53:29 +01:00
Brett Cannon 8b1b27f193
Fix a `UnboundLocalError` bug in `test_sysconfig` (GH-31000)
Accidentally introduced by GH-24502
2022-01-29 00:43:36 +00:00
Natanael Copa 1f036ede59
bpo-43112: detect musl as a separate SOABI (GH-24502)
musl libc and gnu libc are not ABI compatible so we need set different
SOABI for musl and not simply assume that all linux is linux-gnu.

Replace linux-gnu with the detected os for the build from config.guess
for linux-musl*.
2022-01-28 15:02:54 -08:00
Christian Heimes 8464fbc42e
bpo-40280: Skip subprocess-based tests on wasm32-emscripten (GH-30615) 2022-01-25 08:09:06 +01:00
Christian Heimes 91e33ac3d0
bpo-40280: Add requires_fork test helper (GH-30622) 2022-01-16 22:52:43 +01:00
Steve Dower 99fcf15052
bpo-45582: Port getpath[p].c to Python (GH-29041)
The getpath.py file is frozen at build time and executed as code over a namespace. It is never imported, nor is it meant to be importable or reusable. However, it should be easier to read, modify, and patch than the previous code.

This commit attempts to preserve every previously tested quirk, but these may be changed in the future to better align platforms.
2021-12-03 00:08:42 +00:00
Victor Stinner 49acac00c0
bpo-44860: Update test_sysconfig for posix_user platlib (GH-28235)
Update test_sysconfig.test_user_similar() for the posix_user scheme:
"platlib" doesn't use sys.platlibdir.
2021-09-09 11:02:48 +02:00
Tzu-ping Chung d92513390a
bpo-43312: Functions returning default and preferred sysconfig schemes (GH-24644) 2021-04-27 09:45:55 +01:00
pxinwr ab74c014ae
bpo-31904: Fix site and sysconfig modules for VxWorks RTOS (GH-21821) 2020-12-20 23:27:42 +01:00
Matti Picus c0afb7fa0e
bpo-39825: Fixes sysconfig.get_config_var('EXT_SUFFIX') on Windows to match distutils (GH-22088) 2020-12-07 17:33:20 +00:00
Hai Shi deb016224c
bpo-40275: Use new test.support helper submodules in tests (GH-21317) 2020-07-06 14:29:49 +02:00
Steve Dower 9048c49322
bpo-37369: Fix initialization of sys members when launched via an app container (GH-14428)
sys._base_executable is now always defined on all platforms, and can be overridden through configuration.
Also adds test.support.PythonSymlink to encapsulate platform-specific logic for symlinking sys.executable
2019-06-29 10:34:11 -07:00
Steve Dower f14c28f397
bpo-34011: Fixes missing venv files and other tests (GH-9458) 2018-09-20 13:38:34 -07:00
Zachary Ware 49ce74efe8 Remove all mention of Windows IA-64 support (GH-3389)
It was mostly removed long ago.
2017-09-06 15:45:25 -07:00
Xavier de Gaye e660327cf1 Issue #28849: Merge 3.6. 2016-12-14 20:37:53 +01:00
Xavier de Gaye 471bc3c814 Issue #28849: Skip test_sysconfig.test_triplet_in_ext_suffix on non linux platforms. 2016-12-14 20:37:10 +01:00
Xavier de Gaye 5ca2b10213 Issue #28849: Merge 3.6. 2016-12-10 17:34:46 +01:00
Xavier de Gaye 32cf1acda8 Issue #28849: Do not define sys.implementation._multiarch on Android. 2016-12-10 17:31:28 +01:00
Zachary Ware f7cc603507 Skip a sysconfig test if _ctypes is not available.
Also migrates test_sysconfig to unittest discovery.
2016-09-17 01:57:28 -05:00
Xavier de Gaye fda8961115 Issue #27917: Fix test_triplet_in_ext_suffix for the 'x86' Android platform. 2016-09-11 21:39:17 +02:00
Berker Peksag ad13edb6fd Issue #24705: Add a test case for ef84d21f5292 2016-01-28 16:58:00 +02:00
Serhiy Storchaka 5fbadb63ef Use support.change_cwd() in tests. 2015-09-06 14:14:49 +03:00
Serhiy Storchaka 2a23adf440 Use support.change_cwd() in tests. 2015-09-06 14:13:25 +03:00
Ned Deily 3b8124884c Issues #22980, 23969: For OS X, use PEP 3149-style file names for extension
module binaries, with a platform triple of just "darwin", resulting in
file names like:

    _ssl.cpython-35m-darwin.so

rather than just _ssl.so as previously.

Instead of attempting to encode differences in CPU architecture and OS X
deployment targets in the file name as is done on other platforms,
these continue to be managed by the use of Apple multi-architecture
("fat") files, by the system dynamic loader, and by logic in higher-levels
like sysconfig.get_platform() and pip.
2015-04-15 17:11:47 -07:00
doko@ubuntu.com 807b80d4ec - #22980: fix typo in Lib/test/test_sysconfig.py triplet test 2015-04-15 20:52:39 +02:00
doko@ubuntu.com d3899c1a96 - Issue #22980: Under Linux, GNU/KFreeBSD and the Hurd, C extensions now include
the architecture triplet in the extension name, to make it easy to test builds
  for different ABIs in the same working tree.
2015-04-15 20:23:14 +02:00
Antoine Pitrou 5bd7bf5bab Issue #22980: Under Linux, C extensions now include bitness in the file name,
to make it easy to test 32-bit and 64-bit builds in the same working tree.
2015-03-08 20:43:10 +01:00
Serhiy Storchaka eaec3597dd Issue #19760: Silence sysconfig's 'SO' key deprecation warnings in tests.
Change stacklevel in warnings.warn() for 'SO' key to 2.
2013-11-26 17:08:24 +02:00
Barry Warsaw 197a770231 - Issue #19555: Restore sysconfig.get_config_var('SO'), with a
DeprecationWarning pointing people at $EXT_SUFFIX.
2013-11-21 18:57:14 -05:00
Antoine Pitrou 3d3e1ba8ac Issue #19340: Fix test_sysconfig when Python is built with an empty prefix.
Patch by Sunny K.
2013-10-23 19:08:07 +02:00
Antoine Pitrou dde25c4851 Issue #19340: Fix test_sysconfig when Python is built with an empty prefix.
Patch by Sunny K.
2013-10-23 19:07:40 +02:00
Jesus Cea f01d695ccd Closes #16135: Removal of OS/2 support 2012-10-05 03:36:11 +02:00
Philip Jenvey 075bbb176f utilize subprocess.DEVNULL 2012-10-01 11:48:46 -07:00
Ned Deily 6c779ea553 Issue #15364: Fix test_srcdir for the installed case. 2012-07-27 23:37:04 -07:00
Richard Oudkerk 46874ad367 Issue #15364: Fix sysconfig.get_config_var('srcdir') to be an absolute path. 2012-07-27 12:06:55 +01:00
Ned Deily df8aa2b325 Issue #15184: Ensure consistent results of OS X configuration
tailoring for universal builds by factoring out common OS X-specific
customizations from sysconfig, distutils.sysconfig, distutils.util,
and distutils.unixccompiler into a new module _osx_support that can
eventually also be used by packaging.
2012-07-21 05:36:30 -07:00
Larry Hastings 605a62ddb1 Issue #15118: Change return value of os.uname() and os.times() from
plain tuples to immutable iterable objects with named attributes
(structseq objects).
2012-06-24 04:33:36 -07:00
Éric Araujo ec177c14d3 Packaging removal: also revert introduction of sysconfig.cfg.
We need a discussion to define what should be customized how; this new
config file is premature.  It was added to serve the needs of the
resources system in install_data / packaging.database, so it can be
removed alongside packaging for 3.3.
2012-06-24 03:27:43 -04:00
Vinay Sajip 7ded1f0f69 Implemented PEP 405 (Python virtual environments). 2012-05-26 03:45:29 +01:00
Benjamin Peterson d710d147f6 convince regrtest.py we aren't modifying _CONFIG_VARS 2012-01-04 10:12:14 -06:00
Éric Araujo 6ebea15e0b Merge fixes for #10526, #10359, #11254, #9100 and the bug without number 2011-10-08 02:57:45 +02:00
Éric Araujo de504550af Fix test_sysconfig when prefix != exec-prefix (#9100).
I tested this manually; it would be great to have buildbots using
installed Pythons, including Pythons configured with different prefix
and exec-prefix.

Reported by Zsolt Cserna.
2011-10-08 01:55:07 +02:00
Éric Araujo c1b7e7f8bb A few style changes originally done in the distutils2 repo 2011-09-18 23:12:30 +02:00
Éric Araujo ab3bea6815 Merge fix for #10086 from 3.2 2011-08-31 16:52:12 +02:00
Éric Araujo 48e484fdde Fix test_sysconfig when run from a Python installed under /site (#10086).
Patch by Hallvard B Furuseth.
2011-08-31 16:48:17 +02:00
Brett Cannon a4265546f9 Explicitly close a file to stop raising a ResourceWarning. 2011-08-04 21:34:52 -07:00
Éric Araujo f46676d48f Branch merge 2011-05-26 16:35:14 +02:00
Éric Araujo 559b5f1ca0 Minor cleanup in sysconfig.
Also remove outdated and unhelpful docstrings in test_sysconfig.
2011-05-25 18:21:43 +02:00
Victor Stinner 17dc81951a (Merge 3.2) Issue #12070: Fix the Makefile parser of the sysconfig module to
handle correctly references to "bogus variable" (e.g. "prefix=$/opt/python").
2011-05-24 23:38:03 +02:00