cannot build greencard

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

cannot build greencard

mf-hcafe-15c311f0c


hi,

i am stuck with a linker error in greencard, and haven't found
anything online, so i am addressing you for fresh ideas.  as soon as i
get this sorted out, i will try to turn the answer into a patch that
you can consider for the next release.

SYMPTOMS: greencard 3.0.3 and 3.01 do not compile with ghc-6.8 (debian
lenny package) and 6.10 (darcs copy, checked out yesterday).  here is
what happens:


4 (0) 19:27:19 mf@yoyo:/tmp2 $ tar xvpzf greencard-3.0.3.tar.gz
greencard-3.0.3/
greencard-3.0.3/ANNOUNCE
greencard-3.0.3/dist/
greencard-3.0.3/dist/build/
greencard-3.0.3/dist/build/greencard/
greencard-3.0.3/dist/build/greencard/greencard-tmp/
greencard-3.0.3/dist/build/greencard/greencard-tmp/Parse.hs
greencard-3.0.3/examples/
greencard-3.0.3/examples/Gdbm/
greencard-3.0.3/examples/Gdbm/diffs
greencard-3.0.3/examples/Gdbm/Gdbm.gc
greencard-3.0.3/examples/Gdbm/gdbmplus.h
greencard-3.0.3/examples/Gdbm/Main.hs
greencard-3.0.3/examples/Gdbm/Makefile
greencard-3.0.3/examples/Gdbm/README
greencard-3.0.3/examples/Makefile
greencard-3.0.3/examples/world/
greencard-3.0.3/examples/world/Main.hs
greencard-3.0.3/examples/world/Makedefs.ghc
greencard-3.0.3/examples/world/Makedeps
greencard-3.0.3/examples/world/Makefile.ghc-linux
greencard-3.0.3/examples/world/Makefile.ghc-win32
greencard-3.0.3/examples/world/Makefile.hugs-linux
greencard-3.0.3/examples/world/Makefile.hugs-win32
greencard-3.0.3/examples/world/README.txt
greencard-3.0.3/examples/world/World.gc
greencard-3.0.3/greencard.cabal
greencard-3.0.3/INSTALL
greencard-3.0.3/lib/
greencard-3.0.3/lib/Foreign/
greencard-3.0.3/lib/Foreign/GreenCard.hs
greencard-3.0.3/lib/GreenCard.gc
greencard-3.0.3/lib/Makefile
greencard-3.0.3/lib/package.conf.in
greencard-3.0.3/LICENSE
greencard-3.0.3/Makefile
greencard-3.0.3/README
greencard-3.0.3/Setup.hs
greencard-3.0.3/src/
greencard-3.0.3/src/Casm.lhs
greencard-3.0.3/src/Decl.lhs
greencard-3.0.3/src/DIS.lhs
greencard-3.0.3/src/ErrMonad.lhs
greencard-3.0.3/src/ErrorHook.c
greencard-3.0.3/src/FillIn.lhs
greencard-3.0.3/src/FillInMonad.lhs
greencard-3.0.3/src/GCToken.lhs
greencard-3.0.3/src/greencard.ghc.in
greencard-3.0.3/src/greencard.hugs.in
greencard-3.0.3/src/GreenCard.lhs
greencard-3.0.3/src/Lex.lhs
greencard-3.0.3/src/LexM.lhs
greencard-3.0.3/src/ListUtils.lhs
greencard-3.0.3/src/Makefile
greencard-3.0.3/src/MarshallMonad.lhs
greencard-3.0.3/src/Name.lhs
greencard-3.0.3/src/NameSupply.lhs
greencard-3.0.3/src/Package.lhs
greencard-3.0.3/src/Package.lhs.in
greencard-3.0.3/src/Parse.ly
greencard-3.0.3/src/PrettyUtils.lhs
greencard-3.0.3/src/Proc.lhs
greencard-3.0.3/src/Process.lhs
greencard-3.0.3/src/Target.lhs
greencard-3.0.3/src/Type.lhs
5 (0) 19:27:22 mf@yoyo:/tmp2 $ cd greencard-3.0.3
6 (0) 19:27:24 mf@yoyo:/tmp2/greencard-3.0.3 $ make prefix=/tmp2/
make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
happy  Parse.ly
unused terminals: 1
rm -f .depend
touch .depend
ghc -M -optdep-f -optdep.depend -optdep-xFiniteMap -optdep-xPretty -recomp -O -fglasgow-exts     Casm.lhs DIS.lhs Decl.lhs ErrMonad.lhs FillIn.lhs FillInMonad.lhs GCToken.lhs GreenCard.lhs Lex.lhs LexM.lhs ListUtils.lhs MarshallMonad.lhs Name.lhs NameSupply.lhs Package.lhs PrettyUtils.lhs Proc.lhs Process.lhs Target.lhs Type.lhs Parse.hs
make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
ghc -recomp -O -fglasgow-exts     -c Target.lhs -o Target.o
ghc -recomp -O -fglasgow-exts     -c PrettyUtils.lhs -o PrettyUtils.o
ghc -recomp -O -fglasgow-exts     -c Casm.lhs -o Casm.o

Casm.lhs:544:1:
    Warning: Pattern match(es) are overlapped
             In a case alternative: _ -> ...

Casm.lhs:577:1:
    Warning: Pattern match(es) are overlapped
             In a case alternative: _ -> ...

Casm.lhs:616:4:
    Warning: Pattern match(es) are overlapped
             In a case alternative: _ -> ...

Casm.lhs:631:5:
    Warning: Pattern match(es) are overlapped
             In a case alternative: _ -> ...
