Making a bunch of basic programs cross-buildable.

After this, the 'bootstrap-tools' can be cross-built.


svn path=/nixpkgs/branches/stdenv-updates/; revision=20945
This commit is contained in:
Lluís Batlle i Rossell
2010-04-04 18:10:42 +00:00
parent 2d261d1c1e
commit 19b9811012
9 changed files with 63 additions and 8 deletions
+10
View File
@@ -10,6 +10,16 @@ stdenv.mkDerivation {
sha256 = "08py2s9vw6dgw457lbklh1vsr3b8x8dlv7d8ygdfaxlx61l57gzp";
};
crossAttrs = {
patchPhase = ''
sed -i -e 's/CC=gcc/CC=${stdenv.cross.config}-gcc/' \
-e 's/AR=ar/AR=${stdenv.cross.config}-ar/' \
-e 's/RANLIB=ranlib/RANLIB=${stdenv.cross.config}-ranlib/' \
-e 's/bzip2recover test/bzip2recover/' \
Makefile*
'';
};
sharedLibrary =
!stdenv.isDarwin && !(stdenv ? isDietLibC) && !(stdenv ? isStatic) && stdenv.system != "i686-cygwin" && !linkStatic;