-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CPython: Condense patching, update patch versions, and add 3.11/3.12 #22599
Conversation
# Conflicts: # recipes/cpython/all/conanfile.py
Fixed modules standard library modules not being found in test_package.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Not directly related to this PR, but these pkg-config aliases need to be turned into lists:
I'm currently seeing a .pc file for each of the letters in And for Conan devs: a check for |
@valgur That's the second time I've been bitten by that exact problem, yes a check for that would be wonderful. I've fixed the issue, but of course now an unrelated issue popped up :/ |
This comment has been minimized.
This comment has been minimized.
Conan v1 pipeline ✔️All green in build 36 (
Conan v2 pipeline ✔️
All green in build 38 (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot. Can't thank you enough :)
- patch_file: "patches/3.12/3.12.1-0002-remove-module-deps.patch" | ||
patch_description: "Remove section of solution file forcing projects to be built that might not be used for this recipe" | ||
patch_type: "conan" | ||
"3.11.8": |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Ahajha is this a typo?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, yea it is. I have another PR out, I'll fix it in that one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, great!
…nd add 3.11/3.12 * wip * cpython: migrate to Conan v2 * cpython: fix autotools install step * cpython: fix libuuid requirement * cpython: update test_package * cpython: temporarily disable FindPythonX tests * cpython: package_type should be "library" * cpython: tidy * cpython: ncurses is required transitively * cpython: fix shared test * cpython: use cpp_info.aggregated_components() for deps * cpython: bsddb has been remove in Python 3 * cpython: fix openssl support * Fix package layout * Fix new generators in test package * Misc fixes * Remove redundant test * Add FIXMEs * Fix running test package multiple times in a row * Handle conan 1/2 differences in test_package * Fix MSBuild * Misc Conan 2.0 fixes * cpython: minor tweaks, bump deps * cpython: use altinstall Fixed modules standard library modules not being found in test_package. * Comment out versions with broken patches for now * Fix Autotools build * Restore old versions, temp remove 2.7.18 * Temp remove CPython 2.7.18 * Temp remove 2.7.18 * Misc MSVC fixes * Fix Windows/static build * Readd old test_package as test_v1_package * Add conanrun env to test package self.runs * Fix Linux shared build * Shared by default, don't delete compiler in package ID * Misc Mac fixes/cleanup * libxcrypt is transitive * Static by default for now * Attempt to fix 3.7 on Mac * Remove ssl module FIXME * self.settings.arch * Try using vendored libffi for mac on <3.9 * Fix PYTHONHOME on Linux, always set PYTHONHOME for test * Try vendored libffi on mac in debug mode * Remove "dynamic" check * Remove force on versions * Use Version() when comparing versions * Use a virtualrunenv in build, revert ffi changes * Bandaid fix for Linux * Use virtualrunenvs in v1 test package also * Skip 3.7 build on M1 macs * Set platform toolset directly on <3.8 * Fix issue with pip installed cmake * Python 2 compat in test_package.py * Re-add Python 2.7 + workarounds for MSVC * Misc pre-3.8 msvc fixes * Fix python 2 on Linux * Add 2.7.18 to config.yml * Remove includedirs for all components other than the main one * Use msvc_runtime_flag * Misc MSVC fixes * Skip building _freeze_importlib, fix 3.7.12 in msvc Debug MDd * Shot in the dark attempt at fixing Mac issue * Unconditionally generate VCVars in test package * Print config.log if autotools configure fails * Skip spam module test in 2.7 (debug, MDd) as well * Remove unnecessary removals from pcbuild.sln * Inject _bz2 programmatically * Also programattically patch bz2 in python 2.7 * Dynamically patch _elementtree, _ctypes, and _decimal projects * Patch pyexpat project programmatically * Inject libdb programmatically * Inject openssl into hashlib programmatically * Inject xz_utils programattically * Programattically inject sqlite * Programmatically inject openssl into _ssl project * Programmatically inject tk into _tkinter project * Programmatically inject zlib into pythoncore project * Remove/simplify redundant patching code * Minor cleanup * Refactor into _regex_replace_in_file * Refactoring of injection of conan props files * More refactoring for props file injecting * Programmatically remove parts of _ctypes project * Programmatically remove parts of _ctypes (patches) * Patch _decimal project programmatically * Remove sqlite project programmatically * Remove sqlite project programatically (patches) * Remove lzma project include programmatically * Remove openssl props import programmatically * Programmatically patch pyexpat project * Patch _elementtree project programmatically * Allow MSVC/Debug/dynamic with newer libffi * Test package cleanup * Fix Debug MSVC test package * Use test_package/test_package.py in test_v1_package * Fix conditional _d in debug mode * Add -Wl,--as-needed * Use extra_ldflags instead * Don't use -Wl,--as-needed on Apple OSs * Programmatically patch pythoncore project * Remove pythoncore patches * Remove unnecessary(?) patch * Programmatically patch _tkinter project * Programmatically patch _lzma project * Manually inject platform toolset on 3.8.x * Programmatically patch python project * Programmatically patch _freeze_importlib * Programmatically patch _ssl project, remove empty MSVC patches * Misc python 2 fixes * Programmatically patch setup py to skip tkinter detection * Programmatically patch ini CFLAGS and CPPFLAGS * Update 3.8.12 to 3.8.18 * Don't use use_2to3 after it is deprecated * Update 3.9.7 to 3.9.18 * Update 3.10.0 to 3.10.13 * Always manually specify the platform toolset * Fix MSVC static * Fix 3.7 patching * Update 3.7.12 to 3.7.17 * Add 3.11.7 (likely only MSVC works for now) * Add 3.12.1 (likely only working on Windows for now) * Update config.yml * Remove Py_SetProgramName (deprecated in 3.11) * Fix 3.12 on Linux * Fix 3.11 on Linux * Disable GCC 9 build * Cleanup test_v1_package * Only disable 3.12.1 GCC 9 build * Use pkgconfig tool requirement * Another shot in the dark attempt at fixing MacOS sporadic failure * Update to 3.12.2 and 3.11.8 * Update dependencies * Add patch descriptions * Enable short paths * Add link to nis system library * nis -> nsl * Add final newline * Simplify pkg-config info * Check for Linux or FreeBSD * Fix disabling sqlite3 (on Linux at least) * Simplify some file removing * rm unnecessary rm * Simplify pkg-config info * Check for Linux or FreeBSD * Fix disabling sqlite3 (on Linux at least) * Simplify some file removing * rm unnecessary rm * Disable GCC 9 build on 3.12 as a whole * Misc configure variable cleanup * Point test_v1_package to test_package sources * Fix lint warning * Diff cleanup * Conditionally add --with-system-ffi * Misc test package cleanup * Bump xz_utils * Bump xz_utils * Fix pymalloc argument * Don't read SSL config file Co-authored-by: Jordan Williams <jordan@jwillikers.com> * xcrypt is not transitive in newer versions * Bandaid fix for test package overflowing Windows max path length * Fix some lints * Remove EOL versions * Remove <3.8 logic * Fix more <3.8 logic * Small fix * Remove calculated Python major version * Use autotools.install() directly Co-authored-by: Uilian Ries <uilianries@gmail.com> * Remove outdated configure flags and some hacks * Add 2.0 versions of env variables * Remove PYTHONHOME from env info for now * Bump patch versions of 3.8/9/10 * Remove unused import * Fix running test package with spaces in path * Only link to ncursesw and tinfo Co-authored-by: Martin Valgur <martin.valgur@gmail.com> * Fix typo * Add context comments to most MSVC replace_in_files * Merge branch 'master' into update-cpython * Update to 3.11.9 * Add workaround for multithreaded install bug * Remove useless MSVC patch * Convert pkgconfig aliases to list --------- Co-authored-by: memsharded <james@conan.io> Co-authored-by: Martin Valgur <martin.valgur@gmail.com> Co-authored-by: Rubén Rincón Blanco <git@rinconblanco.es> Co-authored-by: Jordan Williams <jordan@jwillikers.com> Co-authored-by: Uilian Ries <uilianries@gmail.com>
there was an typo in conan-io#22599
…nd add 3.11/3.12 * wip * cpython: migrate to Conan v2 * cpython: fix autotools install step * cpython: fix libuuid requirement * cpython: update test_package * cpython: temporarily disable FindPythonX tests * cpython: package_type should be "library" * cpython: tidy * cpython: ncurses is required transitively * cpython: fix shared test * cpython: use cpp_info.aggregated_components() for deps * cpython: bsddb has been remove in Python 3 * cpython: fix openssl support * Fix package layout * Fix new generators in test package * Misc fixes * Remove redundant test * Add FIXMEs * Fix running test package multiple times in a row * Handle conan 1/2 differences in test_package * Fix MSBuild * Misc Conan 2.0 fixes * cpython: minor tweaks, bump deps * cpython: use altinstall Fixed modules standard library modules not being found in test_package. * Comment out versions with broken patches for now * Fix Autotools build * Restore old versions, temp remove 2.7.18 * Temp remove CPython 2.7.18 * Temp remove 2.7.18 * Misc MSVC fixes * Fix Windows/static build * Readd old test_package as test_v1_package * Add conanrun env to test package self.runs * Fix Linux shared build * Shared by default, don't delete compiler in package ID * Misc Mac fixes/cleanup * libxcrypt is transitive * Static by default for now * Attempt to fix 3.7 on Mac * Remove ssl module FIXME * self.settings.arch * Try using vendored libffi for mac on <3.9 * Fix PYTHONHOME on Linux, always set PYTHONHOME for test * Try vendored libffi on mac in debug mode * Remove "dynamic" check * Remove force on versions * Use Version() when comparing versions * Use a virtualrunenv in build, revert ffi changes * Bandaid fix for Linux * Use virtualrunenvs in v1 test package also * Skip 3.7 build on M1 macs * Set platform toolset directly on <3.8 * Fix issue with pip installed cmake * Python 2 compat in test_package.py * Re-add Python 2.7 + workarounds for MSVC * Misc pre-3.8 msvc fixes * Fix python 2 on Linux * Add 2.7.18 to config.yml * Remove includedirs for all components other than the main one * Use msvc_runtime_flag * Misc MSVC fixes * Skip building _freeze_importlib, fix 3.7.12 in msvc Debug MDd * Shot in the dark attempt at fixing Mac issue * Unconditionally generate VCVars in test package * Print config.log if autotools configure fails * Skip spam module test in 2.7 (debug, MDd) as well * Remove unnecessary removals from pcbuild.sln * Inject _bz2 programmatically * Also programattically patch bz2 in python 2.7 * Dynamically patch _elementtree, _ctypes, and _decimal projects * Patch pyexpat project programmatically * Inject libdb programmatically * Inject openssl into hashlib programmatically * Inject xz_utils programattically * Programattically inject sqlite * Programmatically inject openssl into _ssl project * Programmatically inject tk into _tkinter project * Programmatically inject zlib into pythoncore project * Remove/simplify redundant patching code * Minor cleanup * Refactor into _regex_replace_in_file * Refactoring of injection of conan props files * More refactoring for props file injecting * Programmatically remove parts of _ctypes project * Programmatically remove parts of _ctypes (patches) * Patch _decimal project programmatically * Remove sqlite project programmatically * Remove sqlite project programatically (patches) * Remove lzma project include programmatically * Remove openssl props import programmatically * Programmatically patch pyexpat project * Patch _elementtree project programmatically * Allow MSVC/Debug/dynamic with newer libffi * Test package cleanup * Fix Debug MSVC test package * Use test_package/test_package.py in test_v1_package * Fix conditional _d in debug mode * Add -Wl,--as-needed * Use extra_ldflags instead * Don't use -Wl,--as-needed on Apple OSs * Programmatically patch pythoncore project * Remove pythoncore patches * Remove unnecessary(?) patch * Programmatically patch _tkinter project * Programmatically patch _lzma project * Manually inject platform toolset on 3.8.x * Programmatically patch python project * Programmatically patch _freeze_importlib * Programmatically patch _ssl project, remove empty MSVC patches * Misc python 2 fixes * Programmatically patch setup py to skip tkinter detection * Programmatically patch ini CFLAGS and CPPFLAGS * Update 3.8.12 to 3.8.18 * Don't use use_2to3 after it is deprecated * Update 3.9.7 to 3.9.18 * Update 3.10.0 to 3.10.13 * Always manually specify the platform toolset * Fix MSVC static * Fix 3.7 patching * Update 3.7.12 to 3.7.17 * Add 3.11.7 (likely only MSVC works for now) * Add 3.12.1 (likely only working on Windows for now) * Update config.yml * Remove Py_SetProgramName (deprecated in 3.11) * Fix 3.12 on Linux * Fix 3.11 on Linux * Disable GCC 9 build * Cleanup test_v1_package * Only disable 3.12.1 GCC 9 build * Use pkgconfig tool requirement * Another shot in the dark attempt at fixing MacOS sporadic failure * Update to 3.12.2 and 3.11.8 * Update dependencies * Add patch descriptions * Enable short paths * Add link to nis system library * nis -> nsl * Add final newline * Simplify pkg-config info * Check for Linux or FreeBSD * Fix disabling sqlite3 (on Linux at least) * Simplify some file removing * rm unnecessary rm * Simplify pkg-config info * Check for Linux or FreeBSD * Fix disabling sqlite3 (on Linux at least) * Simplify some file removing * rm unnecessary rm * Disable GCC 9 build on 3.12 as a whole * Misc configure variable cleanup * Point test_v1_package to test_package sources * Fix lint warning * Diff cleanup * Conditionally add --with-system-ffi * Misc test package cleanup * Bump xz_utils * Bump xz_utils * Fix pymalloc argument * Don't read SSL config file Co-authored-by: Jordan Williams <jordan@jwillikers.com> * xcrypt is not transitive in newer versions * Bandaid fix for test package overflowing Windows max path length * Fix some lints * Remove EOL versions * Remove <3.8 logic * Fix more <3.8 logic * Small fix * Remove calculated Python major version * Use autotools.install() directly Co-authored-by: Uilian Ries <uilianries@gmail.com> * Remove outdated configure flags and some hacks * Add 2.0 versions of env variables * Remove PYTHONHOME from env info for now * Bump patch versions of 3.8/9/10 * Remove unused import * Fix running test package with spaces in path * Only link to ncursesw and tinfo Co-authored-by: Martin Valgur <martin.valgur@gmail.com> * Fix typo * Add context comments to most MSVC replace_in_files * Merge branch 'master' into update-cpython * Update to 3.11.9 * Add workaround for multithreaded install bug * Remove useless MSVC patch * Convert pkgconfig aliases to list --------- Co-authored-by: memsharded <james@conan.io> Co-authored-by: Martin Valgur <martin.valgur@gmail.com> Co-authored-by: Rubén Rincón Blanco <git@rinconblanco.es> Co-authored-by: Jordan Williams <jordan@jwillikers.com> Co-authored-by: Uilian Ries <uilianries@gmail.com>
there was an typo in #22599
there was an typo in conan-io#22599
Specify library name and version: cpython/all
Depends on #21387
Resolves #20768
Context for some of the changes:
replace_in_file
system, though admittedly I'm not a massive fan. Ideally I'd like to use fuzzy patching, but as far as I can tell they don't work.Once this is merged, I will make a draft PR for 3.13 (yet unreleased), as there are quite a few removals from Python's stdlib that will change some patching and remove at least one dependency: python/cpython#104773