forked from mirrors/nixpkgs
Merge pull request #48699 from ElvishJerricco/overridable-buildFromSdist
haskell.lib.buildFromSdist: Allow overrideCabal
This commit is contained in:
commit
945c6b9981
|
@ -245,12 +245,13 @@ rec {
|
||||||
on hackage. This can be used as a test for the source distribution,
|
on hackage. This can be used as a test for the source distribution,
|
||||||
assuming the build fails when packaging mistakes are in the cabal file.
|
assuming the build fails when packaging mistakes are in the cabal file.
|
||||||
*/
|
*/
|
||||||
buildFromSdist = pkg: lib.overrideDerivation pkg (drv: {
|
buildFromSdist = pkg: overrideCabal pkg (drv: {
|
||||||
unpackPhase = let src = sdistTarball pkg; tarname = "${pkg.pname}-${pkg.version}"; in ''
|
src = "${sdistTarball pkg}/${pkg.pname}-${pkg.version}.tar.gz";
|
||||||
echo "Source tarball is at ${src}/${tarname}.tar.gz"
|
|
||||||
tar xf ${src}/${tarname}.tar.gz
|
# Revising and jailbreaking the cabal file has been handled in sdistTarball
|
||||||
cd ${pkg.pname}-*
|
revision = null;
|
||||||
'';
|
editedCabalFile = null;
|
||||||
|
jailbreak = false;
|
||||||
});
|
});
|
||||||
|
|
||||||
/* Build the package in a strict way to uncover potential problems.
|
/* Build the package in a strict way to uncover potential problems.
|
||||||
|
|
Loading…
Reference in a new issue