GNU Hurd: Restructure for easier overriding, and easier avoided rebuilds.
svn path=/nixpkgs/trunk/; revision=33834
This commit is contained in:
parent
f59b9490ec
commit
61bb81195f
@ -40,18 +40,17 @@ stdenv.mkDerivation ({
|
|||||||
then [ "--with-parted" ]
|
then [ "--with-parted" ]
|
||||||
else [ "--without-parted" ]);
|
else [ "--without-parted" ]);
|
||||||
|
|
||||||
preConfigure = "autoreconf -vfi";
|
preConfigure =
|
||||||
|
'' autoreconf -vfi
|
||||||
|
|
||||||
patchPhase =
|
echo "removing \`-o root' from makefiles..."
|
||||||
'' echo "removing \`-o root' from makefiles..."
|
|
||||||
for mf in {utils,daemons}/Makefile
|
for mf in {utils,daemons}/Makefile
|
||||||
do
|
do
|
||||||
sed -i "$mf" -e's/-o root//g'
|
sed -i "$mf" -e's/-o root//g'
|
||||||
done
|
done
|
||||||
'';
|
'';
|
||||||
|
|
||||||
buildPhase = "make ${buildTarget}";
|
crossAttrs.dontPatchShebangs = true;
|
||||||
installPhase = "make ${installTarget}";
|
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
description = "The GNU Hurd, GNU project's replacement for the Unix kernel";
|
description = "The GNU Hurd, GNU project's replacement for the Unix kernel";
|
||||||
@ -74,6 +73,17 @@ stdenv.mkDerivation ({
|
|||||||
|
|
||||||
//
|
//
|
||||||
|
|
||||||
|
(if !headersOnly && buildTarget != null
|
||||||
|
then assert installTarget != null; {
|
||||||
|
# Use the default `buildPhase' and `installPhase' so that the usual hooks
|
||||||
|
# can still be used.
|
||||||
|
buildFlags = buildTarget;
|
||||||
|
installTargets = installTarget;
|
||||||
|
}
|
||||||
|
else {})
|
||||||
|
|
||||||
|
//
|
||||||
|
|
||||||
(if headersOnly
|
(if headersOnly
|
||||||
then { buildPhase = ":"; installPhase = "make install-headers"; }
|
then { buildPhase = ":"; installPhase = "make install-headers"; }
|
||||||
else (if (cross != null)
|
else (if (cross != null)
|
||||||
|
Loading…
Reference in New Issue
Block a user