gnu: bash-static: Fix cross-compiling for glibc@2.41.

* gnu/packages/bash.scm (static-bash)[arguments]<#:configure-flags>: When
cross-compiling, Add bash_cv_getenv_redef=no.

Change-Id: I8105e91831dfdcce4e5494b3588ab8431dbaf5a8
This commit is contained in:
Zheng Junjie 2025-02-12 19:35:35 +08:00 committed by Andreas Enge
parent 6e9815a84f
commit 5d9a084092
No known key found for this signature in database
GPG key ID: F7D5C9BF765C61E3

View file

@ -326,6 +326,16 @@ without modification.")
(arguments
(substitute-keyword-arguments
`(#:allowed-references ("out") ,@(package-arguments bash))
((#:configure-flags flags '())
;; XXX: when Update glibc from 2.40 to 2.41,
;; need this flag to compile successfully.
;; Otherwise, an error will be reported:
;; multiple definition of `getenv'
(if (%current-target-system)
`(cons
"bash_cv_getenv_redef=no"
,flags)
flags))
((#:phases phases)
#~(modify-phases #$phases
(add-after 'strip 'remove-everything-but-the-binary