diff options
author | Jan (janneke) Nieuwenhuizen <janneke@gnu.org> | 2020-04-17 11:43:23 +0200 |
---|---|---|
committer | Jan Nieuwenhuizen <janneke@gnu.org> | 2020-04-19 16:18:01 +0200 |
commit | fc179005835365c7233b2b7f5abe838404ddf869 (patch) | |
tree | f5eb129d6e5a190338f031525c1e8487e175b9a6 | |
parent | 1c5063af86246917853992421a11997470feff77 (diff) | |
download | guix-fc179005835365c7233b2b7f5abe838404ddf869.tar.gz |
gnu: git: Resurrect cross-compilation.
* gnu/packages/version-control.scm (git-cross-configure-flags): Add missing "ac_cv_iconv_omits_bom" flag. (git)[arguments]: Avoid modify-PATH stage when cross-compiling as it depends on non-present "bash-for-tests".
-rw-r--r-- | gnu/packages/version-control.scm | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index b0cf2bd152..88a25f04f1 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -28,6 +28,7 @@ ;;; Copyright © 2020 Roel Janssen <roel@gnu.org> ;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re> ;;; Copyright © 2020 John D. Boy <jboy@bius.moe> +;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -147,7 +148,8 @@ as well as the classic centralized workflow.") (define git-cross-configure-flags '("ac_cv_fread_reads_directories=yes" - "ac_cv_snprintf_returns_bogus=no")) + "ac_cv_snprintf_returns_bogus=no" + "ac_cv_iconv_omits_bom=no")) (define-public git (package @@ -251,16 +253,19 @@ as well as the classic centralized workflow.") ,@%gnu-build-system-modules) #:phases (modify-phases %standard-phases - (add-after 'unpack 'modify-PATH - (lambda* (#:key inputs #:allow-other-keys) - (let ((path (string-split (getenv "PATH") #\:)) - (bash-full (assoc-ref inputs "bash-for-tests"))) - ;; Drop the test bash from PATH so that (which "sh") and - ;; similar does the right thing. - (setenv "PATH" (string-join - (remove (cut string-prefix? bash-full <>) path) - ":")) - #t))) + ;; We do not have bash-for-tests when cross-compiling. + ,@(if (%current-target-system) + '() + `((add-after 'unpack 'modify-PATH + (lambda* (#:key inputs #:allow-other-keys) + (let ((path (string-split (getenv "PATH") #\:)) + (bash-full (assoc-ref inputs "bash-for-tests"))) + ;; Drop the test bash from PATH so that (which "sh") and + ;; similar does the right thing. + (setenv "PATH" (string-join + (remove (cut string-prefix? bash-full <>) path) + ":")) + #t))))) ;; Add cross curl-config script to PATH when cross-compiling. ,@(if (%current-target-system) '((add-before 'configure 'add-cross-curl-config |