diff options
author | Josselin Poiret <dev@jpoiret.xyz> | 2023-05-22 11:04:13 +0200 |
---|---|---|
committer | Josselin Poiret <dev@jpoiret.xyz> | 2023-07-13 18:20:04 +0200 |
commit | c2bb342b5ff0ac15d6dc37a9ba8daeb8956237e1 (patch) | |
tree | db34473fe2963c79bd37448a0d4622ac9ad9e6bd /gnu/packages/cross-base.scm | |
parent | 85ebfcf4ffe5dda6f1eceb00b6afdac3239c0a31 (diff) | |
download | guix-c2bb342b5ff0ac15d6dc37a9ba8daeb8956237e1.tar.gz guix-c2bb342b5ff0ac15d6dc37a9ba8daeb8956237e1.zip |
gnu: gnumach-headers: Cross-build without relying on x86.
* gnu/packages/hurd.scm (gnumach-headers): Remove configure flags where we
say the builder is running x86.
* gnu/packages/cross-base.scm (cross-gnumach-headers): Work around limitation
of build system, by manually changing the target host_cpu without relying on
--host, because we don't have a working cross-compiler yet.
Diffstat (limited to 'gnu/packages/cross-base.scm')
-rw-r--r-- | gnu/packages/cross-base.scm | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/gnu/packages/cross-base.scm b/gnu/packages/cross-base.scm index e5fc4ba8b5..cdf642358d 100644 --- a/gnu/packages/cross-base.scm +++ b/gnu/packages/cross-base.scm @@ -375,6 +375,24 @@ target that libc." (inherit gnumach-headers) (name (string-append (package-name gnumach-headers) "-cross-" target)) + (arguments + (substitute-keyword-arguments (package-arguments gnumach-headers) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + ;; Cheat by setting the host_cpu variable manually, since using + ;; --host= would require a working cross-compiler, which we don't + ;; have yet. + (add-after 'unpack 'substitute-host-cpu + (lambda _ + (substitute* "configure.ac" + (("AC_CANONICAL_HOST") + #$(string-append + "host_cpu=" + (match target + ((? target-x86-32?) + "i386") + ((? target-x86-64?) + "x86_64"))))))))))) (native-inputs (modify-inputs (package-native-inputs gnumach-headers) (prepend xgcc xbinutils))))) |