Trying to get coreutils cross-built with uclibc.

This involved fixing some buildInputs/buildNativeInputs in acl/attr,
and adding a libiconv in some places.


svn path=/nixpkgs/branches/stdenv-updates/; revision=20510
This commit is contained in:
Lluís Batlle i Rossell 2010-03-09 18:05:38 +00:00
parent 70b2dd393c
commit 6f9a783232
6 changed files with 25 additions and 5 deletions

View File

@ -8,7 +8,8 @@ stdenv.mkDerivation {
sha256 = "1j39g62fki0iyji9s62slgwdfskpkqy7rmjlqcnmsvsnxbxhc294";
};
buildInputs = [gettext attr libtool];
buildNativeInputs = [gettext];
buildInputs = [attr libtool];
configureFlags = "MAKE=make LIBTOOL=libtool MSGFMT=msgfmt MSGMERGE=msgmerge XGETTEXT=xgettext ZIP=gzip ECHO=echo SED=sed AWK=gawk";

View File

@ -9,7 +9,8 @@ stdenv.mkDerivation {
sha256 = "1gy5zspj8ynxv6q29r24d18cfvq06zirg1pxcdg27bg2ncrv4n6k";
};
buildInputs = [libtool gettext];
buildNativeInputs = [gettext];
buildInputs = [libtool];
configureFlags = "MAKE=make LIBTOOL=libtool MSGFMT=msgfmt MSGMERGE=msgmerge XGETTEXT=xgettext ECHO=echo SED=sed AWK=gawk";

View File

@ -21,6 +21,11 @@ stdenv.mkDerivation (rec {
fi
'';
crossAttrs = {
buildInputs = stdenv.lib.optional (stdenv.gccCross.libc ? libiconv)
stdenv.gccCross.libc.libiconv.hostDrv;
};
meta = {
description = "GNU gettext, a well integrated set of translation tools and documentation";

View File

@ -1,4 +1,4 @@
{stdenv, fetchurl, linuxHeaders, cross ? null, gccCross ? null}:
{stdenv, fetchurl, linuxHeaders, libiconv, cross ? null, gccCross ? null}:
assert stdenv.isLinux;
assert cross != null -> gccCross != null;
@ -59,6 +59,11 @@ stdenv.mkDerivation {
sed -i s@/lib/@$out/lib/@g $out/lib/libc.so
'';
passthru = {
# Derivations may check for the existance of this attribute, to know what to link to.
inherit libiconv;
};
meta = {
homepage = http://www.uclibc.org/;
description = "A small implementation of the C library";

View File

@ -8,7 +8,15 @@ stdenv.mkDerivation rec {
sha256 = "0zq11lykc7hfs9nsdnb8gqk354l82hswqj38607mvwj3b0zqvc4b";
};
buildInputs = [ perl gmp ] ++ stdenv.lib.optional aclSupport acl;
buildNativeInputs = [ perl ];
buildInputs = [ gmp ] ++ stdenv.lib.optional aclSupport acl;
crossAttrs = {
buildInputs = [ gmp ]
++ stdenv.lib.optional aclSupport acl.hostDrv
++ stdenv.lib.optional (stdenv.gccCross.libc ? libiconv)
stdenv.gccCross.libc.libiconv.hostDrv;
};
# The tests are known broken on Cygwin
# (http://thread.gmane.org/gmane.comp.gnu.core-utils.bugs/19025),

View File

@ -6401,7 +6401,7 @@ let
*/
uclibcCross = import ../os-specific/linux/uclibc {
inherit fetchurl stdenv;
inherit fetchurl stdenv libiconv;
linuxHeaders = linuxHeadersCross;
gccCross = gccCrossStageStatic;
cross = assert crossSystem != null; crossSystem;