* Oops, the bootstrap tools contained an impure gzip/gunzip.
* To prevent this kind of thing, check that all tools are statically linked. * Use findutils 4.2.27, 4.2.28 doesn't build with dietlibc. svn path=/nixpkgs/trunk/; revision=6881
This commit is contained in:
parent
de25bee83d
commit
c37304db96
Binary file not shown.
Binary file not shown.
|
@ -6,22 +6,22 @@
|
|||
tar = ./tar.bz2;
|
||||
|
||||
staticToolsURL = {
|
||||
url = http://nix.cs.uu.nl/dist/tarballs/stdenv-linux/i686/r6824/static-tools.tar.bz2;
|
||||
sha1 = "4cc936e5c5881eb1466dd8c2cb968e255fa446b7";
|
||||
url = file:///tmp/tarballs/static-tools.tar.bz2;
|
||||
sha1 = "c366d9ee0d969e68311fdb37abc91b46fb13b585";
|
||||
};
|
||||
|
||||
binutilsURL = {
|
||||
url = http://nix.cs.uu.nl/dist/tarballs/stdenv-linux/i686/r6824/binutils.tar.bz2;
|
||||
sha1 = "d7d85684fae7ec5b51d31e105f8fc041a3553c82";
|
||||
url = file:///tmp/tarballs/binutils.tar.bz2;
|
||||
sha1 = "fa77c29ef4f13ddf43bba3f4f020ceafa6604ccc";
|
||||
};
|
||||
|
||||
gccURL = {
|
||||
url = http://nix.cs.uu.nl/dist/tarballs/stdenv-linux/i686/r6824/gcc.tar.bz2;
|
||||
sha1 = "c1a6f1a6de2cd3cc1b112614661c9f6adf8a6377";
|
||||
url = file:///tmp/tarballs/gcc.tar.bz2;
|
||||
sha1 = "ea7171fc2f70880e8a6c2480b3d3fed7409b7a4e";
|
||||
};
|
||||
|
||||
glibcURL = {
|
||||
url = http://nix.cs.uu.nl/dist/tarballs/stdenv-linux/i686/r6824/glibc.tar.bz2;
|
||||
sha1 = "666b5a6c179bd6aedeeb40d34336716eb0d659ce";
|
||||
url = file:///tmp/tarballs/glibc.tar.bz2;
|
||||
sha1 = "728e0a9e66e01cf2815eca8cc638e5ed140a36cd";
|
||||
};
|
||||
}
|
||||
|
|
|
@ -25,8 +25,10 @@ let
|
|||
builder = ./make-bootstrap-tools.sh;
|
||||
|
||||
inherit (pkgsDiet)
|
||||
coreutils findutils diffutils gnugrep
|
||||
coreutils diffutils gnugrep
|
||||
gzip bzip2 gnumake bash patch binutils;
|
||||
|
||||
findutils = pkgsDiet.findutils4227; # 4.2.28 is broken
|
||||
|
||||
gnused = pkgsDiet.gnused412; # 4.1.5 gives "Memory exhausted" errors
|
||||
|
||||
|
@ -35,8 +37,8 @@ let
|
|||
|
||||
gnutar =
|
||||
# Tar seems to be broken on dietlibc on x86_64.
|
||||
if pkgs.stdenv.system == "i686-linux"
|
||||
then pkgsDiet.gnutar
|
||||
if pkgs.stdenv.system != "x86_64-linux"
|
||||
then pkgsDiet.gnutar151 # 1.16 is broken
|
||||
else pkgsStatic.gnutar;
|
||||
|
||||
gawk =
|
||||
|
@ -63,4 +65,4 @@ let
|
|||
allowedReferences = [];
|
||||
};
|
||||
|
||||
in generator.gnutar
|
||||
in generator
|
||||
|
|
|
@ -47,8 +47,8 @@ cp $gnugrep/bin/* tools/bin
|
|||
cp $gawk/bin/gawk tools/bin
|
||||
ln -s gawk tools/bin/awk
|
||||
cp $gnutar/bin/* tools/bin
|
||||
cp $gunzip/bin/gunzip tools/bin
|
||||
cp $gunzip/bin/gzip tools/bin
|
||||
cp $gzip/bin/gzip tools/bin
|
||||
ln -s gzip tools/bin/gunzip
|
||||
cp $bzip2/bin/bunzip2 tools/bin
|
||||
cp $gnumake/bin/* tools/bin
|
||||
cp $patch/bin/* tools/bin
|
||||
|
@ -62,12 +62,6 @@ nukeRefs tools/bin/grep
|
|||
nukeRefs tools/bin/patchelf
|
||||
nukeRefs tools/bin/make
|
||||
|
||||
if test "$system" = "powerpc-linux"; then
|
||||
for i in tools/bin/*; do
|
||||
nukeRefs $i
|
||||
done
|
||||
fi
|
||||
|
||||
|
||||
# Create the binutils tarball.
|
||||
mkdir binutils
|
||||
|
@ -153,6 +147,6 @@ done
|
|||
|
||||
|
||||
# Check that everything is statically linked
|
||||
for i in $(find $out -type x); do
|
||||
ldd $i
|
||||
for i in $(find $out -type f -perm +111); do
|
||||
if ldd $i | grep -q "=>"; then echo "not statically linked: $i"; exit 1; fi
|
||||
done
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
{stdenv, fetchurl, coreutils}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "findutils-4.2.27";
|
||||
src = fetchurl {
|
||||
url = http://nix.cs.uu.nl/dist/tarballs/findutils-4.2.27.tar.gz;
|
||||
md5 = "f1e0ddf09f28f8102ff3b90f3b5bc920";
|
||||
};
|
||||
buildInputs = [coreutils];
|
||||
patches = [./findutils-path.patch]
|
||||
# Note: the dietlibc is just to get findutils to compile. The
|
||||
# locate command probably won't work though.
|
||||
++ (if stdenv ? isDietLibC then [./dietlibc-hack.patch] else []);
|
||||
}
|
|
@ -273,6 +273,10 @@ rec {
|
|||
inherit fetchurl stdenv coreutils;
|
||||
});
|
||||
|
||||
findutils4227 = import ../tools/misc/findutils/4.2.27.nix {
|
||||
inherit fetchurl stdenv coreutils;
|
||||
};
|
||||
|
||||
findutilsWrapper = import ../tools/misc/findutils-wrapper {
|
||||
inherit stdenv findutils;
|
||||
};
|
||||
|
@ -314,13 +318,14 @@ rec {
|
|||
};
|
||||
|
||||
gnutar = useFromStdenv (stdenv ? gnutar) stdenv.gnutar
|
||||
((if stdenv ? isDietLibC
|
||||
then import ../tools/archivers/gnutar/1.15.1.nix
|
||||
else import ../tools/archivers/gnutar)
|
||||
{
|
||||
(import ../tools/archivers/gnutar {
|
||||
inherit fetchurl stdenv;
|
||||
});
|
||||
|
||||
gnutar151 = import ../tools/archivers/gnutar/1.15.1.nix {
|
||||
inherit fetchurl stdenv;
|
||||
};
|
||||
|
||||
graphviz = import ../tools/graphics/graphviz {
|
||||
inherit fetchurl stdenv libpng libjpeg expat x11 yacc libtool;
|
||||
inherit (xlibs) libXaw;
|
||||
|
|
Loading…
Reference in New Issue