ghc -recomp -O -fglasgow-exts     -c ListUtils.lhs -o ListUtils.o
ghc -recomp -O -fglasgow-exts     -c ErrMonad.lhs -o ErrMonad.o
ghc -recomp -O -fglasgow-exts     -c Name.lhs -o Name.o
ghc -recomp -O -fglasgow-exts     -c DIS.lhs -o DIS.o
ghc -recomp -O -fglasgow-exts     -c Type.lhs -o Type.o
ghc -recomp -O -fglasgow-exts     -c Decl.lhs -o Decl.o
ghc -recomp -O -fglasgow-exts     -c FillInMonad.lhs -o FillInMonad.o
ghc -recomp -O -fglasgow-exts     -c NameSupply.lhs -o NameSupply.o
ghc -recomp -O -fglasgow-exts     -c FillIn.lhs -o FillIn.o
ghc -recomp -O -fglasgow-exts     -c GCToken.lhs -o GCToken.o
ghc -recomp -O -fglasgow-exts     -c MarshallMonad.lhs -o MarshallMonad.o
ghc -recomp -O -fglasgow-exts     -c Proc.lhs -o Proc.o
ghc -recomp -O -fglasgow-exts     -c LexM.lhs -o LexM.o
ghc -recomp -O -fglasgow-exts     -c Lex.lhs -o Lex.o
ghc -recomp -O -fglasgow-exts   -Onot  -c Parse.hs -o Parse.o

Parse.hs:1733:1:
    Warning: Pattern match(es) are overlapped
             In a case alternative: _ -> ...
