Only return Hydra jobs for supported platforms
This commit is contained in:
parent
79eda8573e
commit
78de3c912d
@ -8,6 +8,10 @@ rec {
|
|||||||
pkgs = allPackages { };
|
pkgs = allPackages { };
|
||||||
|
|
||||||
|
|
||||||
|
# The platforms for which we build Nixpkgs.
|
||||||
|
supportedSystems = [ "x86_64-linux" "i686-linux" "x86_64-darwin" "x86_64-freebsd" "i686-freebsd" ];
|
||||||
|
|
||||||
|
|
||||||
/* !!! Hack: poor man's memoisation function. Necessary to prevent
|
/* !!! Hack: poor man's memoisation function. Necessary to prevent
|
||||||
Nixpkgs from being evaluated again and again for every
|
Nixpkgs from being evaluated again and again for every
|
||||||
job/platform pair. */
|
job/platform pair. */
|
||||||
@ -45,11 +49,14 @@ rec {
|
|||||||
{ type = "job"; systems = x; schedulingPriority = 10; };
|
{ type = "job"; systems = x; schedulingPriority = 10; };
|
||||||
|
|
||||||
|
|
||||||
/* Perform a job on the given set of platforms. The function `f' is
|
/* Build a package on the given set of platforms. The function `f'
|
||||||
called by Hydra for each platform, and should return some job
|
is called for each supported platform with Nixpkgs for that
|
||||||
to build on that platform. `f' is passed the Nixpkgs collection
|
platform as an argument . We return an attribute set containing
|
||||||
for the platform in question. */
|
a derivation for each supported platform, i.e. ‘{ x86_64-linux =
|
||||||
testOn = systems: f: pkgs.lib.genAttrs systems (system: f (pkgsFor system));
|
f pkgs_x86_64_linux; i686-linux = f pkgs_i686_linux; ... }’. */
|
||||||
|
testOn = systems: f: pkgs.lib.genAttrs
|
||||||
|
(pkgs.lib.filter (x: pkgs.lib.elem x supportedSystems) systems)
|
||||||
|
(system: f (pkgsFor system));
|
||||||
|
|
||||||
|
|
||||||
/* Similar to the testOn function, but with an additional
|
/* Similar to the testOn function, but with an additional
|
||||||
|
Loading…
x
Reference in New Issue
Block a user