* Pass makeFlags to `make install' as well. This is because quite

often the same flags need to be passed to both `make' and `make
  install'.  Added a variable buildFlags for flags that should only be
  passed to `make'.

svn path=/nixpkgs/trunk/; revision=7491
This commit is contained in:
Eelco Dolstra 2006-12-27 17:30:40 +00:00
parent 81025a05df
commit ed8fff32af
2 changed files with 9 additions and 5 deletions

View File

@ -9,7 +9,7 @@ stdenv.mkDerivation {
preBuild = " preBuild = "
substituteInPlace libcap/Makefile --replace /usr/include ${stdenv.glibc}/include substituteInPlace libcap/Makefile --replace /usr/include ${stdenv.glibc}/include
installFlags=\"LIBDIR=$out/lib INCDIR=$out/include SBINDIR=$out/sbin MANDIR=$out/man\" makeFlags=\"LIBDIR=$out/lib INCDIR=$out/include SBINDIR=$out/sbin MANDIR=$out/man\"
"; ";
patches = [ patches = [

View File

@ -566,8 +566,10 @@ buildW() {
eval "$preBuild" eval "$preBuild"
echo "make flags: $makeFlags ${makeFlagsArray[@]}" echo "make flags: $makeFlags ${makeFlagsArray[@]} $buildFlags ${buildFlagsArray[@]}"
make $makeFlags "${makeFlagsArray[@]}" || fail make \
$makeFlags "${makeFlagsArray[@]}" \
$buildFlags "${buildFlagsArray[@]}" || fail
eval "$postBuild" eval "$postBuild"
} }
@ -638,8 +640,10 @@ installW() {
if test -z "$installTargets"; then if test -z "$installTargets"; then
installTargets=install installTargets=install
fi fi
echo "install flags: $installTargets $installFlags ${installFlagsArray[@]}" echo "install flags: $installTargets $makeFlags ${makeFlagsArray[@]} $installFlags ${installFlagsArray[@]}"
make $installTargets $installFlags "${installFlagsArray[@]}" || fail make $installTargets \
$makeFlags ${makeFlagsArray[@]} \
$installFlags "${installFlagsArray[@]}" || fail
fi fi
else else
eval "$installCommand" eval "$installCommand"