ghc -recomp -O -fglasgow-exts     -c Process.lhs -o Process.o
ghc -recomp -O -fglasgow-exts     -c Package.lhs -o Package.o
ghc -recomp -O -fglasgow-exts   -cpp -DBEGIN_GHC_ONLY='-}' -DEND_GHC_ONLY='{-' -DBEGIN_NOT_FOR_GHC='{-' -DEND_NOT_FOR_GHC='-}' -DPURE_WIN32=0  -c GreenCard.lhs -o GreenCard.o
ghc     -c ErrorHook.c -o ErrorHook.o
ghc -recomp -O -fglasgow-exts     -o greencard-bin Casm.o DIS.o Decl.o ErrMonad.o FillIn.o FillInMonad.o GCToken.o GreenCard.o Lex.o LexM.o ListUtils.o MarshallMonad.o Name.o NameSupply.o Package.o PrettyUtils.o Proc.o Process.o Target.o Type.o Parse.o ErrorHook.o
Casm.o: In function `s201_info':
(.text+0x168): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_con_info'
Casm.o: In function `s201_info':
(.text+0x17b): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_con_info'
Casm.o: In function `s201_info':
(.text+0x19d): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
Casm.o: In function `s201_info':
(.text+0x1b7): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_con_info'
Casm.o: In function `s201_info':
(.text+0x1ca): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_con_info'
Casm.o: In function `s201_info':
(.text+0x1e9): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
Casm.o: In function `s201_info':
(.text+0x1f0): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Beside_con_info'

[...  these continue for every object file on the command line; a bit
over 2000 message of the same type in total...]

Type.o: In function `sBv_info':
(.text+0x1b2b): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Beside_con_info'
Type.o: In function `sZT_info':
(.text+0x1ed3): undefined reference to `__stginit_prettyzm1zi0zi0zi0_TextziPrettyPrint_'
Type.o: In function `sBb_info':
(.text+0x1988): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_go6_info'
Type.o: In function `sBf_info':
(.text+0x1a12): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_go6_info'
Type.o: In function `sZU_info':
(.text+0x1b96): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_text_info'
Type.o: In function `rvv_closure':
(.data+0x8): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Chr_static_info'
Type.o: In function `rvH_closure':
(.data+0x64): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_static_info'
Type.o: In function `rvH_closure':
(.data+0x6c): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_lvl3_closure'
Type.o: In function `rvH_closure':
(.data+0x70): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
Type.o: In function `rvN_closure':
(.data+0xb0): undefined reference to `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_static_info'
collect2: ld returned 1 exit status
make[1]: *** [greencard-bin] Error 1
make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/lib'
ghc -package-name greencard -cpp -fglasgow-exts -fno-prune-tydecls   -c Foreign/GreenCard.hs -o Foreign/GreenCard.o -hisuf hi
ghc-6.8.2: unrecognised flags: -fno-prune-tydecls
Usage: For basic information, try the `--help' option.
make[1]: *** [Foreign/GreenCard.o] Error 1
make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/lib'
make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/lib'
ghc -package-name greencard -cpp -fglasgow-exts -fno-prune-tydecls  -prof -c Foreign/GreenCard.hs -o Foreign/GreenCard.p_o -hisuf p_hi
ghc-6.8.2: unrecognised flags: -fno-prune-tydecls
Usage: For basic information, try the `--help' option.
make[1]: *** [Foreign/GreenCard.p_o] Error 1
make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/lib'
make: *** [all] Error 2

the errors about no-prune-tydecls are easy enough to fix:

$ diff -r greencard-3.0.3{,-patched}
diff -r greencard-3.0.3/examples/Gdbm/Makefile greencard-3.0.3-patched/examples/Gdbm/Makefile
28d27
< HC_OPTS += -fno-prune-tydecls
diff -r greencard-3.0.3/lib/Makefile greencard-3.0.3-patched/lib/Makefile
6c6
< GHC_OPTS = -cpp -fglasgow-exts -fno-prune-tydecls
---
> GHC_OPTS = -cpp -fglasgow-exts
$  


this helps, but the linker errors are unrealted, and i don't know what
to make of them.  (I guess I should study how ghc generates C code at
this point?  it does feel like something obvious...)


thanks,
cheers,
matthias
_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe
Reply | Threaded
Open this post in threaded view
|

Re: cannot build greencard

Bulat Ziganshin-2
Hello mf-hcafe-15c311f0c,

Thursday, September 3, 2009, 12:44:25 AM, you wrote:

to the best of my knowledge, GC was developed in the days of ghc 0.20
or so and last 10 years it's superceded by FFI addendum to Haskell'98
standard. there is also more high-level tools like hsc2hs and HSFFIG


> hi,

> i am stuck with a linker error in greencard, and haven't found
> anything online, so i am addressing you for fresh ideas.  as soon as i
> get this sorted out, i will try to turn the answer into a patch that
> you can consider for the next release.

> SYMPTOMS: greencard 3.0.3 and 3.01 do not compile with ghc-6.8 (debian
> lenny package) and 6.10 (darcs copy, checked out yesterday).  here is
> what happens:


> 4 (0) 19:27:19 mf@yoyo:/tmp2 $ tar xvpzf greencard-3.0.3.tar.gz
> greencard-3.0.3/
> greencard-3.0.3/ANNOUNCE
> greencard-3.0.3/dist/
> greencard-3.0.3/dist/build/
> greencard-3.0.3/dist/build/greencard/
> greencard-3.0.3/dist/build/greencard/greencard-tmp/
> greencard-3.0.3/dist/build/greencard/greencard-tmp/Parse.hs
> greencard-3.0.3/examples/
> greencard-3.0.3/examples/Gdbm/
> greencard-3.0.3/examples/Gdbm/diffs
> greencard-3.0.3/examples/Gdbm/Gdbm.gc
> greencard-3.0.3/examples/Gdbm/gdbmplus.h
> greencard-3.0.3/examples/Gdbm/Main.hs
> greencard-3.0.3/examples/Gdbm/Makefile
> greencard-3.0.3/examples/Gdbm/README
> greencard-3.0.3/examples/Makefile
> greencard-3.0.3/examples/world/
> greencard-3.0.3/examples/world/Main.hs
> greencard-3.0.3/examples/world/Makedefs.ghc
> greencard-3.0.3/examples/world/Makedeps
> greencard-3.0.3/examples/world/Makefile.ghc-linux
> greencard-3.0.3/examples/world/Makefile.ghc-win32
> greencard-3.0.3/examples/world/Makefile.hugs-linux
> greencard-3.0.3/examples/world/Makefile.hugs-win32
> greencard-3.0.3/examples/world/README.txt
> greencard-3.0.3/examples/world/World.gc
> greencard-3.0.3/greencard.cabal
> greencard-3.0.3/INSTALL
> greencard-3.0.3/lib/
> greencard-3.0.3/lib/Foreign/
> greencard-3.0.3/lib/Foreign/GreenCard.hs
> greencard-3.0.3/lib/GreenCard.gc
> greencard-3.0.3/lib/Makefile
> greencard-3.0.3/lib/package.conf.in
> greencard-3.0.3/LICENSE
> greencard-3.0.3/Makefile
> greencard-3.0.3/README
> greencard-3.0.3/Setup.hs
> greencard-3.0.3/src/
> greencard-3.0.3/src/Casm.lhs
> greencard-3.0.3/src/Decl.lhs
> greencard-3.0.3/src/DIS.lhs
> greencard-3.0.3/src/ErrMonad.lhs
> greencard-3.0.3/src/ErrorHook.c
> greencard-3.0.3/src/FillIn.lhs
> greencard-3.0.3/src/FillInMonad.lhs
> greencard-3.0.3/src/GCToken.lhs
> greencard-3.0.3/src/greencard.ghc.in
> greencard-3.0.3/src/greencard.hugs.in
> greencard-3.0.3/src/GreenCard.lhs
> greencard-3.0.3/src/Lex.lhs
> greencard-3.0.3/src/LexM.lhs
> greencard-3.0.3/src/ListUtils.lhs
> greencard-3.0.3/src/Makefile
> greencard-3.0.3/src/MarshallMonad.lhs
> greencard-3.0.3/src/Name.lhs
> greencard-3.0.3/src/NameSupply.lhs
> greencard-3.0.3/src/Package.lhs
> greencard-3.0.3/src/Package.lhs.in
> greencard-3.0.3/src/Parse.ly
> greencard-3.0.3/src/PrettyUtils.lhs
> greencard-3.0.3/src/Proc.lhs
> greencard-3.0.3/src/Process.lhs
> greencard-3.0.3/src/Target.lhs
> greencard-3.0.3/src/Type.lhs
> 5 (0) 19:27:22 mf@yoyo:/tmp2 $ cd greencard-3.0.3
> 6 (0) 19:27:24 mf@yoyo:/tmp2/greencard-3.0.3 $ make prefix=/tmp2/
> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
> happy  Parse.ly
> unused terminals: 1
> rm -f .depend
> touch .depend
> ghc -M -optdep-f -optdep.depend -optdep-xFiniteMap -optdep-xPretty
> -recomp -O -fglasgow-exts     Casm.lhs DIS.lhs Decl.lhs ErrMonad.lhs
> FillIn.lhs FillInMonad.lhs GCToken.lhs GreenCard.lhs Lex.lhs
> LexM.lhs ListUtils.lhs MarshallMonad.lhs Name.lhs NameSupply.lhs
> Package.lhs PrettyUtils.lhs Proc.lhs Process.lhs Target.lhs Type.lhs Parse.hs
> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
> ghc -recomp -O -fglasgow-exts     -c Target.lhs -o Target.o
> ghc -recomp -O -fglasgow-exts     -c PrettyUtils.lhs -o PrettyUtils.o
> ghc -recomp -O -fglasgow-exts     -c Casm.lhs -o Casm.o

> Casm.lhs:544:1:
>     Warning: Pattern match(es) are overlapped
>              In a case alternative: _ -> ...

> Casm.lhs:577:1:
>     Warning: Pattern match(es) are overlapped
>              In a case alternative: _ -> ...

> Casm.lhs:616:4:
>     Warning: Pattern match(es) are overlapped
>              In a case alternative: _ -> ...

> Casm.lhs:631:5:
>     Warning: Pattern match(es) are overlapped
>              In a case alternative: _ -> ...
> ghc -recomp -O -fglasgow-exts     -c ListUtils.lhs -o ListUtils.o
> ghc -recomp -O -fglasgow-exts     -c ErrMonad.lhs -o ErrMonad.o
> ghc -recomp -O -fglasgow-exts     -c Name.lhs -o Name.o
> ghc -recomp -O -fglasgow-exts     -c DIS.lhs -o DIS.o
> ghc -recomp -O -fglasgow-exts     -c Type.lhs -o Type.o
> ghc -recomp -O -fglasgow-exts     -c Decl.lhs -o Decl.o
> ghc -recomp -O -fglasgow-exts     -c FillInMonad.lhs -o FillInMonad.o
> ghc -recomp -O -fglasgow-exts     -c NameSupply.lhs -o NameSupply.o
> ghc -recomp -O -fglasgow-exts     -c FillIn.lhs -o FillIn.o
> ghc -recomp -O -fglasgow-exts     -c GCToken.lhs -o GCToken.o
> ghc -recomp -O -fglasgow-exts     -c MarshallMonad.lhs -o MarshallMonad.o
> ghc -recomp -O -fglasgow-exts     -c Proc.lhs -o Proc.o
> ghc -recomp -O -fglasgow-exts     -c LexM.lhs -o LexM.o
> ghc -recomp -O -fglasgow-exts     -c Lex.lhs -o Lex.o
> ghc -recomp -O -fglasgow-exts   -Onot  -c Parse.hs -o Parse.o

> Parse.hs:1733:1:
>     Warning: Pattern match(es) are overlapped
>              In a case alternative: _ -> ...
> ghc -recomp -O -fglasgow-exts     -c Process.lhs -o Process.o
> ghc -recomp -O -fglasgow-exts     -c Package.lhs -o Package.o
> ghc -recomp -O -fglasgow-exts   -cpp -DBEGIN_GHC_ONLY='-}'
> -DEND_GHC_ONLY='{-' -DBEGIN_NOT_FOR_GHC='{-' -DEND_NOT_FOR_GHC='-}'
> -DPURE_WIN32=0  -c GreenCard.lhs -o GreenCard.o
> ghc     -c ErrorHook.c -o ErrorHook.o
> ghc -recomp -O -fglasgow-exts     -o greencard-bin Casm.o DIS.o
> Decl.o ErrMonad.o FillIn.o FillInMonad.o GCToken.o GreenCard.o Lex.o
> LexM.o ListUtils.o MarshallMonad.o Name.o NameSupply.o Package.o
> PrettyUtils.o Proc.o Process.o Target.o Type.o Parse.o ErrorHook.o
> Casm.o: In function `s201_info':
> (.text+0x168): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_con_info'
> Casm.o: In function `s201_info':
> (.text+0x17b): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_con_info'
> Casm.o: In function `s201_info':
> (.text+0x19d): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
> Casm.o: In function `s201_info':
> (.text+0x1b7): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_con_info'
> Casm.o: In function `s201_info':
> (.text+0x1ca): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_con_info'
> Casm.o: In function `s201_info':
> (.text+0x1e9): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
> Casm.o: In function `s201_info':
> (.text+0x1f0): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Beside_con_info'

