Hi, I'm trying to build and install readline on a i386 MacBook with Snow Leopard.
I have made the following steps:
download and extract readline-6.0.tar.gz
./configure
make everything
sudo make install
I checked the examples and they appear to work (for instance rltest has support for history). This is the output of file libreadline.6.0.dylib :
libreadline.6.0.dylib: Mach-O 64-bit dynamically linked shared library x86_64
I expected it to be i386 instead, but then if the examples work...
then I have installed the readline package from cabal with the following:
cabal install readline --reinstall --configure-option=--with-readline-includes="/usr/local/include" --configure-option=--with-readline-libraries="/usr/local/lib"
It appears to work: note that without the configure-options installation fails. I have used the --reinstall flag to force reinstallation since I have already made many trials.
This is the output of cabal info:
$ cabal info readline
* readline (library)
Synopsis: An interface to the GNU readline library
Latest version available: 1.0.1.0
Latest version installed: 1.0.1.0
Homepage: [ Not specified ]
Bug reports: [ Not specified ]
Description: More information on readline can be found at
http:\/\/www.gnu.org\/directory\/readline.html.
License: GPL
Maintainer: [email protected]
Source repo: [ Not specified ]
Flags: split-base
Dependencies: base >=3, process -any, base <3
Documentation: [ Not installed ]
Cached: Yes
Modules:
System.Console.Readline
System.Console.SimpleLineEditor
Ok, it seems that I am done. No, I am not:
GHCi, version 6.10.4: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer ... linking ... done.
Loading package base ... linking ... done.
Prelude> import System.Console.Readline
Prelude System.Console.Readline> do { readline "Prompt" }
Loading package syb ... linking ... done.
Loading package base-3.0.3.1 ... linking ... done.
Loading package filepath-1.1.0.2 ... linking ... done.
Loading package old-locale-1.0.0.1 ... linking ... done.
Loading package old-time-1.0.0.2 ... linking ... done.
Loading package unix-2.3.2.0 ... linking ... done.
Loading package directory-1.0.0.3 ... linking ... done.
Loading package process-1.0.1.1 ... linking ... done.
Loading package readline-1.0.1.0 ... linking ... <interactive>:
/Users/macbook/.cabal/lib/readline-1.0.1.0/ghc-6.10.4/HSreadline-1.0.1.0.o: unknown symbol `_rl_basic_quote_characters'
ghc: unable to load package `readline-1.0.1.0'
Unsuprisingly, I am also unable to build packages which depend on readline (eg JHC).
Can you point me in the right direction? Tell me if you need other info.
Thanks in advance.