aboutsummaryrefslogtreecommitdiff
path: root/guix/build/gnu-build-system.scm
diff options
context:
space:
mode:
authorMark H Weaver <mhw@netris.org>2015-07-13 18:54:40 -0400
committerMark H Weaver <mhw@netris.org>2015-07-13 18:54:40 -0400
commit3c7d023d6458669c6bfa23bc85e098c91f699892 (patch)
tree6c5ed721c9bb2705ae6b2e54befdbe04fae3d806 /guix/build/gnu-build-system.scm
parentf727ec5bc8a6f97ae1083026e508b917235dfd2d (diff)
downloadgnu-guix-3c7d023d6458669c6bfa23bc85e098c91f699892.tar
gnu-guix-3c7d023d6458669c6bfa23bc85e098c91f699892.tar.gz
build-system/gnu: Pass --build=<triplet> to configure by default.
* guix/build-system/gnu.scm (gnu-build, gnu-cross-build): Accept #:build keyword argument. Pass it to 'gnu-build' on the build side. * guix/build/gnu-build-system.scm (configure): Accept #:build keyword argument. Unless it is false, pass --build to configure.
Diffstat (limited to 'guix/build/gnu-build-system.scm')
-rw-r--r--guix/build/gnu-build-system.scm5
1 files changed, 4 insertions, 1 deletions
diff --git a/guix/build/gnu-build-system.scm b/guix/build/gnu-build-system.scm
index 5062479360..102207b022 100644
--- a/guix/build/gnu-build-system.scm
+++ b/guix/build/gnu-build-system.scm
@@ -184,7 +184,7 @@ makefiles."
;; Patch `SHELL' in generated makefiles.
(for-each patch-makefile-SHELL (find-files "." "^(GNU)?[mM]akefile$")))
-(define* (configure #:key target native-inputs inputs outputs
+(define* (configure #:key build target native-inputs inputs outputs
(configure-flags '()) out-of-source?
#:allow-other-keys)
(define (package-name)
@@ -234,6 +234,9 @@ makefiles."
(list (string-append "--docdir=" docdir
"/share/doc/" (package-name)))
'())
+ ,@(if build
+ (list (string-append "--build=" build))
+ '())
,@(if target ; cross building
(list (string-append "--host=" target))
'())