> [...  these continue for every object file on the command line; a bit
> over 2000 message of the same type in total...]

> Type.o: In function `sBv_info':
> (.text+0x1b2b): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Beside_con_info'
> Type.o: In function `sZT_info':
> (.text+0x1ed3): undefined reference to
> `__stginit_prettyzm1zi0zi0zi0_TextziPrettyPrint_'
> Type.o: In function `sBb_info':
> (.text+0x1988): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_go6_info'
> Type.o: In function `sBf_info':
> (.text+0x1a12): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_go6_info'
> Type.o: In function `sZU_info':
> (.text+0x1b96): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_text_info'
> Type.o: In function `rvv_closure':
> (.data+0x8): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Chr_static_info'
> Type.o: In function `rvH_closure':
> (.data+0x64): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_static_info'
> Type.o: In function `rvH_closure':
> (.data+0x6c): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_lvl3_closure'
> Type.o: In function `rvH_closure':
> (.data+0x70): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
> Type.o: In function `rvN_closure':
> (.data+0xb0): undefined reference to
> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_static_info'
> collect2: ld returned 1 exit status
> make[1]: *** [greencard-bin] Error 1
> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/lib'
> ghc -package-name greencard -cpp -fglasgow-exts -fno-prune-tydecls
> -c Foreign/GreenCard.hs -o Foreign/GreenCard.o -hisuf hi
> ghc-6.8.2: unrecognised flags: -fno-prune-tydecls
> Usage: For basic information, try the `--help' option.
> make[1]: *** [Foreign/GreenCard.o] Error 1
> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/lib'
> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
> make[1]: Nothing to be done for `all'.
> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/lib'
> ghc -package-name greencard -cpp -fglasgow-exts -fno-prune-tydecls
> -prof -c Foreign/GreenCard.hs -o Foreign/GreenCard.p_o -hisuf p_hi
> ghc-6.8.2: unrecognised flags: -fno-prune-tydecls
> Usage: For basic information, try the `--help' option.
> make[1]: *** [Foreign/GreenCard.p_o] Error 1
> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/lib'
> make: *** [all] Error 2

> the errors about no-prune-tydecls are easy enough to fix:

> $ diff -r greencard-3.0.3{,-patched}
> diff -r greencard-3.0.3/examples/Gdbm/Makefile
> greencard-3.0.3-patched/examples/Gdbm/Makefile
> 28d27
> < HC_OPTS += -fno-prune-tydecls
> diff -r greencard-3.0.3/lib/Makefile
> greencard-3.0.3-patched/lib/Makefile
> 6c6
> < GHC_OPTS = -cpp -fglasgow-exts -fno-prune-tydecls
> ---
>> GHC_OPTS = -cpp -fglasgow-exts
> $  


