Skip to content

Commit

Permalink
fix for build with GHC 9.8
Browse files Browse the repository at this point in the history
  • Loading branch information
clinty committed Feb 5, 2024
1 parent f7d457b commit 67603c6
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cabal-debian.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ Library
lens,
mtl,
network-uri,
newtype-generics >= 0.4,
newtype-generics >= 0.5.3,
parsec >= 3,
pretty >= 1.1.2,
process,
Expand Down
4 changes: 2 additions & 2 deletions debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ Build-Depends: debhelper (>= 9),
libghc-memoize-prof (>= 0.7),
libghc-network-uri-dev,
libghc-network-uri-prof,
libghc-newtype-generics-dev (>= 0.4),
libghc-newtype-generics-prof (>= 0.4),
libghc-newtype-generics-dev (>= 0.5.3),
libghc-newtype-generics-prof (>= 0.5.3),
libghc-optparse-applicative-dev (>= 0.11),
libghc-optparse-applicative-prof (>= 0.11),
libghc-puremd5-dev,
Expand Down
4 changes: 3 additions & 1 deletion src/Debian/Debianize/Finalize.hs
Original file line number Diff line number Diff line change
Expand Up @@ -405,13 +405,15 @@ finalizeChangelog date currentUser =
where
fixLog :: Maybe SrcPkgName -> V.DebianVersion -> Maybe [[Text]] -> Either String NameAddr -> Text -> Maybe ChangeLog -> Maybe ChangeLog
-- Ensure that the package name is correct in the first log entry.
fixLog src ver cmts _maint _ (Just (ChangeLog (entry : older)))
fixLog src ver cmts _maint _ (Just (ChangeLog (entry@Entry{} : older)))
| logVersion entry == ver =
let entry' = entry { logPackage = show (pretty (PP src))
, logComments = logComments entry ++ "\n" ++
(List.unlines $ List.map ((" * " <>) . List.intercalate "\n " . List.map unpack) (fromMaybe [] cmts))
} in
Just (ChangeLog (entry' : older))
fixLog _src _ver _cmts _maint _ (Just (ChangeLog (entry@WhiteSpace{} : older))) =
Just (ChangeLog (entry : older))
-- The newest log entry isn't exactly ver, build a new entry.
fixLog src ver cmts maint msg log =
let entry = Entry { logPackage = show (pretty (PP src))
Expand Down

0 comments on commit 67603c6

Please sign in to comment.