haskell-packages: made darcs compile with ghc 8.8

authored by David Guibert and committed by Peter Simons 8ab67c7a 7c1c9dcc

+460 -4
+6 -3
pkgs/development/haskell-modules/configuration-common.nix
··· 45 45 # Needs older QuickCheck version 46 46 attoparsec-varword = dontCheck super.attoparsec-varword; 47 47 48 + # http://bugs.darcs.net/issue2642 49 + darcs = doJailbreak (appendPatches super.darcs [ 50 + ./patches/darcs-setup.patch 51 + ./patches/darcs-2.14.2-Compile-against-GHC-8.8.patch 52 + ]); 53 + 48 54 # Tests are failing 49 55 # https://github.com/bos/statistics/issues/123 50 56 statistics = dontCheck super.statistics; ··· 1504 1510 # version of Polysemy the plugin goes with 1505 1511 polysemy = self.polysemy_1_3_0_0; 1506 1512 }; 1507 - 1508 - # Fixed at head, but hasn't cut a release in awhile. 1509 - darcs = doJailbreak super.darcs; 1510 1513 1511 1514 # Test suite requires running a database server. Testing is done upstream. 1512 1515 hasql-pool = dontCheck super.hasql-pool;
+333
pkgs/development/haskell-modules/patches/darcs-2.14.2-Compile-against-GHC-8.8.patch
··· 1 + From 2490fa65eeba52699a7c0e303aa5cb9b78c2b1cf Mon Sep 17 00:00:00 2001 2 + From: =?UTF-8?q?Niklas=20Hamb=C3=BCchen?= <mail@nh2.me> 3 + Date: Fri, 17 Apr 2020 20:49:23 +0200 4 + Subject: [PATCH] Compile against GHC 8.8 5 + 6 + --- 7 + Setup.hs | 15 --------------- 8 + src/Darcs/Patch/Depends.hs | 2 +- 9 + src/Darcs/Patch/Match.hs | 12 ++++++------ 10 + src/Darcs/Patch/PatchInfoAnd.hs | 2 +- 11 + src/Darcs/Patch/Prim/V1/Apply.hs | 6 +++--- 12 + src/Darcs/Patch/Prim/V1/Commute.hs | 1 + 13 + src/Darcs/Patch/ReadMonads.hs | 1 + 14 + src/Darcs/Patch/V1/Commute.hs | 1 + 15 + src/Darcs/Repository/Diff.hs | 2 +- 16 + src/Darcs/Repository/Match.hs | 2 +- 17 + src/Darcs/Util/Tree/Monad.hs | 4 ++-- 18 + 12 files changed, 30 insertions(+), 42 deletions(-) 19 + 20 + diff --git a/Setup.hs b/Setup.hs 21 + index f5cc3e8..05caac4 100644 22 + --- a/Setup.hs 23 + +++ b/Setup.hs 24 + @@ -75,21 +75,6 @@ 25 + postInst = \ _ flags pkg lbi -> 26 + installManpage pkg lbi (fromFlag $ installVerbosity flags) NoCopyDest, 27 + 28 + - sDistHook = \ pkg lbi hooks flags -> do 29 + - let pkgVer = packageVersion pkg 30 + - verb = fromFlag $ sDistVerbosity flags 31 + - x <- versionPatches verb pkgVer 32 + - y <- context verb 33 + - rewriteFileEx silent "release/distributed-version" $ show x 34 + - rewriteFileEx silent "release/distributed-context" $ show y 35 + - putStrLn "about to hand over" 36 + - let pkg' = pkg { library = sanity (library pkg) } 37 + - sanity (Just lib) = Just $ lib { libBuildInfo = sanity' $ libBuildInfo lib } 38 + - sanity _ = error "eh" 39 + - sanity' bi = bi { otherModules = [ m | m <- otherModules bi, toFilePath m /= "Version" ] } 40 + - 41 + - sDistHook simpleUserHooks pkg' lbi hooks flags 42 + - , 43 + postConf = \_ _ _ _ -> return () --- Usually this checked for external C 44 + --- dependencies, but we already have performed such 45 + --- check in the confHook 46 + --- a/darcs.cabal 1970-01-01 01:00:01.000000000 +0100 47 + +++ b/darcs.cabal 2020-04-18 10:26:07.605129733 +0200 48 + @@ -1,6 +1,5 @@ 49 + Name: darcs 50 + version: 2.14.2 51 + -x-revision: 1 52 + License: GPL-2 53 + License-file: COPYING 54 + Author: David Roundy <droundy@darcs.net>, <darcs-devel@darcs.net> 55 + @@ -75,7 +74,7 @@ 56 + description: Use libcurl for HTTP support. 57 + 58 + -- in future this could extend to any other external libraries, 59 + --- e.g. libiconv 60 + +-- e.g. libiconv 61 + flag pkgconfig 62 + description: Use pkgconfig to configure libcurl 63 + default: False 64 + @@ -113,7 +112,7 @@ 65 + -- ---------------------------------------------------------------------- 66 + 67 + custom-setup 68 + - setup-depends: base >= 4.9 && < 4.13, 69 + + setup-depends: base >= 4.9 && <5, 70 + Cabal >= 1.24, 71 + process >= 1.2.3.0 && < 1.7, 72 + filepath >= 1.4.1 && < 1.5.0.0, 73 + @@ -381,7 +380,7 @@ 74 + else 75 + build-depends: unix >= 2.7.1.0 && < 2.8 76 + 77 + - build-depends: base >= 4.9 && < 4.13, 78 + + build-depends: base >= 4.9 && <5, 79 + stm >= 2.1 && < 2.6, 80 + binary >= 0.5 && < 0.10, 81 + containers >= 0.5.6.2 && < 0.7, 82 + @@ -402,19 +401,19 @@ 83 + tar >= 0.5 && < 0.6, 84 + data-ordlist == 0.4.*, 85 + attoparsec >= 0.13.0.1 && < 0.14, 86 + - zip-archive >= 0.3 && < 0.5, 87 + + zip-archive >= 0.3 && <1, 88 + async >= 2.0.2 && < 2.3, 89 + - sandi >= 0.4 && < 0.6, 90 + + sandi >= 0.4 && <1, 91 + unix-compat >= 0.4.2 && < 0.6, 92 + bytestring >= 0.10.6 && < 0.11, 93 + old-time >= 1.1.0.3 && < 1.2, 94 + time >= 1.5.0.1 && < 1.10, 95 + - text >= 1.2.1.3 && < 1.3, 96 + + text >= 1.2.1.3 && <2, 97 + directory >= 1.2.6.2 && < 1.4, 98 + process >= 1.2.3.0 && < 1.7, 99 + array >= 0.5.1.0 && < 0.6, 100 + random >= 1.1 && < 1.2, 101 + - hashable >= 1.2.3.3 && < 1.3, 102 + + hashable >= 1.2.3.3 && <2, 103 + mmap >= 0.5.9 && < 0.6, 104 + zlib >= 0.6.1.2 && < 0.7.0.0, 105 + network-uri == 2.6.*, 106 + @@ -443,7 +442,7 @@ 107 + 108 + -- The terminfo package cannot be built on Windows. 109 + if flag(terminfo) && !os(windows) 110 + - build-depends: terminfo >= 0.4.0.2 && < 0.5 111 + + build-depends: terminfo >= 0.4.0.2 && <1 112 + cpp-options: -DHAVE_TERMINFO 113 + 114 + default-extensions: 115 + @@ -500,7 +499,7 @@ 116 + cc-options: -D_REENTRANT 117 + 118 + build-depends: darcs, 119 + - base >= 4.9 && < 4.13 120 + + base >= 4.9 && <5 121 + 122 + -- ---------------------------------------------------------------------- 123 + -- unit test driver 124 + @@ -518,7 +517,7 @@ 125 + build-depends: Win32 >= 2.3.1 && < 2.4 126 + 127 + build-depends: darcs, 128 + - base >= 4.9 && < 4.13, 129 + + base >= 4.9 && <5, 130 + array >= 0.5.1.0 && < 0.6, 131 + bytestring >= 0.10.6 && < 0.11, 132 + cmdargs >= 0.10.10 && < 0.11, 133 + @@ -527,15 +526,15 @@ 134 + mtl >= 2.2.1 && < 2.3, 135 + shelly >= 1.6.8 && < 1.9, 136 + split >= 0.2.2 && < 0.3, 137 + - text >= 1.2.1.3 && < 1.3, 138 + + text >= 1.2.1.3 && <2, 139 + directory >= 1.2.6.2 && < 1.4, 140 + FindBin >= 0.0.5 && < 0.1, 141 + - QuickCheck >= 2.8.2 && < 2.13, 142 + + QuickCheck >= 2.8.2 && <3, 143 + HUnit >= 1.3 && < 1.7, 144 + test-framework >= 0.8.1.1 && < 0.9, 145 + test-framework-hunit >= 0.3.0.2 && < 0.4, 146 + test-framework-quickcheck2 >= 0.3.0.3 && < 0.4, 147 + - zip-archive >= 0.3 && < 0.5 148 + + zip-archive >= 0.3 && <1 149 + 150 + -- https://github.com/yesodweb/Shelly.hs/issues/177 151 + if os(windows) 152 + diff --git a/src/Darcs/Patch/Depends.hs b/src/Darcs/Patch/Depends.hs 153 + index 8531294..a4c71cb 100644 154 + --- a/src/Darcs/Patch/Depends.hs 155 + +++ b/src/Darcs/Patch/Depends.hs 156 + @@ -251,7 +251,7 @@ splitOnTag _ (PatchSet NilRL NilRL) = Nothing 157 + unwrapOneTagged :: (Monad m) => PatchSet rt p wX wY -> m (PatchSet rt p wX wY) 158 + unwrapOneTagged (PatchSet (ts :<: Tagged t _ tps) ps) = 159 + return $ PatchSet ts (tps :<: t +<+ ps) 160 + -unwrapOneTagged _ = fail "called unwrapOneTagged with no Tagged's in the set" 161 + +unwrapOneTagged _ = error "called unwrapOneTagged with no Tagged's in the set" 162 + 163 + -- | @getUncovered ps@ returns the 'PatchInfo' for all the patches in 164 + -- @ps@ that are not depended on by anything else *through explicit 165 + diff --git a/src/Darcs/Patch/Match.hs b/src/Darcs/Patch/Match.hs 166 + index aba6c7a..2b6f53a 100644 167 + --- a/src/Darcs/Patch/Match.hs 168 + +++ b/src/Darcs/Patch/Match.hs 169 + @@ -421,7 +421,7 @@ getNonrangeMatchS fs repo = 170 + Just m -> if nonrangeMatcherIsTag fs 171 + then getTagS m repo 172 + else getMatcherS Exclusive m repo 173 + - Nothing -> fail "Pattern not specified in getNonrangeMatch." 174 + + Nothing -> error "Pattern not specified in getNonrangeMatch." 175 + 176 + -- | @firstMatch fs@ tells whether @fs@ implies a "first match", that 177 + -- is if we match against patches from a point in the past on, rather 178 + @@ -441,7 +441,7 @@ getFirstMatchS fs repo = 179 + Just (_,b) -> unpullLastN repo b -- b is chronologically earlier than a 180 + Nothing -> 181 + case firstMatcher fs of 182 + - Nothing -> fail "Pattern not specified in getFirstMatchS." 183 + + Nothing -> error "Pattern not specified in getFirstMatchS." 184 + Just m -> if firstMatcherIsTag fs 185 + then getTagS m repo 186 + else getMatcherS Inclusive m repo 187 + @@ -462,7 +462,7 @@ checkMatchSyntax :: [MatchFlag] -> IO () 188 + checkMatchSyntax opts = 189 + case getMatchPattern opts of 190 + Nothing -> return () 191 + - Just p -> either fail (const $ return ()) (parseMatch p::Either String (MatchFun rt DummyPatch)) 192 + + Just p -> either error (const $ return ()) (parseMatch p::Either String (MatchFun rt DummyPatch)) 193 + 194 + getMatchPattern :: [MatchFlag] -> Maybe String 195 + getMatchPattern [] = Nothing 196 + @@ -718,7 +718,7 @@ getMatcherS :: (ApplyMonad (ApplyState p) m, Matchable p) => 197 + getMatcherS ioe m repo = 198 + if matchExists m repo 199 + then applyInvToMatcher ioe m repo 200 + - else fail $ "Couldn't match pattern "++ show m 201 + + else error $ "Couldn't match pattern "++ show m 202 + 203 + getTagS :: (ApplyMonad (ApplyState p) m, MonadProgress m, Matchable p) => 204 + Matcher rt p -> PatchSet rt p Origin wX -> m () 205 + diff --git a/src/Darcs/Patch/PatchInfoAnd.hs b/src/Darcs/Patch/PatchInfoAnd.hs 206 + index 2da7ec8..1147410 100644 207 + --- a/src/Darcs/Patch/PatchInfoAnd.hs 208 + +++ b/src/Darcs/Patch/PatchInfoAnd.hs 209 + @@ -167,7 +167,7 @@ conscientiously er (PIAP pinf hp) = 210 + 211 + -- | @hopefullyM@ is a version of @hopefully@ which calls @fail@ in a 212 + -- monad instead of erroring. 213 + -hopefullyM :: Monad m => PatchInfoAnd rt p wA wB -> m (WrappedNamed rt p wA wB) 214 + +hopefullyM :: MonadFail m => PatchInfoAnd rt p wA wB -> m (WrappedNamed rt p wA wB) 215 + hopefullyM (PIAP pinf hp) = case hopefully2either hp of 216 + Right p -> return p 217 + Left e -> fail $ renderString 218 + diff --git a/src/Darcs/Patch/Prim/V1/Apply.hs b/src/Darcs/Patch/Prim/V1/Apply.hs 219 + index bea7e41..7984d21 100644 220 + --- a/src/Darcs/Patch/Prim/V1/Apply.hs 221 + +++ b/src/Darcs/Patch/Prim/V1/Apply.hs 222 + @@ -41,13 +41,13 @@ instance Apply Prim where 223 + apply (FP f (TokReplace t o n)) = mModifyFilePS f doreplace 224 + where doreplace fc = 225 + case tryTokReplace t (BC.pack o) (BC.pack n) fc of 226 + - Nothing -> fail $ "replace patch to " ++ fn2fp f 227 + + Nothing -> error $ "replace patch to " ++ fn2fp f 228 + ++ " couldn't apply." 229 + Just fc' -> return fc' 230 + apply (FP f (Binary o n)) = mModifyFilePS f doapply 231 + where doapply oldf = if o == oldf 232 + then return n 233 + - else fail $ "binary patch to " ++ fn2fp f 234 + + else error $ "binary patch to " ++ fn2fp f 235 + ++ " couldn't apply." 236 + apply (DP d AddDir) = mCreateDirectory d 237 + apply (DP d RmDir) = mRemoveDirectory d 238 + @@ -115,7 +115,7 @@ applyHunk f h fc = 239 + case applyHunkLines h fc of 240 + Right fc' -> return fc' 241 + Left msg -> 242 + - fail $ 243 + + error $ 244 + "### Error applying:\n" ++ renderHunk h ++ 245 + "\n### to file " ++ fn2fp f ++ ":\n" ++ BC.unpack fc ++ 246 + "### Reason: " ++ msg 247 + diff --git a/src/Darcs/Patch/Prim/V1/Commute.hs b/src/Darcs/Patch/Prim/V1/Commute.hs 248 + index 7639dbd..e1432e6 100644 249 + --- a/src/Darcs/Patch/Prim/V1/Commute.hs 250 + +++ b/src/Darcs/Patch/Prim/V1/Commute.hs 251 + @@ -58,6 +58,7 @@ instance Monad Perhaps where 252 + Failed >>= _ = Failed 253 + Unknown >>= _ = Unknown 254 + return = Succeeded 255 + +instance MonadFail Perhaps where 256 + fail _ = Unknown 257 + 258 + instance Alternative Perhaps where 259 + diff --git a/src/Darcs/Patch/ReadMonads.hs b/src/Darcs/Patch/ReadMonads.hs 260 + index 62a4f81..e1cb149 100644 261 + --- a/src/Darcs/Patch/ReadMonads.hs 262 + +++ b/src/Darcs/Patch/ReadMonads.hs 263 + @@ -237,6 +237,7 @@ failSM _ = SM (\_ -> Nothing) 264 + instance Monad SM where 265 + (>>=) = bindSM 266 + return = returnSM 267 + +instance MonadFail SM where 268 + fail = failSM 269 + 270 + instance ParserM SM where 271 + diff --git a/src/Darcs/Patch/V1/Commute.hs b/src/Darcs/Patch/V1/Commute.hs 272 + index 0bb41a3..c6c3382 100644 273 + --- a/src/Darcs/Patch/V1/Commute.hs 274 + +++ b/src/Darcs/Patch/V1/Commute.hs 275 + @@ -93,6 +93,7 @@ instance Monad Perhaps where 276 + Failed >>= _ = Failed 277 + Unknown >>= _ = Unknown 278 + return = Succeeded 279 + +instance MonadFail Perhaps where 280 + fail _ = Unknown 281 + 282 + instance Alternative Perhaps where 283 + diff --git a/src/Darcs/Repository/Diff.hs b/src/Darcs/Repository/Diff.hs 284 + index 8078d49..e0e2341 100644 285 + --- a/src/Darcs/Repository/Diff.hs 286 + +++ b/src/Darcs/Repository/Diff.hs 287 + @@ -138,7 +138,7 @@ treeDiff da ft t1 t2 = do 288 + do rmDirP <- diff p (Removed subtree) 289 + addFileP <- diff p (Changed (File emptyBlob) b') 290 + return $ joinGap (+>+) rmDirP addFileP 291 + - diff p _ = fail $ "Missing case at path " ++ show p 292 + + diff p _ = error $ "Missing case at path " ++ show p 293 + 294 + text_diff p a b 295 + | BL.null a && BL.null b = emptyGap NilFL 296 + diff --git a/src/Darcs/Repository/Match.hs b/src/Darcs/Repository/Match.hs 297 + index 08c9f13..f33cabe 100644 298 + --- a/src/Darcs/Repository/Match.hs 299 + +++ b/src/Darcs/Repository/Match.hs 300 + @@ -60,7 +60,7 @@ getNonrangeMatch :: (ApplyMonad (ApplyState p) DefaultIO, IsRepoType rt, RepoPat 301 + getNonrangeMatch r = withRecordedMatch r . getMatch where 302 + getMatch fs = case hasIndexRange fs of 303 + Just (n, m) | n == m -> applyNInv (n-1) 304 + - | otherwise -> fail "Index range is not allowed for this command." 305 + + | otherwise -> error "Index range is not allowed for this command." 306 + _ -> getNonrangeMatchS fs 307 + 308 + getOnePatchset :: (IsRepoType rt, RepoPatch p) 309 + diff --git a/src/Darcs/Util/Tree/Monad.hs b/src/Darcs/Util/Tree/Monad.hs 310 + index 0e01d9b..296fdc4 100644 311 + --- a/src/Darcs/Util/Tree/Monad.hs 312 + +++ b/src/Darcs/Util/Tree/Monad.hs 313 + @@ -216,7 +216,7 @@ instance (Monad m) => TreeRO (TreeMonad m) where 314 + t <- gets tree 315 + let f = findFile t p' 316 + case f of 317 + - Nothing -> fail $ "No such file " ++ show p' 318 + + Nothing -> error $ "No such file " ++ show p' 319 + Just x -> lift (readBlob x) 320 + 321 + currentDirectory = ask 322 + @@ -251,7 +251,7 @@ instance (Monad m) => TreeRW (TreeMonad m) where 323 + let item = find tr from' 324 + found_to = find tr to' 325 + unless (isNothing found_to) $ 326 + - fail $ "Error renaming: destination " ++ show to ++ " exists." 327 + + error $ "Error renaming: destination " ++ show to ++ " exists." 328 + unless (isNothing item) $ do 329 + modifyItem from Nothing 330 + modifyItem to item 331 + -- 332 + 2.23.1 333 +
+120
pkgs/development/haskell-modules/patches/darcs-setup.patch
··· 1 + --- darcs-2.14.2/Setup.hs 2019-01-27 03:14:51.000000000 +1300 2 + +++ darcs.net/Setup.hs 2019-10-18 02:41:57.000000000 +1300 3 + @@ -11,7 +11,9 @@ 4 + , TestSuite(testBuildInfo) 5 + , updatePackageDescription 6 + , cppOptions, ccOptions 7 + - , library, libBuildInfo, otherModules ) 8 + + , library, libBuildInfo, otherModules 9 + + , ComponentName(CExeName) 10 + + ) 11 + import Distribution.Package 12 + ( packageVersion ) 13 + import Distribution.Version( Version ) 14 + @@ -21,24 +23,27 @@ 15 + import Distribution.Simple.Setup 16 + (buildVerbosity, copyDest, copyVerbosity, fromFlag, 17 + haddockVerbosity, installVerbosity, sDistVerbosity, replVerbosity ) 18 + -import Distribution.Simple.BuildPaths ( autogenModulesDir ) 19 + +import Distribution.Simple.BuildPaths ( autogenPackageModulesDir ) 20 + import Distribution.System 21 + ( OS(Windows), buildOS ) 22 + import Distribution.Simple.Utils 23 + (copyFiles, createDirectoryIfMissingVerbose, rawSystemStdout, 24 + - rewriteFile ) 25 + + rewriteFileEx) 26 + +import Distribution.Types.UnqualComponentName 27 + import Distribution.Verbosity 28 + - ( Verbosity ) 29 + + ( Verbosity, silent ) 30 + import Distribution.Text 31 + ( display ) 32 + -import Control.Monad ( unless, void ) 33 + 34 + +import Control.Monad ( unless, when, void ) 35 + import System.Directory 36 + ( doesDirectoryExist, doesFileExist ) 37 + import System.IO 38 + ( openFile, IOMode(..) ) 39 + import System.Process (runProcess) 40 + import Data.List( isInfixOf, lines ) 41 + +import qualified Data.Map as M 42 + +import Data.Maybe ( isJust ) 43 + import System.FilePath ( (</>) ) 44 + import Foreign.Marshal.Utils ( with ) 45 + import Foreign.Storable ( peek ) 46 + @@ -75,8 +80,8 @@ 47 + verb = fromFlag $ sDistVerbosity flags 48 + x <- versionPatches verb pkgVer 49 + y <- context verb 50 + - rewriteFile "release/distributed-version" $ show x 51 + - rewriteFile "release/distributed-context" $ show y 52 + + rewriteFileEx silent "release/distributed-version" $ show x 53 + + rewriteFileEx silent "release/distributed-context" $ show y 54 + putStrLn "about to hand over" 55 + let pkg' = pkg { library = sanity (library pkg) } 56 + sanity (Just lib) = Just $ lib { libBuildInfo = sanity' $ libBuildInfo lib } 57 + @@ -105,8 +110,7 @@ 58 + littleEndian <- testEndianness 59 + let args = ("-DPACKAGE_VERSION=" ++ show' version) : 60 + [arg | (arg, True) <- -- include fst iff snd. 61 + - [-- We have MAPI iff building on/for Windows. 62 + - ("-DHAVE_MAPI", buildOS == Windows), 63 + + [ 64 + ("-DLITTLEENDIAN", littleEndian), 65 + ("-DBIGENDIAN", not littleEndian)]] 66 + bi = emptyBuildInfo { cppOptions = args, ccOptions = args } 67 + @@ -133,20 +137,26 @@ 68 + -- man page 69 + -- --------------------------------------------------------------------- 70 + 71 + +hasDarcsExe :: LocalBuildInfo -> Bool 72 + +hasDarcsExe = isJust . M.lookup darcsExe . componentNameMap where 73 + + darcsExe = CExeName (mkUnqualComponentName "darcs") 74 + + 75 + buildManpage :: LocalBuildInfo -> IO () 76 + -buildManpage lbi = do 77 + - let darcs = buildDir lbi </> "darcs/darcs" 78 + - manpage = buildDir lbi </> "darcs/darcs.1" 79 + - manpageHandle <- openFile manpage WriteMode 80 + - void $ runProcess darcs ["help","manpage"] 81 + - Nothing Nothing Nothing (Just manpageHandle) Nothing 82 + +buildManpage lbi = 83 + + when (hasDarcsExe lbi) $ do 84 + + let darcs = buildDir lbi </> "darcs/darcs" 85 + + manpage = buildDir lbi </> "darcs/darcs.1" 86 + + manpageHandle <- openFile manpage WriteMode 87 + + void $ runProcess darcs ["help","manpage"] 88 + + Nothing Nothing Nothing (Just manpageHandle) Nothing 89 + 90 + -installManpage :: PackageDescription -> LocalBuildInfo 91 + - -> Verbosity -> CopyDest -> IO () 92 + +installManpage :: PackageDescription -> LocalBuildInfo -> Verbosity -> CopyDest -> IO () 93 + installManpage pkg lbi verbosity copy = 94 + - copyFiles verbosity 95 + - (mandir (absoluteInstallDirs pkg lbi copy) </> "man1") 96 + - [(buildDir lbi </> "darcs", "darcs.1")] 97 + + when (hasDarcsExe lbi) $ 98 + + copyFiles 99 + + verbosity 100 + + (mandir (absoluteInstallDirs pkg lbi copy) </> "man1") 101 + + [(buildDir lbi </> "darcs", "darcs.1")] 102 + 103 + -- --------------------------------------------------------------------- 104 + -- version module 105 + @@ -187,12 +197,13 @@ 106 + generateVersionModule :: Verbosity -> LocalBuildInfo 107 + -> String -> String -> IO () 108 + generateVersionModule verbosity lbi version state = do 109 + - let dir = autogenModulesDir lbi 110 + + let dir = autogenPackageModulesDir lbi 111 + createDirectoryIfMissingVerbose verbosity True dir 112 + ctx <- context verbosity 113 + hash <- weakhash verbosity 114 + - rewriteFile (dir </> "Version.hs") $ unlines 115 + + rewriteFileEx silent (dir </> "Version.hs") $ unlines 116 + ["module Version where" 117 + + ,"import Darcs.Prelude" 118 + ,"version, weakhash, context :: String" 119 + ,"version = \"" ++ version ++ " (" ++ state ++ ")\"" 120 + ,"weakhash = " ++ case hash of
+1 -1
pkgs/top-level/all-packages.nix
··· 18947 18947 18948 18948 dablin = callPackage ../applications/radio/dablin { }; 18949 18949 18950 - darcs = haskell.lib.overrideCabal (haskell.lib.justStaticExecutables haskell.packages.ghc865.darcs) (drv: { 18950 + darcs = haskell.lib.overrideCabal (haskell.lib.justStaticExecutables haskellPackages.darcs) (drv: { 18951 18951 configureFlags = (stdenv.lib.remove "-flibrary" drv.configureFlags or []) ++ ["-f-library"]; 18952 18952 }); 18953 18953