haskellPackages.dyre: fix build by removing out-dated patch and pulling from upstream
This commit is contained in:
parent
408d7aabb4
commit
8f9f70446e
2 changed files with 12 additions and 27 deletions
|
@ -259,8 +259,18 @@ self: super: builtins.intersectAttrs super {
|
|||
'';
|
||||
}));
|
||||
|
||||
# Patch to consider NIX_GHC just like xmonad does
|
||||
dyre = appendPatch super.dyre ./patches/dyre-nix.patch;
|
||||
dyre =
|
||||
appendPatch
|
||||
# dyre's tests appear to be trying to directly call GHC.
|
||||
(dontCheck super.dyre)
|
||||
# Dyre needs special support for reading the NIX_GHC env var. This is
|
||||
# available upstream in https://github.com/willdonnelly/dyre/pull/43, but
|
||||
# hasn't been released to Hackage as of dyre-0.9.1. Likely included in
|
||||
# next version.
|
||||
(pkgs.fetchpatch {
|
||||
url = "https://github.com/willdonnelly/dyre/commit/c7f29d321aae343d6b314f058812dffcba9d7133.patch";
|
||||
sha256 = "10m22k35bi6cci798vjpy4c2l08lq5nmmj24iwp0aflvmjdgscdb";
|
||||
});
|
||||
|
||||
# https://github.com/edwinb/EpiVM/issues/13
|
||||
# https://github.com/edwinb/EpiVM/issues/14
|
||||
|
|
|
@ -1,25 +0,0 @@
|
|||
--- dyre-0.8.12/Config/Dyre/Compile.hs 2015-04-13 11:00:20.794278350 +0100
|
||||
+++ dyre-0.8.12-patched/Config/Dyre/Compile.hs 2015-04-13 11:07:26.938893502 +0100
|
||||
@@ -10,11 +10,13 @@
|
||||
import System.FilePath ( (</>) )
|
||||
import System.Directory ( getCurrentDirectory, doesFileExist
|
||||
, createDirectoryIfMissing )
|
||||
+import System.Environment ( lookupEnv )
|
||||
+import Control.Applicative ((<$>))
|
||||
import Control.Exception ( bracket )
|
||||
-import GHC.Paths ( ghc )
|
||||
|
||||
import Config.Dyre.Paths ( getPaths )
|
||||
import Config.Dyre.Params ( Params(..) )
|
||||
+import Data.Maybe ( fromMaybe )
|
||||
|
||||
-- | Return the path to the error file.
|
||||
getErrorPath :: Params cfgType -> IO FilePath
|
||||
@@ -47,6 +49,7 @@
|
||||
errFile <- getErrorPath params
|
||||
result <- bracket (openFile errFile WriteMode) hClose $ \errHandle -> do
|
||||
ghcOpts <- makeFlags params configFile tempBinary cacheDir libsDir
|
||||
+ ghc <- fromMaybe "ghc" <$> lookupEnv "NIX_GHC"
|
||||
ghcProc <- runProcess ghc ghcOpts (Just cacheDir) Nothing
|
||||
Nothing Nothing (Just errHandle)
|
||||
waitForProcess ghcProc
|
Loading…
Reference in a new issue