> this helps, but the linker errors are unrealted, and i don't know what
> to make of them.  (I guess I should study how ghc generates C code at
> this point?  it does feel like something obvious...)


> thanks,
> cheers,
> matthias
> _______________________________________________
> Haskell-Cafe mailing list
> [hidden email]
> http://www.haskell.org/mailman/listinfo/haskell-cafe


--
Best regards,
 Bulat                            mailto:[hidden email]

_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe
Reply | Threaded
Open this post in threaded view
|

Re: cannot build greencard

Dan Weston
Yet strangely, the last upload was Sun Apr 19 21:42:04 UTC 2009 and
hackage claims it builds without failure with ghc-6.10.

And in fact it builds just fine for me, so maybe it is worth finding out
why it doesn't build for you. Are you using ghc-6.10.4 and the latest
version of cabal? I get:

 > ghc --version
The Glorious Glasgow Haskell Compilation System, version 6.10.4

 > cabal --version
cabal-install version 0.6.2
using version 1.6.0.3 of the Cabal library

 > cabal install greencard

Resolving dependencies...
Downloading greencard-3.0.3...
Configuring greencard-3.0.3...
Preprocessing library greencard-3.0.3...
Preprocessing executables for greencard-3.0.3...
Building greencard-3.0.3...
[1 of 1] Compiling Foreign.GreenCard ( lib/Foreign/GreenCard.hs,
dist/build/Foreign/GreenCard.o )
/usr/bin/ar: creating dist/build/libHSgreencard-3.0.3.a
[ 1 of 21] Compiling Package          ( src/Package.lhs,
dist/build/greencard/greencard-tmp/Package.o )
[ 2 of 21] Compiling ErrMonad         ( src/ErrMonad.lhs,
dist/build/greencard/greencard-tmp/ErrMonad.o )
[ 3 of 21] Compiling PrettyUtils      ( src/PrettyUtils.lhs,
dist/build/greencard/greencard-tmp/PrettyUtils.o )
[ 4 of 21] Compiling Target           ( src/Target.lhs,
dist/build/greencard/greencard-tmp/Target.o )
[ 5 of 21] Compiling Casm             ( src/Casm.lhs,
dist/build/greencard/greencard-tmp/Casm.o )

src/Casm.lhs:544:1:
     Warning: Pattern match(es) are overlapped
              In a case alternative: _ -> ...

src/Casm.lhs:577:1:
     Warning: Pattern match(es) are overlapped
              In a case alternative: _ -> ...

src/Casm.lhs:616:4:
     Warning: Pattern match(es) are overlapped
              In a case alternative: _ -> ...

src/Casm.lhs:631:5:
     Warning: Pattern match(es) are overlapped
              In a case alternative: _ -> ...
[ 6 of 21] Compiling GCToken          ( src/GCToken.lhs,
dist/build/greencard/greencard-tmp/GCToken.o )
[ 7 of 21] Compiling ListUtils        ( src/ListUtils.lhs,
dist/build/greencard/greencard-tmp/ListUtils.o )
[ 8 of 21] Compiling Name             ( src/Name.lhs,
dist/build/greencard/greencard-tmp/Name.o )
[ 9 of 21] Compiling Type             ( src/Type.lhs,
dist/build/greencard/greencard-tmp/Type.o )
[10 of 21] Compiling DIS              ( src/DIS.lhs,
dist/build/greencard/greencard-tmp/DIS.o )
[11 of 21] Compiling FillInMonad      ( src/FillInMonad.lhs,
dist/build/greencard/greencard-tmp/FillInMonad.o )
[12 of 21] Compiling NameSupply       ( src/NameSupply.lhs,
dist/build/greencard/greencard-tmp/NameSupply.o )
[13 of 21] Compiling Decl             ( src/Decl.lhs,
dist/build/greencard/greencard-tmp/Decl.o )
[14 of 21] Compiling FillIn           ( src/FillIn.lhs,
dist/build/greencard/greencard-tmp/FillIn.o )
[15 of 21] Compiling LexM             ( src/LexM.lhs,
dist/build/greencard/greencard-tmp/LexM.o )
[16 of 21] Compiling Lex              ( src/Lex.lhs,
dist/build/greencard/greencard-tmp/Lex.o )
[17 of 21] Compiling MarshallMonad    ( src/MarshallMonad.lhs,
dist/build/greencard/greencard-tmp/MarshallMonad.o )
[18 of 21] Compiling Proc             ( src/Proc.lhs,
dist/build/greencard/greencard-tmp/Proc.o )
[19 of 21] Compiling Parse            (
dist/build/greencard/greencard-tmp/Parse.hs,
dist/build/greencard/greencard-tmp/Parse.o )

dist/build/greencard/greencard-tmp/Parse.hs:1122:1:
     Warning: Pattern match(es) are overlapped
              In a case alternative: _ -> ...
[20 of 21] Compiling Process          ( src/Process.lhs,
dist/build/greencard/greencard-tmp/Process.o )
[21 of 21] Compiling Main             ( src/GreenCard.lhs,
dist/build/greencard/greencard-tmp/Main.o )
Linking dist/build/greencard/greencard ...
Installing library in
/net/homedirs/westondan/.cabal/lib/greencard-3.0.3/ghc-6.10.4
Installing executable(s) in /net/homedirs/westondan/.cabal/bin
Registering greencard-3.0.3...
Reading package info from "dist/installed-pkg-config" ... done.
Writing new package config file... done.

Bulat Ziganshin wrote:

