Loading pkgs/os-specific/linux/minimal-bootstrap/default.nix +7 −0 Original line number Diff line number Diff line Loading @@ -243,6 +243,12 @@ lib.makeScope gnutarBoot = gnutar-latest; }; gzip-static = callPackage ./gzip/static.nix { gcc = gcc-latest; gnumake = gnumake-musl; gnutar = gnutar-latest; }; gzip = callPackage ./gzip { bash = bash_2_05; tinycc = tinycc-bootstrappable; Loading Loading @@ -377,6 +383,7 @@ lib.makeScope echo ${gnutar-musl.tests.get-version} echo ${gnutar-static.tests.get-version} echo ${gzip.tests.get-version} echo ${gzip-static.tests.get-version} echo ${heirloom.tests.get-version} echo ${mes.compiler.tests.get-version} echo ${musl.tests.hello-world} Loading pkgs/os-specific/linux/minimal-bootstrap/gzip/static.nix 0 → 100644 +79 −0 Original line number Diff line number Diff line { lib, buildPlatform, hostPlatform, fetchurl, bash, gcc, musl, binutils, gnumake, gnused, gnugrep, gawk, diffutils, findutils, gnutar, xz, }: let pname = "gzip-static"; version = "1.13"; src = fetchurl { url = "mirror://gnu/gzip/gzip-${version}.tar.xz"; hash = "sha256-dFTraTXbF8ZlVXbC4bD6vv04tNCTbg+H9IzQYs6RoFc="; }; in bash.runCommand "${pname}-${version}" { inherit pname version; nativeBuildInputs = [ gcc musl binutils gnumake gnused gnugrep gawk diffutils findutils gnutar xz ]; passthru.tests.get-version = result: bash.runCommand "${pname}-get-version-${version}" { } '' ${result}/bin/gzip --version mkdir $out ''; meta = { description = "GNU zip compression program"; homepage = "https://www.gnu.org/software/gzip"; license = lib.licenses.gpl3Plus; platforms = lib.platforms.unix; teams = [ lib.teams.minimal-bootstrap ]; }; } '' # Unpack tar xf ${src} cd gzip-${version} # Configure bash ./configure \ --prefix=$out \ --build=${buildPlatform.config} \ --host=${hostPlatform.config} \ CC=musl-gcc \ CFLAGS=-static # Build make -j $NIX_BUILD_CORES bin_SCRIPTS= # Install make -j $NIX_BUILD_CORES bin_SCRIPTS= install '' Loading
pkgs/os-specific/linux/minimal-bootstrap/default.nix +7 −0 Original line number Diff line number Diff line Loading @@ -243,6 +243,12 @@ lib.makeScope gnutarBoot = gnutar-latest; }; gzip-static = callPackage ./gzip/static.nix { gcc = gcc-latest; gnumake = gnumake-musl; gnutar = gnutar-latest; }; gzip = callPackage ./gzip { bash = bash_2_05; tinycc = tinycc-bootstrappable; Loading Loading @@ -377,6 +383,7 @@ lib.makeScope echo ${gnutar-musl.tests.get-version} echo ${gnutar-static.tests.get-version} echo ${gzip.tests.get-version} echo ${gzip-static.tests.get-version} echo ${heirloom.tests.get-version} echo ${mes.compiler.tests.get-version} echo ${musl.tests.hello-world} Loading
pkgs/os-specific/linux/minimal-bootstrap/gzip/static.nix 0 → 100644 +79 −0 Original line number Diff line number Diff line { lib, buildPlatform, hostPlatform, fetchurl, bash, gcc, musl, binutils, gnumake, gnused, gnugrep, gawk, diffutils, findutils, gnutar, xz, }: let pname = "gzip-static"; version = "1.13"; src = fetchurl { url = "mirror://gnu/gzip/gzip-${version}.tar.xz"; hash = "sha256-dFTraTXbF8ZlVXbC4bD6vv04tNCTbg+H9IzQYs6RoFc="; }; in bash.runCommand "${pname}-${version}" { inherit pname version; nativeBuildInputs = [ gcc musl binutils gnumake gnused gnugrep gawk diffutils findutils gnutar xz ]; passthru.tests.get-version = result: bash.runCommand "${pname}-get-version-${version}" { } '' ${result}/bin/gzip --version mkdir $out ''; meta = { description = "GNU zip compression program"; homepage = "https://www.gnu.org/software/gzip"; license = lib.licenses.gpl3Plus; platforms = lib.platforms.unix; teams = [ lib.teams.minimal-bootstrap ]; }; } '' # Unpack tar xf ${src} cd gzip-${version} # Configure bash ./configure \ --prefix=$out \ --build=${buildPlatform.config} \ --host=${hostPlatform.config} \ CC=musl-gcc \ CFLAGS=-static # Build make -j $NIX_BUILD_CORES bin_SCRIPTS= # Install make -j $NIX_BUILD_CORES bin_SCRIPTS= install ''