2024-04-12 12:35:54 +00:00
|
|
|
{
|
|
|
|
buildPackages,
|
2024-04-12 12:45:51 +00:00
|
|
|
cacert,
|
2024-04-12 12:35:54 +00:00
|
|
|
nix,
|
|
|
|
system,
|
|
|
|
}:
|
|
|
|
let
|
2024-07-13 23:22:43 +00:00
|
|
|
rootPaths = [
|
|
|
|
nix
|
|
|
|
cacert
|
|
|
|
];
|
|
|
|
installerClosureInfo = buildPackages.closureInfo { inherit rootPaths; };
|
2024-04-12 12:35:54 +00:00
|
|
|
|
2024-05-14 00:05:08 +00:00
|
|
|
meta.description = "Distribution-independent Lix bootstrap binaries for ${system}";
|
2024-04-12 12:35:54 +00:00
|
|
|
in
|
2024-07-13 23:22:43 +00:00
|
|
|
buildPackages.runCommand "lix-binary-tarball-${nix.version}"
|
|
|
|
{
|
|
|
|
inherit meta;
|
|
|
|
passthru.rootPaths = rootPaths;
|
|
|
|
}
|
|
|
|
''
|
|
|
|
cp ${installerClosureInfo}/registration $TMPDIR/reginfo
|
2024-04-12 12:35:54 +00:00
|
|
|
|
2024-07-13 23:22:43 +00:00
|
|
|
dir=lix-${nix.version}-${system}
|
|
|
|
fn=$out/$dir.tar.xz
|
|
|
|
mkdir -p $out/nix-support
|
|
|
|
echo "file binary-dist $fn" >> $out/nix-support/hydra-build-products
|
|
|
|
tar cvfJ $fn \
|
|
|
|
--owner=0 --group=0 --mode=u+rw,uga+r \
|
|
|
|
--mtime='1970-01-01' \
|
|
|
|
--absolute-names \
|
|
|
|
--hard-dereference \
|
|
|
|
--transform "s,$TMPDIR/reginfo,$dir/.reginfo," \
|
|
|
|
--transform "s,$NIX_STORE,$dir/store,S" \
|
|
|
|
$TMPDIR/reginfo \
|
|
|
|
$(cat ${installerClosureInfo}/store-paths)
|
|
|
|
''
|