From 4541b1090491a7ab74d74a5ebee31bd3ccf1be63 Mon Sep 17 00:00:00 2001 From: Matthew Pickering Date: Sat, 24 Dec 2016 17:37:58 +0000 Subject: [PATCH] Refactor ghcHEAD postPatch / preConfigure phases This is for GHC developers using NixOS where patchShebangs is inconvenient as it dirties the tree but unnecessary for compilation. --- pkgs/development/compilers/ghc/head.nix | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/pkgs/development/compilers/ghc/head.nix b/pkgs/development/compilers/ghc/head.nix index 0deabd0fa98..0581038d18d 100644 --- a/pkgs/development/compilers/ghc/head.nix +++ b/pkgs/development/compilers/ghc/head.nix @@ -27,19 +27,18 @@ in stdenv.mkDerivation (rec { sha256 = "0rk6xy7kgxx849nprq1ji459p88nyy93236g841m5p6mdh7mmrcr"; }; - postPatch = '' + postPatch = "patchShebangs ."; + + preConfigure = '' echo ${version} >VERSION echo ${rev} >GIT_COMMIT_ID - patchShebangs . ./boot - ''; + '' + commonPreConfigure ; buildInputs = commonBuildInputs; enableParallelBuilding = true; - preConfigure = commonPreConfigure; - configureFlags = [ "CC=${stdenv.cc}/bin/cc" "--with-gmp-includes=${gmp.dev}/include" "--with-gmp-libraries=${gmp.out}/lib"