moved finalPhase so it is possible to override through args

svn path=/nixpkgs/trunk/; revision=15977
This commit is contained in:
Rob Vermaas 2009-06-17 07:02:59 +00:00
parent 891991a1d9
commit cd2c0b26ad

View File

@ -24,6 +24,15 @@ stdenv.mkDerivation (
# Hack - swap checkPhase and installPhase (otherwise Stratego barfs).
phases = "unpackPhase patchPhase configurePhase buildPhase installPhase checkPhase fixupPhase distPhase ${if doCoverageAnalysis then "coverageReportPhase" else ""} finalPhase";
finalPhase =
''
# Propagate the release name of the source tarball. This is
# to get nice package names in channels.
if test -e $origSrc/nix-support/hydra-release-name; then
cp $origSrc/nix-support/hydra-release-name $out/nix-support/hydra-release-name
fi
'';
}
// args //
@ -77,16 +86,6 @@ stdenv.mkDerivation (
lcovFilter = ["/nix/store/*"] ++ lcovFilter;
finalPhase =
''
# Propagate the release name of the source tarball. This is
# to get nice package names in channels.
if test -e $origSrc/nix-support/hydra-release-name; then
cp $origSrc/nix-support/hydra-release-name $out/nix-support/hydra-release-name
fi
'';
meta = (if args ? meta then args.meta else {}) // {
description = if doCoverageAnalysis then "Coverage analysis" else "Native Nix build on ${stdenv.system}";
};