summaryrefslogtreecommitdiff
path: root/p/haskell-hoogle
diff options
context:
space:
mode:
authorRaúl Benencia <rul@kalgan.cc>2013-10-06 19:25:53 +0400
committer=?UTF-8?q?Ra=C3=BAl=20Benencia?= <rul@kalgan.cc>2013-10-06 19:25:53 +0400
commit81b33512332e8de135d9080896953bf40a1eaf8c (patch)
tree99ef6796b1c29f6327cca4c8315ee0b281d3cea9 /p/haskell-hoogle
parent39a985757c88473526b2f9dd7ed74c95e1d2d028 (diff)
downloadDHG_packages-81b33512332e8de135d9080896953bf40a1eaf8c.tar.gz
haskell-hoogle: New upstream version 4.2.23
It was needed to adapt the patch add-local-loction-database.patch in order for it to work with this new version. The patch fix-extract-tarball.patch was addded to fix a bug when trying to extract a couple of missing tarballs.
Diffstat (limited to 'p/haskell-hoogle')
-rw-r--r--p/haskell-hoogle/debian/changelog9
-rw-r--r--p/haskell-hoogle/debian/control5
-rw-r--r--p/haskell-hoogle/debian/patches/add-local-loction-database.patch80
-rw-r--r--p/haskell-hoogle/debian/patches/fix-extract-tarball.patch19
-rw-r--r--p/haskell-hoogle/debian/patches/series1
5 files changed, 63 insertions, 51 deletions
diff --git a/p/haskell-hoogle/debian/changelog b/p/haskell-hoogle/debian/changelog
index ba524189f..49daebd27 100644
--- a/p/haskell-hoogle/debian/changelog
+++ b/p/haskell-hoogle/debian/changelog
@@ -1,7 +1,14 @@
-haskell-hoogle (4.2.16-4) UNRELEASED; urgency=low
+haskell-hoogle (4.2.23-1) UNRELEASED; urgency=low
+ [ Joachim Breitner ]
* Adjust watch file to new hackage layout
+ [ Raúl Benencia ]
+ * New upstream release
+ * Remove obsolete DM-Upload-Allowed control field
+ * Add fix-extract-tarball.patch
+ * Depend on haskell-src-exts 1.14
+
-- Joachim Breitner <nomeata@debian.org> Sat, 05 Oct 2013 18:20:36 +0200
haskell-hoogle (4.2.16-3) unstable; urgency=low
diff --git a/p/haskell-hoogle/debian/control b/p/haskell-hoogle/debian/control
index 038da4a43..15fc20dce 100644
--- a/p/haskell-hoogle/debian/control
+++ b/p/haskell-hoogle/debian/control
@@ -17,8 +17,8 @@ Build-Depends: debhelper (>= 9)
, libghc-cmdargs-prof
, libghc-conduit-dev (>= 0.2)
, libghc-conduit-prof
- , libghc-src-exts-dev (>= 1.12)
- , libghc-src-exts-dev (<< 1.14)
+ , libghc-src-exts-dev (>= 1.14)
+ , libghc-src-exts-dev (<< 1.15)
, libghc-src-exts-prof
, libghc-http-types-dev (>= 0.7)
, libghc-http-types-prof
@@ -58,7 +58,6 @@ Standards-Version: 3.9.4
Homepage: http://www.haskell.org/hoogle/
Vcs-Darcs: http://darcs.debian.org/pkg-haskell/haskell-hoogle
Vcs-Browser: http://darcs.debian.org/cgi-bin/darcsweb.cgi?r=pkg-haskell/haskell-hoogle
-DM-Upload-Allowed: yes
Package: libghc-hoogle-dev
Architecture: any
diff --git a/p/haskell-hoogle/debian/patches/add-local-loction-database.patch b/p/haskell-hoogle/debian/patches/add-local-loction-database.patch
index 7732b66f7..259539cb3 100644
--- a/p/haskell-hoogle/debian/patches/add-local-loction-database.patch
+++ b/p/haskell-hoogle/debian/patches/add-local-loction-database.patch
@@ -1,64 +1,50 @@
-Forwarded: http://code.google.com/p/ndmitchell/issues/detail?id=590
+--- a/src/Recipe/Haddock.hs
++++ b/src/Recipe/Haddock.hs
+@@ -1,7 +1,7 @@
+ {-# LANGUAGE PatternGuards #-}
-Index: haskell-hoogle-4.2.15/src/CmdLine/Type.hs
-===================================================================
---- haskell-hoogle-4.2.15.orig/src/CmdLine/Type.hs 2013-01-29 11:35:35.000000000 +0100
-+++ haskell-hoogle-4.2.15/src/CmdLine/Type.hs 2013-02-17 17:26:49.000000000 +0100
-@@ -34,7 +34,7 @@
+ module Recipe.Haddock(
+- haddockToHTML, haddockHacks
++ haddockToHTML, haddockHacks, haddockPackageUrl
+ ) where
+
+ import General.Base
+--- a/src/CmdLine/Type.hs
++++ b/src/CmdLine/Type.hs
+@@ -35,7 +35,7 @@
| Data {redownload :: Bool, local :: [String], datadir :: FilePath, threads :: Int, actions :: [String]}
| Server {port :: Int, local_ :: Bool, databases :: [FilePath], resources :: FilePath, dynamic :: Bool, template :: [FilePath]}
| Combine {srcfiles :: [FilePath], outfile :: String}
-- | Convert {srcfile :: String, outfile :: String}
-+ | Convert {srcfile :: String, outfile :: String, addlocation :: Bool}
+- | Convert {srcfile :: String, outfile :: String, doc :: Maybe String, merge :: [String], haddock :: Bool}
++ | Convert {srcfile :: String, outfile :: String, doc :: Maybe String, merge :: [String], haddock :: Bool, addlocation :: Bool}
| Log {logfiles :: [FilePath]}
| Test {testFiles :: [String], example :: Bool}
| Dump {database :: String, section :: [String]}
-@@ -92,6 +92,7 @@
- convert = Convert
- {srcfile = def &= argPos 0 &= typ "INPUT"
- ,outfile = def &= argPos 1 &= typ "DATABASE" &= opt ""
+@@ -97,6 +97,7 @@
+ ,doc = def &= typDir &= help "Path to the root of local or Hackage documentation for the package (implies --haddock)"
+ ,merge = def &= typ "DATABASE" &= help "Merge other databases"
+ ,haddock = def &= help "Apply haddock-specific hacks"
+ ,addlocation = def &= help "Add location infomation to database"
} &= help "Convert an input file to a database"
data_ = Data
-Index: haskell-hoogle-4.2.15/src/Console/All.hs
-===================================================================
---- haskell-hoogle-4.2.15.orig/src/Console/All.hs 2013-01-29 11:35:35.000000000 +0100
-+++ haskell-hoogle-4.2.15/src/Console/All.hs 2013-02-17 17:33:42.662665170 +0100
-@@ -3,6 +3,7 @@
-
- import CmdLine.All
- import Recipe.All
-+import Recipe.Hackage
- import Console.Log
- import Console.Search
- import Console.Test
-@@ -36,12 +37,15 @@
+--- a/src/Console/All.hs
++++ b/src/Console/All.hs
+@@ -40,12 +40,15 @@
action (Log files) = logFiles files
--action (Convert from to) = do
-+action (Convert from to addloc) = do
- to <- return $ if null to then replaceExtension from "hoo" else to
+-action (Convert from to doc merge haddock) = do
++action (Convert from to doc merge haddock addloc) = do
when (any isUpper $ takeBaseName to) $ putStrLn $ "Warning: Hoogle databases should be all lower case, " ++ takeBaseName to
putStrLn $ "Converting " ++ from
src <- readFileUtf8 from
-- let (err,db) = createDatabase Haskell [] src
-+ let from' = "file://" ++ from
-+ src' = if addloc then unlines . haddockPackageUrl from' . lines $ src
-+ else src
-+ (err,db) = createDatabase Haskell [] src'
- unless (null err) $ putStr $ unlines $ "Warning: parse errors" : map show err
- saveDatabase to db
- putStrLn $ "Written " ++ to
-Index: haskell-hoogle-4.2.15/src/Recipe/Hackage.hs
-===================================================================
---- haskell-hoogle-4.2.15.orig/src/Recipe/Hackage.hs 2013-01-29 11:35:35.000000000 +0100
-+++ haskell-hoogle-4.2.15/src/Recipe/Hackage.hs 2013-02-17 17:26:49.000000000 +0100
-@@ -1,5 +1,5 @@
-
--module Recipe.Hackage(makePlatform, makeDefault, makePackage, makeAll) where
-+module Recipe.Hackage(makePlatform, makeDefault, makePackage, makeAll, haddockPackageUrl) where
-
- import Recipe.Type
- import Recipe.Cabal
+- convert merge (takeBaseName from) to $ unlines $ addLocalDoc doc (lines src)
++ convert merge (takeBaseName from) to $ unlines . fixURLs $ addLocalDoc doc (lines src)
+ where
++ fixURLs :: [String] -> [String]
++ fixURLs lns = if not addloc then lns else haddockPackageUrl ("file://" ++ from) lns
++
+ addLocalDoc :: Maybe FilePath -> [String] -> [String]
+ addLocalDoc doc = if haddock
+ then haddockHacks $ addDoc doc
diff --git a/p/haskell-hoogle/debian/patches/fix-extract-tarball.patch b/p/haskell-hoogle/debian/patches/fix-extract-tarball.patch
new file mode 100644
index 000000000..a2fc0e595
--- /dev/null
+++ b/p/haskell-hoogle/debian/patches/fix-extract-tarball.patch
@@ -0,0 +1,19 @@
+Description: Ask if a tarball exists before trying to extract its contents
+ When a contents of the tarball are already present in the filesystem,
+ hoogle will not download it again. In this case, the tarball must not be
+ extracted because it does not exists.
+Bug: https://github.com/ndmitchell/hoogle/pull/35
+Author: Raúl Benencia <rul@kalgan.cc>
+--- a/src/Recipe/Download.hs
++++ b/src/Recipe/Download.hs
+@@ -47,8 +47,8 @@
+ , (inputs <.> "txt", inputs <.> "tar.gz", "http://old.hackage.haskell.org/packages/archive/00-hoogle.tar.gz")
+ ]
+ withDownloader opt downloader items
+- extractTarball cabals
+- extractTarball inputs
++ doesFileExist (cabals <.> "tar.gz") >>= \b -> when b $ extractTarball cabals
++ doesFileExist (inputs <.> "tar.gz") >>= \b -> when b $ extractTarball inputs
+
+
+ check :: String -> IO (Maybe FilePath)
diff --git a/p/haskell-hoogle/debian/patches/series b/p/haskell-hoogle/debian/patches/series
index e0e0a8247..ef65a65c0 100644
--- a/p/haskell-hoogle/debian/patches/series
+++ b/p/haskell-hoogle/debian/patches/series
@@ -1 +1,2 @@
add-local-loction-database.patch
+fix-extract-tarball.patch