haddock-hardcode-ghc-paths
authorDebian Haskell Group <pkg-haskell-maintainers@lists.alioth.debian.org>
Wed, 1 Apr 2015 11:35:10 +0000 (11:35 +0000)
committerJoachim Breitner <nomeata@debian.org>
Wed, 1 Apr 2015 11:35:10 +0000 (11:35 +0000)
===================================================================

Gbp-Pq: Name haddock-hardcode-ghc-paths

utils/haddock/haddock.cabal
utils/haddock/src/Haddock.hs

index 2c102bc0db6e6fb1429f00135f8bd90020816bb2..c9cc1662a75a326a1d78af23194fd524a5aef7ae 100644 (file)
@@ -118,10 +118,6 @@ executable haddock
 
 library
   default-language:     Haskell2010
-  -- In a GHC tree - in particular, in a source tarball - we don't
-  -- require alex or happy
-  if !flag(in-ghc-tree)
-    build-tools: alex >= 2.3, happy >= 1.18
   build-depends:
     base >= 4.3 && < 4.7,
     filepath,
@@ -135,8 +131,6 @@ library
 
   if flag(in-ghc-tree)
     cpp-options: -DIN_GHC_TREE
-  else
-    build-depends: ghc-paths
 
   hs-source-dirs:       src
   if flag(dev)
index f79f34709da6d52998d209e302024b2947832f84..8752d228028c6fcd0c947a6af40c45f32ba4b07b 100644 (file)
@@ -50,7 +50,6 @@ import Data.Int
 #ifdef IN_GHC_TREE
 import System.FilePath
 #else
-import qualified GHC.Paths as GhcPaths
 import Paths_haddock
 #endif
 
@@ -349,14 +348,14 @@ getGhcDirs flags = do
       libDir <- getInTreeDir
       return (ghcPath, libDir)
 #else
-      return (ghcPath, GhcPaths.libdir)
+      return (ghcPath, "/usr/lib/ghc")
 #endif
     xs -> return (ghcPath, last xs)
   where
 #ifdef IN_GHC_TREE
     ghcPath = "not available"
 #else
-    ghcPath = GhcPaths.ghc
+    ghcPath = "/usr/bin/ghc"
 #endif