summaryrefslogtreecommitdiff
path: root/guix
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2019-10-13 23:04:06 +0200
committerMarius Bakke <mbakke@fastmail.com>2019-10-13 23:04:06 +0200
commit378ebc048c033744b4f1dc13e16f4f2277d7529f (patch)
tree8411f2a9348d47858b2aca849377e91ea7f90833 /guix
parentd99e7ee0f2bbe4abe08552afaa9821036da2a760 (diff)
parent64855281c18bab87a61c77a18c9001e6e222fb08 (diff)
Merge branch 'master' into staging
Diffstat (limited to 'guix')
-rw-r--r--guix/build-system/scons.scm4
-rw-r--r--guix/build/scons-build-system.scm9
2 files changed, 9 insertions, 4 deletions
diff --git a/guix/build-system/scons.scm b/guix/build-system/scons.scm
index 5e76d64180..aad455c419 100644
--- a/guix/build-system/scons.scm
+++ b/guix/build-system/scons.scm
@@ -76,7 +76,9 @@
#:key
(tests? #t)
(scons-flags ''())
+ (build-targets ''())
(test-target "test")
+ (install-targets ''("install"))
(phases '(@ (guix build scons-build-system)
%standard-phases))
(outputs '("out"))
@@ -101,8 +103,10 @@ provides a 'SConstruct' file as its build system."
source))
#:scons-flags ,scons-flags
#:system ,system
+ #:build-targets ,build-targets
#:test-target ,test-target
#:tests? ,tests?
+ #:install-targets ,install-targets
#:phases ,phases
#:outputs %outputs
#:search-paths ',(map search-path-specification->sexp
diff --git a/guix/build/scons-build-system.scm b/guix/build/scons-build-system.scm
index eb013f03b6..17a0b7b877 100644
--- a/guix/build/scons-build-system.scm
+++ b/guix/build/scons-build-system.scm
@@ -29,7 +29,7 @@
;;
;; Code:
-(define* (build #:key outputs (scons-flags '()) (parallel-build? #t) #:allow-other-keys)
+(define* (build #:key outputs (build-targets '()) (scons-flags '()) (parallel-build? #t) #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(mkdir-p out)
(apply invoke "scons"
@@ -37,7 +37,8 @@
(list "-j" (number->string
(parallel-job-count)))
(list))
- scons-flags))))
+ scons-flags
+ build-targets))))
(define* (check #:key tests? test-target (scons-flags '()) #:allow-other-keys)
"Run the test suite of a given SCons application."
@@ -46,9 +47,9 @@
(format #t "test suite not run~%"))
#t)
-(define* (install #:key outputs (scons-flags '()) #:allow-other-keys)
+(define* (install #:key outputs (install-targets '("install")) (scons-flags '()) #:allow-other-keys)
"Install a given SCons application."
- (apply invoke "scons" "install" scons-flags))
+ (apply invoke "scons" (append scons-flags install-targets)))
(define %standard-phases
(modify-phases gnu:%standard-phases