> Hello mf-hcafe-15c311f0c,
>
> Thursday, September 3, 2009, 12:44:25 AM, you wrote:
>
> to the best of my knowledge, GC was developed in the days of ghc 0.20
> or so and last 10 years it's superceded by FFI addendum to Haskell'98
> standard. there is also more high-level tools like hsc2hs and HSFFIG
>
>
>> hi,
>
>> i am stuck with a linker error in greencard, and haven't found
>> anything online, so i am addressing you for fresh ideas.  as soon as i
>> get this sorted out, i will try to turn the answer into a patch that
>> you can consider for the next release.
>
>> SYMPTOMS: greencard 3.0.3 and 3.01 do not compile with ghc-6.8 (debian
>> lenny package) and 6.10 (darcs copy, checked out yesterday).  here is
>> what happens:
>
>
>> 4 (0) 19:27:19 mf@yoyo:/tmp2 $ tar xvpzf greencard-3.0.3.tar.gz
>> greencard-3.0.3/
>> greencard-3.0.3/ANNOUNCE
>> greencard-3.0.3/dist/
>> greencard-3.0.3/dist/build/
>> greencard-3.0.3/dist/build/greencard/
>> greencard-3.0.3/dist/build/greencard/greencard-tmp/
>> greencard-3.0.3/dist/build/greencard/greencard-tmp/Parse.hs
>> greencard-3.0.3/examples/
>> greencard-3.0.3/examples/Gdbm/
>> greencard-3.0.3/examples/Gdbm/diffs
>> greencard-3.0.3/examples/Gdbm/Gdbm.gc
>> greencard-3.0.3/examples/Gdbm/gdbmplus.h
>> greencard-3.0.3/examples/Gdbm/Main.hs
>> greencard-3.0.3/examples/Gdbm/Makefile
>> greencard-3.0.3/examples/Gdbm/README
>> greencard-3.0.3/examples/Makefile
>> greencard-3.0.3/examples/world/
>> greencard-3.0.3/examples/world/Main.hs
>> greencard-3.0.3/examples/world/Makedefs.ghc
>> greencard-3.0.3/examples/world/Makedeps
>> greencard-3.0.3/examples/world/Makefile.ghc-linux
>> greencard-3.0.3/examples/world/Makefile.ghc-win32
>> greencard-3.0.3/examples/world/Makefile.hugs-linux
>> greencard-3.0.3/examples/world/Makefile.hugs-win32
>> greencard-3.0.3/examples/world/README.txt
>> greencard-3.0.3/examples/world/World.gc
>> greencard-3.0.3/greencard.cabal
>> greencard-3.0.3/INSTALL
>> greencard-3.0.3/lib/
>> greencard-3.0.3/lib/Foreign/
>> greencard-3.0.3/lib/Foreign/GreenCard.hs
>> greencard-3.0.3/lib/GreenCard.gc
>> greencard-3.0.3/lib/Makefile
>> greencard-3.0.3/lib/package.conf.in
>> greencard-3.0.3/LICENSE
>> greencard-3.0.3/Makefile
>> greencard-3.0.3/README
>> greencard-3.0.3/Setup.hs
>> greencard-3.0.3/src/
>> greencard-3.0.3/src/Casm.lhs
>> greencard-3.0.3/src/Decl.lhs
>> greencard-3.0.3/src/DIS.lhs
>> greencard-3.0.3/src/ErrMonad.lhs
>> greencard-3.0.3/src/ErrorHook.c
>> greencard-3.0.3/src/FillIn.lhs
>> greencard-3.0.3/src/FillInMonad.lhs
>> greencard-3.0.3/src/GCToken.lhs
>> greencard-3.0.3/src/greencard.ghc.in
>> greencard-3.0.3/src/greencard.hugs.in
>> greencard-3.0.3/src/GreenCard.lhs
>> greencard-3.0.3/src/Lex.lhs
>> greencard-3.0.3/src/LexM.lhs
>> greencard-3.0.3/src/ListUtils.lhs
>> greencard-3.0.3/src/Makefile
>> greencard-3.0.3/src/MarshallMonad.lhs
>> greencard-3.0.3/src/Name.lhs
>> greencard-3.0.3/src/NameSupply.lhs
>> greencard-3.0.3/src/Package.lhs
>> greencard-3.0.3/src/Package.lhs.in
>> greencard-3.0.3/src/Parse.ly
>> greencard-3.0.3/src/PrettyUtils.lhs
>> greencard-3.0.3/src/Proc.lhs
>> greencard-3.0.3/src/Process.lhs
>> greencard-3.0.3/src/Target.lhs
>> greencard-3.0.3/src/Type.lhs
>> 5 (0) 19:27:22 mf@yoyo:/tmp2 $ cd greencard-3.0.3
>> 6 (0) 19:27:24 mf@yoyo:/tmp2/greencard-3.0.3 $ make prefix=/tmp2/
>> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
>> happy  Parse.ly
>> unused terminals: 1
>> rm -f .depend
>> touch .depend
>> ghc -M -optdep-f -optdep.depend -optdep-xFiniteMap -optdep-xPretty
>> -recomp -O -fglasgow-exts     Casm.lhs DIS.lhs Decl.lhs ErrMonad.lhs
>> FillIn.lhs FillInMonad.lhs GCToken.lhs GreenCard.lhs Lex.lhs
>> LexM.lhs ListUtils.lhs MarshallMonad.lhs Name.lhs NameSupply.lhs
>> Package.lhs PrettyUtils.lhs Proc.lhs Process.lhs Target.lhs Type.lhs Parse.hs
>> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
>> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
>> ghc -recomp -O -fglasgow-exts     -c Target.lhs -o Target.o
>> ghc -recomp -O -fglasgow-exts     -c PrettyUtils.lhs -o PrettyUtils.o
>> ghc -recomp -O -fglasgow-exts     -c Casm.lhs -o Casm.o
>
>> Casm.lhs:544:1:
>>     Warning: Pattern match(es) are overlapped
>>              In a case alternative: _ -> ...
>
>> Casm.lhs:577:1:
>>     Warning: Pattern match(es) are overlapped
>>              In a case alternative: _ -> ...
>
>> Casm.lhs:616:4:
>>     Warning: Pattern match(es) are overlapped
>>              In a case alternative: _ -> ...
>
>> Casm.lhs:631:5:
>>     Warning: Pattern match(es) are overlapped
>>              In a case alternative: _ -> ...
>> ghc -recomp -O -fglasgow-exts     -c ListUtils.lhs -o ListUtils.o
>> ghc -recomp -O -fglasgow-exts     -c ErrMonad.lhs -o ErrMonad.o
>> ghc -recomp -O -fglasgow-exts     -c Name.lhs -o Name.o
>> ghc -recomp -O -fglasgow-exts     -c DIS.lhs -o DIS.o
>> ghc -recomp -O -fglasgow-exts     -c Type.lhs -o Type.o
>> ghc -recomp -O -fglasgow-exts     -c Decl.lhs -o Decl.o
>> ghc -recomp -O -fglasgow-exts     -c FillInMonad.lhs -o FillInMonad.o
>> ghc -recomp -O -fglasgow-exts     -c NameSupply.lhs -o NameSupply.o
>> ghc -recomp -O -fglasgow-exts     -c FillIn.lhs -o FillIn.o
>> ghc -recomp -O -fglasgow-exts     -c GCToken.lhs -o GCToken.o
>> ghc -recomp -O -fglasgow-exts     -c MarshallMonad.lhs -o MarshallMonad.o
>> ghc -recomp -O -fglasgow-exts     -c Proc.lhs -o Proc.o
>> ghc -recomp -O -fglasgow-exts     -c LexM.lhs -o LexM.o
>> ghc -recomp -O -fglasgow-exts     -c Lex.lhs -o Lex.o
>> ghc -recomp -O -fglasgow-exts   -Onot  -c Parse.hs -o Parse.o
>
>> Parse.hs:1733:1:
>>     Warning: Pattern match(es) are overlapped
>>              In a case alternative: _ -> ...
>> ghc -recomp -O -fglasgow-exts     -c Process.lhs -o Process.o
>> ghc -recomp -O -fglasgow-exts     -c Package.lhs -o Package.o
>> ghc -recomp -O -fglasgow-exts   -cpp -DBEGIN_GHC_ONLY='-}'
>> -DEND_GHC_ONLY='{-' -DBEGIN_NOT_FOR_GHC='{-' -DEND_NOT_FOR_GHC='-}'
>> -DPURE_WIN32=0  -c GreenCard.lhs -o GreenCard.o
>> ghc     -c ErrorHook.c -o ErrorHook.o
>> ghc -recomp -O -fglasgow-exts     -o greencard-bin Casm.o DIS.o
>> Decl.o ErrMonad.o FillIn.o FillInMonad.o GCToken.o GreenCard.o Lex.o
>> LexM.o ListUtils.o MarshallMonad.o Name.o NameSupply.o Package.o
>> PrettyUtils.o Proc.o Process.o Target.o Type.o Parse.o ErrorHook.o
>> Casm.o: In function `s201_info':
>> (.text+0x168): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_con_info'
>> Casm.o: In function `s201_info':
>> (.text+0x17b): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_con_info'
>> Casm.o: In function `s201_info':
>> (.text+0x19d): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
>> Casm.o: In function `s201_info':
>> (.text+0x1b7): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_con_info'
>> Casm.o: In function `s201_info':
>> (.text+0x1ca): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_con_info'
>> Casm.o: In function `s201_info':
>> (.text+0x1e9): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
>> Casm.o: In function `s201_info':
>> (.text+0x1f0): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Beside_con_info'
>
>> [...  these continue for every object file on the command line; a bit
>> over 2000 message of the same type in total...]
>
>> Type.o: In function `sBv_info':
>> (.text+0x1b2b): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Beside_con_info'
>> Type.o: In function `sZT_info':
>> (.text+0x1ed3): undefined reference to
>> `__stginit_prettyzm1zi0zi0zi0_TextziPrettyPrint_'
>> Type.o: In function `sBb_info':
>> (.text+0x1988): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_go6_info'
>> Type.o: In function `sBf_info':
>> (.text+0x1a12): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_go6_info'
>> Type.o: In function `sZU_info':
>> (.text+0x1b96): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_text_info'
>> Type.o: In function `rvv_closure':
>> (.data+0x8): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Chr_static_info'
>> Type.o: In function `rvH_closure':
>> (.data+0x64): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_TextBeside_static_info'
>> Type.o: In function `rvH_closure':
>> (.data+0x6c): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_lvl3_closure'
>> Type.o: In function `rvH_closure':
>> (.data+0x70): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Empty_closure'
>> Type.o: In function `rvN_closure':
>> (.data+0xb0): undefined reference to
>> `prettyzm1zi0zi0zi0_TextziPrettyPrintziHughesPJ_Str_static_info'
>> collect2: ld returned 1 exit status
>> make[1]: *** [greencard-bin] Error 1
>> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
>> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/lib'
>> ghc -package-name greencard -cpp -fglasgow-exts -fno-prune-tydecls
>> -c Foreign/GreenCard.hs -o Foreign/GreenCard.o -hisuf hi
>> ghc-6.8.2: unrecognised flags: -fno-prune-tydecls
>> Usage: For basic information, try the `--help' option.
>> make[1]: *** [Foreign/GreenCard.o] Error 1
>> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/lib'
>> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'
>> make[1]: Nothing to be done for `all'.
>> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/src'
>> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/lib'
>> ghc -package-name greencard -cpp -fglasgow-exts -fno-prune-tydecls
>> -prof -c Foreign/GreenCard.hs -o Foreign/GreenCard.p_o -hisuf p_hi
>> ghc-6.8.2: unrecognised flags: -fno-prune-tydecls
>> Usage: For basic information, try the `--help' option.
>> make[1]: *** [Foreign/GreenCard.p_o] Error 1
>> make[1]: Leaving directory `/hime/tmp2/greencard-3.0.3/lib'
>> make: *** [all] Error 2
>
>> the errors about no-prune-tydecls are easy enough to fix:
>
>> $ diff -r greencard-3.0.3{,-patched}
>> diff -r greencard-3.0.3/examples/Gdbm/Makefile
>> greencard-3.0.3-patched/examples/Gdbm/Makefile
>> 28d27
>> < HC_OPTS += -fno-prune-tydecls
>> diff -r greencard-3.0.3/lib/Makefile
>> greencard-3.0.3-patched/lib/Makefile
>> 6c6
>> < GHC_OPTS = -cpp -fglasgow-exts -fno-prune-tydecls
>> ---
>>> GHC_OPTS = -cpp -fglasgow-exts
>> $
>
>
>> this helps, but the linker errors are unrealted, and i don't know what
>> to make of them.  (I guess I should study how ghc generates C code at
>> this point?  it does feel like something obvious...)
>
>
>> thanks,
>> cheers,
>> matthias
>> _______________________________________________
>> Haskell-Cafe mailing list
>> [hidden email]
>> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
>
> --
> Best regards,
>  Bulat                            mailto:[hidden email]
>
> _______________________________________________
> Haskell-Cafe mailing list
> [hidden email]
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
>

_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe
Reply | Threaded
Open this post in threaded view
|

Re: cannot build greencard

Daniel Fischer-4
In reply to this post by mf-hcafe-15c311f0c
Am Mittwoch 02 September 2009 22:44:25 schrieb [hidden email]:

> hi,
>
> i am stuck with a linker error in greencard, and haven't found
> anything online, so i am addressing you for fresh ideas.  as soon as i
> get this sorted out, i will try to turn the answer into a patch that
> you can consider for the next release.
>
> SYMPTOMS: greencard 3.0.3 and 3.01 do not compile with ghc-6.8 (debian
> lenny package) and 6.10 (darcs copy, checked out yesterday).  here is
> what happens:
>

> 6 (0) 19:27:24 mf@yoyo:/tmp2/greencard-3.0.3 $ make prefix=/tmp2/
> make[1]: Entering directory `/hime/tmp2/greencard-3.0.3/src'

