hydra: Factorize package list creation.
* build-aux/hydra/gnu-system.scm (all-packages): New procedure, with body taken from... (hydra-jobs): ... here. Use it.
This commit is contained in:
parent
ad54924285
commit
b5033c5a9e
|
@ -261,6 +261,19 @@ valid."
|
||||||
(else
|
(else
|
||||||
#f)))))
|
#f)))))
|
||||||
|
|
||||||
|
(define (all-packages)
|
||||||
|
"Return the list of packages to build."
|
||||||
|
(fold-packages (lambda (package result)
|
||||||
|
(cond ((package-replacement package)
|
||||||
|
(cons* package ;build both
|
||||||
|
(package-replacement package)
|
||||||
|
result))
|
||||||
|
((package-superseded package)
|
||||||
|
result) ;don't build it
|
||||||
|
(else
|
||||||
|
(cons package result))))
|
||||||
|
'()))
|
||||||
|
|
||||||
|
|
||||||
;;;
|
;;;
|
||||||
;;; Hydra entry point.
|
;;; Hydra entry point.
|
||||||
|
@ -317,17 +330,7 @@ valid."
|
||||||
(case subset
|
(case subset
|
||||||
((all)
|
((all)
|
||||||
;; Build everything, including replacements.
|
;; Build everything, including replacements.
|
||||||
(let ((all (fold-packages
|
(let ((all (all-packages))
|
||||||
(lambda (package result)
|
|
||||||
(cond ((package-replacement package)
|
|
||||||
(cons* package
|
|
||||||
(package-replacement package)
|
|
||||||
result))
|
|
||||||
((package-superseded package)
|
|
||||||
result) ;don't build it
|
|
||||||
(else
|
|
||||||
(cons package result))))
|
|
||||||
'()))
|
|
||||||
(job (lambda (package)
|
(job (lambda (package)
|
||||||
(package->job store package
|
(package->job store package
|
||||||
system))))
|
system))))
|
||||||
|
|
Loading…
Reference in New Issue