Compare commits

...

4 Commits

Author SHA1 Message Date
Domen Kožar e7763e4576
release.nix: add tarballs to release critical 2017-07-13 14:58:15 +02:00
Domen Kožar 9f29ddd07c
release.nix: Use only one version of tarball 2017-07-13 14:56:59 +02:00
Domen Kožar af10cd93a5
release.nix: respect top-level nixpkgs input 2017-07-12 16:37:17 +02:00
Domen Kožar 555f283064
Build tarball per system
This catches any build failures that otherwise users might encounter.

For example libseccomp package doesn't build on darwin.
2017-07-12 16:31:31 +02:00
1 changed files with 22 additions and 20 deletions

View File

@ -5,7 +5,7 @@
let
pkgs = import <nixpkgs> {};
pkgs = import nixpkgs {};
systems = [ "x86_64-linux" "i686-linux" "x86_64-darwin" "aarch64-linux" ];
@ -13,8 +13,8 @@ let
jobs = rec {
tarball =
with pkgs;
tarball = pkgs.lib.genAttrs systems (system:
with import nixpkgs { inherit system; };
releaseTools.sourceTarball {
name = "nix-tarball";
@ -30,8 +30,7 @@ let
docbook5 docbook5_xsl
autoconf-archive
git
libseccomp
];
] ++ lib.optional stdenv.isLinux libseccomp;
configureFlags = "--enable-gc";
@ -60,18 +59,19 @@ let
make install docdir=$out/share/doc/nix makefiles=doc/manual/local.mk
echo "doc manual $out/share/doc/nix/manual" >> $out/nix-support/hydra-build-products
'';
};
}
);
build = pkgs.lib.genAttrs systems (system:
with import <nixpkgs> { inherit system; };
with import nixpkgs { inherit system; };
with import ./release-common.nix { inherit pkgs; };
releaseTools.nixBuild {
name = "nix";
src = tarball;
src = tarball."x86_64-linux";
buildInputs =
[ curl
@ -105,11 +105,11 @@ let
perlBindings = pkgs.lib.genAttrs systems (system:
let pkgs = import <nixpkgs> { inherit system; }; in with pkgs;
let pkgs = import nixpkgs { inherit system; }; in with pkgs;
releaseTools.nixBuild {
name = "nix-perl";
src = tarball;
src = tarball."x86_64-linux";
buildInputs =
[ (builtins.getAttr system jobs.build) curl bzip2 xz pkgconfig pkgs.perl ]
@ -131,7 +131,7 @@ let
binaryTarball = pkgs.lib.genAttrs systems (system:
# FIXME: temporarily use a different branch for the Darwin build.
with import <nixpkgs> { inherit system; };
with import nixpkgs { inherit system; };
let
toplevel = builtins.getAttr system jobs.build;
@ -166,11 +166,11 @@ let
coverage =
with import <nixpkgs> { system = "x86_64-linux"; };
with import nixpkgs { system = "x86_64-linux"; };
releaseTools.coverageAnalysis {
name = "nix-build";
src = tarball;
src = tarball."x86_64-linux";
buildInputs =
[ curl bzip2 openssl pkgconfig sqlite xz libsodium libseccomp
@ -225,7 +225,7 @@ let
});
tests.binaryTarball =
with import <nixpkgs> { system = "x86_64-linux"; };
with import nixpkgs { system = "x86_64-linux"; };
vmTools.runInLinuxImage (runCommand "nix-binary-tarball-test"
{ diskImage = vmTools.diskImages.ubuntu1204x86_64;
}
@ -265,10 +265,12 @@ let
# Aggregate job containing the release-critical jobs.
release = pkgs.releaseTools.aggregate {
name = "nix-${tarball.version}";
name = "nix-${tarball."x86_64-linux".version}";
meta.description = "Release-critical builds";
constituents =
[ tarball
[ tarball.x86_64-linux
tarball.x86_64-darwin
tarball.i686-linux
build.i686-linux
build.x86_64-darwin
build.x86_64-linux
@ -298,11 +300,11 @@ let
makeRPM =
system: diskImageFun: extraPackages:
with import <nixpkgs> { inherit system; };
with import nixpkgs { inherit system; };
releaseTools.rpmBuild rec {
name = "nix-rpm";
src = jobs.tarball;
src = jobs.tarball."x86_64-linux";
diskImage = (diskImageFun vmTools.diskImageFuns)
{ extraPackages =
[ "sqlite" "sqlite-devel" "bzip2-devel" "emacs" "libcurl-devel" "openssl-devel" "xz-devel" "libseccomp-devel" ]
@ -320,11 +322,11 @@ let
makeDeb =
system: diskImageFun: extraPackages: extraDebPackages:
with import <nixpkgs> { inherit system; };
with import nixpkgs { inherit system; };
releaseTools.debBuild {
name = "nix-deb";
src = jobs.tarball;
src = jobs.tarball."x86_64-linux";
diskImage = (diskImageFun vmTools.diskImageFuns)
{ extraPackages =
[ "libsqlite3-dev" "libbz2-dev" "libcurl-dev" "libcurl3-nss" "libssl-dev" "liblzma-dev" "libseccomp-dev" ]