don't install with make, try

cabal update && cabal install greencard

if you have a cabal binary, otherwise

ghc --make Steup
./Setup configure --user --prefix=$HOME   (or whatever configure options you want)
./Setup build
./Setup install
_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe
Reply | Threaded
Open this post in threaded view
|

Re: cannot build greencard

Daniel Fischer-4
In reply to this post by Dan Weston
Am Mittwoch 02 September 2009 23:23:47 schrieb Dan Weston:
> Yet strangely, the last upload was Sun Apr 19 21:42:04 UTC 2009 and
> hackage claims it builds without failure with ghc-6.10.
>
> And in fact it builds just fine for me, so maybe it is worth finding out
> why it doesn't build for you. Are you using ghc-6.10.4 and the latest
> version of cabal?

He used make, not cabal.
My guess is that the makefiles haven't been updated because we now have Cabal and cabal.
Formerly, Text.PrettyPrint.HughesPJ was in base, now it's in pretty, since --make is none
of the HC_OPTIONS in the makefiles, ghc can't find HughesPJ, thus the linker errors.
_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe
Reply | Threaded
Open this post in threaded view
|

Solved (Was: cannot build greencard)

mf-hcafe-15c311f0c


Yes, it works:

$ greencard -V
greencard, version 3.00

(Daniel: You were right; I made the mistake of following the
instructions in the README :).  Now I've finally switched to Cabal,
and that did the trick.  Bulat: Yes, I am aware of all the other
projects, but greencard seems to be a front-end to FFI, and it looks
alive enough to me right now, right?)

