GNU bug report logs -
#77947
[PATCH] gnu: python@3.11: Support cross-compilation.
Previous Next
Reported by: Ludovic Courtès <ludo <at> gnu.org>
Date: Sun, 20 Apr 2025 21:35:02 UTC
Severity: normal
Tags: patch
Done: Ludovic Courtès <ludo <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
* gnu/packages/python.scm (python-3.11)[arguments]: Pass
‘--with-build-python’ when cross-compiling.
Change-Id: Ibb210cc599ff06c5da7e73f706488488c84f5cba
---
gnu/packages/python.scm | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
Hello Python team,
This fixes cross-compilation of python <at> 3.11, adding the ‘--with-build-python’
flag, which apparently wasn’t needed for 3.10.
I found this while attempting to build a childhurd as part of my system
config.
Thoughts?
Ludo’.
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index ebc9712294..0f2b0891aa 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -1,6 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013 Nikita Karetnikov <nikita <at> karetnikov.org>
-;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2021, 2023 Ludovic Courtès <ludo <at> gnu.org>
+;;; Copyright © 2013-2018, 2021, 2023, 2025 Ludovic Courtès <ludo <at> gnu.org>
;;; Copyright © 2013, 2014, 2015, 2016 Andreas Enge <andreas <at> enge.fr>
;;; Copyright © 2014, 2015 Mark H Weaver <mhw <at> netris.org>
;;; Copyright © 2014, 2017, 2019 Eric Bavier <bavier <at> member.fsf.org>
@@ -728,9 +728,12 @@ (define-public python-3.11
;; Disable runtime check failing if cross-compiling, see:
;; https://lists.yoctoproject.org/pipermail/poky/2013-June/008997.html
#$@(if (%current-target-system)
- '("ac_cv_buggy_getaddrinfo=no"
- "ac_cv_file__dev_ptmx=no"
- "ac_cv_file__dev_ptc=no")
+ #~("ac_cv_buggy_getaddrinfo=no"
+ "ac_cv_file__dev_ptmx=no"
+ "ac_cv_file__dev_ptc=no"
+ (string-append "--with-build-python="
+ #+(this-package-native-input "python")
+ "/bin/python3"))
'())
;; -fno-semantic-interposition reinstates some
;; optimizations by gcc leading to around 15% speedup.
base-commit: ba53ff9cc403c7f0388e2dc932cb46e665e81be7
--
2.49.0
This bug report was last modified 31 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.