Package: haddock
Severity: normal
Tags: patch

When building 'haddock' on amd64 with gcc-4.0,
I get the following error:

/usr/bin/make INSTALLING=0 BIN_DIST=0 - --no-print-directory -r all
/usr/bin/ghc -H16m -O -package network -fglasgow-exts -cpp    -c FastMutInt.hs 
-o FastMutInt.o  -ohi FastMutInt.hi
/usr/bin/ghc -H16m -O -package network -fglasgow-exts -cpp    -c Binary.hs -o 
Binary.o  -ohi Binary.hi
/usr/bin/ghc -H16m -O -package network -fglasgow-exts -cpp    -c BlockTable.hs 
-o BlockTable.o  -ohi BlockTable.hi
/usr/bin/ghc -H16m -O -package network -fglasgow-exts -cpp    -c Digraph.lhs -o 
Digraph.o  -ohi Digraph.hi
/usr/bin/ghc -H16m -O -package network -fglasgow-exts -cpp    -c HsSyn.lhs -o 
HsSyn.o  -ohi HsSyn.hi
/usr/bin/ghc -H16m -O -package network -fglasgow-exts -cpp    -c HaddockUtil.hs 
-o HaddockUtil.o  -ohi HaddockUtil.hi
HaddockUtil.hs:191: warning: backslash and newline separated by space
HaddockUtil.hs:192: warning: backslash and newline separated by space
HaddockUtil.hs:193: warning: backslash and newline separated by space
HaddockUtil.hs:194: warning: backslash and newline separated by space
HaddockUtil.hs:195: warning: backslash and newline separated by space
HaddockUtil.hs:191: lexical error in string/character literal

With the attached patch 'haddock' can be compiled
on amd64 using gcc-4.0.

The patch was taken from gentoo.

Regards
Andreas Jochens

diff -urN ../tmp-orig/haddock-0.6/haddock/src/HaddockUtil.hs 
./haddock/src/HaddockUtil.hs
--- ../tmp-orig/haddock-0.6/haddock/src/HaddockUtil.hs  2003-11-10 
17:14:42.000000000 +0100
+++ ./haddock/src/HaddockUtil.hs        2005-03-19 12:37:41.422854453 +0100
@@ -188,12 +188,12 @@
 
 moduleHeaderRE :: Regex
 moduleHeaderRE = mkRegexWithOpts
-                        "^([ \t\n]*Module[ \t]*:.*\n)?\ 
-                         \([ \t\n]*Copyright[ \t]*:.*\n)?\ 
-                         \([ \t\n]*License[ \t]*:.*\n)?\ 
-                         \[ \t\n]*Maintainer[ \t]*:(.*)\n\ 
-                         \[ \t\n]*Stability[ \t]*:(.*)\n\ 
-                         \[ \t\n]*Portability[ \t]*:([^\n]*)\n"
+                       ( "^([ \t\n]*Module[ \t]*:.*\n)?" ++
+                         "([ \t\n]*Copyright[ \t]*:.*\n)?" ++
+                         "([ \t\n]*License[ \t]*:.*\n)?" ++
+                         "[ \t\n]*Maintainer[ \t]*:(.*)\n" ++
+                         "[ \t\n]*Stability[ \t]*:(.*)\n" ++
+                         "[ \t\n]*Portability[ \t]*:([^\n]*)\n" )
                True -- match "\n" with "."
                False -- not case sensitive
        -- All fields except the last (Portability) may be multi-line.
diff -urN ../tmp-orig/haddock-0.6/haddock/src/HaddockVersion.hs 
./haddock/src/HaddockVersion.hs
--- ../tmp-orig/haddock-0.6/haddock/src/HaddockVersion.hs       2003-11-10 
17:14:42.000000000 +0100
+++ ./haddock/src/HaddockVersion.hs     2005-03-19 12:37:41.423854252 +0100
@@ -14,5 +14,4 @@
 
 -- The version comes in via CPP from mk/version.mk
 projectVersion :: String
-projectVersion = tail "\ 
-  \ HADDOCK_VERSION"
+projectVersion = "0.6"
diff -urN ../tmp-orig/haddock-0.6/haddock/src/Main.hs ./haddock/src/Main.hs
--- ../tmp-orig/haddock-0.6/haddock/src/Main.hs 2003-11-10 17:13:39.000000000 
+0100
+++ ./haddock/src/Main.hs       2005-03-19 12:37:41.423854252 +0100
@@ -460,8 +460,8 @@
 
   when (not (null name_strings)) $
          tell ["Warning: " ++ show mdl ++ 
-               ": the following names could not be resolved:\n\ 
-               \   " ++ concat (map (' ':) name_strings)
+               ": the following names could not be resolved:\n" ++
+               "   " ++ concat (map (' ':) name_strings)
                ]
 
   return (mdl, Interface { 


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to