mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-15 08:34:04 +00:00
python3: fix build on Darwin
https://github.com/NixOS/nixpkgs/pull/311767 improved build purity, but Python’s configure script checks the Darwin version to enable platform features. Replacing the check with a check for Darwin without the version allows the build to succeed again.
This commit is contained in:
parent
ef12b15a5b
commit
07ab74e4aa
@ -461,6 +461,8 @@ in with passthru; stdenv.mkDerivation (finalAttrs: {
|
||||
'' + optionalString stdenv.isDarwin ''
|
||||
# Override the auto-detection in setup.py, which assumes a universal build
|
||||
export PYTHON_DECIMAL_WITH_MACHINE=${if stdenv.isAarch64 then "uint128" else "x64"}
|
||||
# Ensure that modern platform features are enabled on Darwin in spite of having no version suffix.
|
||||
sed -E -i -e 's|Darwin/\[12\]\[0-9\]\.\*|Darwin/*|' configure
|
||||
'' + optionalString (stdenv.isDarwin && x11Support && pythonAtLeast "3.11") ''
|
||||
export TCLTK_LIBS="-L${tcl}/lib -L${tk}/lib -l${tcl.libPrefix} -l${tk.libPrefix}"
|
||||
export TCLTK_CFLAGS="-I${tcl}/include -I${tk}/include"
|
||||
|
Loading…
Reference in New Issue
Block a user