mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-11 15:27:20 +03:00
* Add gzip, binutils. Getting there...
svn path=/nixpkgs/trunk/; revision=6784
This commit is contained in:
parent
884e8571c3
commit
63720cf493
@ -7,13 +7,14 @@ let
|
||||
# stdenv-linux's dependencies, rather than building new ones with
|
||||
# dietlibc.
|
||||
bootStdenv = removeAttrs (pkgs.useDietLibC pkgs.stdenv)
|
||||
["coreutils" "gnused" "gnutar" "gnugrep" "bzip2" "bash" "patch" "patchelf"];
|
||||
["binutils" "coreutils" "gnused" "gnugrep" "gnutar" "gzip" "bzip2" "bash" "patch" "patchelf"];
|
||||
};
|
||||
|
||||
generator = pkgs.stdenv.mkDerivation {
|
||||
name = "bootstrap-tools-generator";
|
||||
builder = ./make-bootstrap-tools.sh;
|
||||
inherit (pkgsDiet) coreutils gnused gnugrep gnutar bzip2 bash patch;
|
||||
inherit (pkgsDiet) coreutils gnused gnugrep gnutar gzip bzip2 bash patch;
|
||||
binutils = pkgsDiet.binutils;
|
||||
curl = pkgsDiet.realCurl;
|
||||
|
||||
# The result should not contain any references (store paths) so
|
||||
|
@ -17,6 +17,8 @@ nukeRefs() {
|
||||
}
|
||||
|
||||
|
||||
# Create the tools that need to be in-tree, i.e., the ones that are
|
||||
# necessary for the absolute first stage of the bootstrap.
|
||||
cp $bash/bin/bash $out/in-nixpkgs
|
||||
cp $bzip2/bin/bunzip2 $out/in-nixpkgs
|
||||
cp $gnutar/bin/tar $out/in-nixpkgs
|
||||
@ -27,6 +29,7 @@ nukeRefs $out/in-nixpkgs/bash
|
||||
nukeRefs $out/in-nixpkgs/tar
|
||||
|
||||
|
||||
# Create the tools tarball.
|
||||
mkdir tools
|
||||
mkdir tools/bin
|
||||
|
||||
@ -37,6 +40,7 @@ rm tools/bin/printf # idem
|
||||
cp $gnused/bin/* tools/bin
|
||||
cp $gnugrep/bin/* tools/bin
|
||||
cp $gnutar/bin/* tools/bin
|
||||
cp $gunzip/bin/gunzip tools/bin
|
||||
cp $bzip2/bin/bunzip2 tools/bin
|
||||
cp $patch/bin/* tools/bin
|
||||
|
||||
@ -47,7 +51,17 @@ nukeRefs tools/bin/grep
|
||||
#cp $patchelf/bin/* tools/bin
|
||||
|
||||
|
||||
for i in $out/in-nixpkgs/* tools/bin/*; do
|
||||
# Create the binutils tarball.
|
||||
mkdir binutils
|
||||
mkdir binutils/bin
|
||||
for i in as ld ar ranlib nm strip; do
|
||||
cp $binutils/bin/$i binutils/bin
|
||||
nukeRefs binutils/bin/$i
|
||||
done
|
||||
|
||||
|
||||
# Strip executables even further.
|
||||
for i in $out/in-nixpkgs/* */bin/*; do
|
||||
if test -x $i; then
|
||||
chmod +w $i
|
||||
strip -s $i || true
|
||||
@ -55,9 +69,10 @@ for i in $out/in-nixpkgs/* tools/bin/*; do
|
||||
done
|
||||
|
||||
|
||||
tar cvfj $out/on-server/static-tools.tar.bz2 tools
|
||||
|
||||
# Pack, unpack everything.
|
||||
tar cfj $out/on-server/static-tools.tar.bz2 tools
|
||||
tar cfj $out/on-server/binutils.tar.bz2 binutils
|
||||
|
||||
for i in $out/on-server/*.tar.bz2; do
|
||||
(cd $out/check-only && tar xvfj $i)
|
||||
(cd $out/check-only && tar xfj $i)
|
||||
done
|
||||
|
@ -957,9 +957,8 @@ rec {
|
||||
cross = "sparc-linux";
|
||||
};
|
||||
|
||||
binutilsDiet = import ../development/tools/misc/binutils/binutils-2.17.nix {
|
||||
inherit fetchurl noSysDirs;
|
||||
stdenv = useDietLibC stdenv;
|
||||
binutils217 = import ../development/tools/misc/binutils/binutils-2.17.nix {
|
||||
inherit fetchurl stdenv noSysDirs;
|
||||
};
|
||||
|
||||
bison = bison1875;
|
||||
|
Loading…
Reference in New Issue
Block a user