(Btw the "report-bugs-to" e-mail doesn't work.)

(Btw2:

diff -r cabal-install-0.6.2/bootstrap.sh cabal-install-0.6.2-/bootstrap.sh
166c166
< dep_pkg "parsec" "2\."
---
> dep_pkg "parsec" "3\."

shouldn't be a problem, right?)


Thanks everybody,
Cheers,
Matthias



On Wed, Sep 02, 2009 at 11:41:34PM +0200, Daniel Fischer wrote:

> To: [hidden email]
> Cc: Dan Weston <[hidden email]>,
> "[hidden email]" <[hidden email]>
> From: Daniel Fischer <[hidden email]>
> Date: Wed, 2 Sep 2009 23:41:34 +0200
> Subject: Re: [Haskell-cafe] cannot build greencard
>
> Am Mittwoch 02 September 2009 23:23:47 schrieb Dan Weston:
> > Yet strangely, the last upload was Sun Apr 19 21:42:04 UTC 2009 and
> > hackage claims it builds without failure with ghc-6.10.
> >
> > And in fact it builds just fine for me, so maybe it is worth finding out
> > why it doesn't build for you. Are you using ghc-6.10.4 and the latest
> > version of cabal?
>
> He used make, not cabal.
> My guess is that the makefiles haven't been updated because we now have Cabal and cabal.
> Formerly, Text.PrettyPrint.HughesPJ was in base, now it's in pretty, since --make is none
> of the HC_OPTIONS in the makefiles, ghc can't find HughesPJ, thus the linker errors.
>
>  
>  ** ACCEPT: CRM114 PASS osb unique microgroom Matcher **
> CLASSIFY succeeds; success probability: 1.0000  pR: 11.1886
> Best match to file #0 (nonspam.css) prob: 1.0000  pR: 11.1886  
> Total features in input file: 2456
> #0 (nonspam.css): features: 758386, hits: 2553116, prob: 1.00e+00, pR:  11.19
> #1 (spam.css): features: 1686574, hits: 2754260, prob: 6.48e-12, pR: -11.19
>  
_______________________________________________
Haskell-Cafe mailing list
[hidden email]
http://www.haskell.org/mailman/listinfo/haskell-cafe