coreutils: fixing cross-build
coreutils can't generate the man pages cross-building. I do a trick to get them from a non-cross-built coreutils.
This commit is contained in:
parent
d8f98d1a85
commit
91a94932d9
@ -6,7 +6,8 @@
|
||||
assert aclSupport -> acl != null;
|
||||
assert selinuxSupport -> libselinux != null && libsepol != null;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
let
|
||||
self = stdenv.mkDerivation rec {
|
||||
name = "coreutils-8.21";
|
||||
|
||||
src = fetchurl {
|
||||
@ -28,6 +29,20 @@ stdenv.mkDerivation rec {
|
||||
++ stdenv.lib.optional (stdenv.gccCross.libc ? libiconv)
|
||||
stdenv.gccCross.libc.libiconv.crossDrv;
|
||||
|
||||
buildPhase = ''
|
||||
make || (
|
||||
pushd man
|
||||
for a in *.x; do
|
||||
touch `basename $a .x`.1
|
||||
done
|
||||
popd; make )
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
rm $out/share/man/man1/*
|
||||
cp ${self}/share/man/man1/* $out/share/man/man1
|
||||
'';
|
||||
|
||||
# Needed for fstatfs()
|
||||
# I don't know why it is not properly detected cross building with glibc.
|
||||
configureFlags = [ "fu_cv_sys_stat_statfs2_bsize=yes" ];
|
||||
@ -59,4 +74,6 @@ stdenv.mkDerivation rec {
|
||||
|
||||
maintainers = [ stdenv.lib.maintainers.ludo ];
|
||||
};
|
||||
}
|
||||
};
|
||||
in
|
||||
self
|
||||
|
Loading…
x
Reference in New Issue
Block a user