GHCI and readline package
sof at galois.com
Mon Nov 1 23:30:57 EST 2004
You can make 'readline' load with GHCi 6.2.2 with
just a little bit of effort -- try the following:
# any old temporary working directory will do
bash$ mkdir c:/tmp/hack
bash$ cd c:/tmp/hack
# assuming you've install 6.2.2 in c:/ghc/ghc-6.2.2
bash$ c:/ghc/ghc-6.2.2/bin/ar x \
bash$ c:/ghc/ghc-6.2.2/gcc-lib/ld --whole-archive \
-r -x -o readline.o c:/ghc/ghc-6.2.2/gcc-lib/libreadline.a \
bash$ cp readline.o c:/ghc/ghc-6.2.2/
# you may now delete the temp dir.
Next, manually edit your c:/ghc/ghc-6.2.2/package.conf,
editing the "readline" package's extra_libraries field to:
extra_libraries = ["readline", "advapi32"],
Save the changes & you should be ready to go.
----- Original Message -----
From: "Wassell, Mark P (GE Energy)" <mark.wassell at ps.ge.com>
To: <glasgow-haskell-users at haskell.org>
Sent: Monday, November 01, 2004 19:34
Subject: GHCI and readline package
> I'm having a problem running ghci and loading the readline package on
> C:\Software\haskell\ghc622\bin>ghci -package readline
> ghci -package readline
> ___ ___ _
> / _ \ /\ /\/ __(_)
> / /_\// /_/ / / | | GHC Interactive, version 6.2.2, for Haskell 98.
> / /_\\/ __ / /___| | http://www.haskell.org/ghc/
> \____/\/ /_/\____/|_| Type :? for help.
> Loading package base ... linking ... done.
> Loading package readline ... linking ...
> C:/Software/haskell/ghc622/HSreadline.o: unknown symbol
> ghc.exe: unable to load package `readline'
> I have seen the follow in the user guide:
> "For some reason, Mingw ships with the readline library, but not with the
> readline headers. As a result, GHC (like Hugs) does not use readline for
> interactive input on Windows. You can get a close simulation by using an
> emacs shell buffer!"
> but I assume I need readline as util needs it and util is needed by data
> which is needed by wxcore.
More information about the Glasgow-haskell-users