chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] Building readline extension on Mac OS X


From: bsd1628
Subject: Re: [Chicken-users] Building readline extension on Mac OS X
Date: Tue, 15 Aug 2006 09:59:13 -0400
User-agent: Mail/News 1.5.0.4 (X11/20060804)

Graham Ashton wrote:
I've got readline installed via DarwinPorts, but am unable to persuade
csc to find everything that it needs to get it build. I wonder if
anybody here could help...

Here are the files in my readline package:

clown% port installed | grep readline
 readline @5.0.005_0+darwin_8 (active)
clown% port contents readline
Port readline contains:
 /opt/local/include/readline/chardefs.h
 /opt/local/include/readline/history.h
 /opt/local/include/readline/keymaps.h
 /opt/local/include/readline/readline.h
 /opt/local/include/readline/rlconf.h
 /opt/local/include/readline/rlstdc.h
 /opt/local/include/readline/rltypedefs.h
 /opt/local/include/readline/tilde.h
 /opt/local/lib/libhistory.5.0.dylib
 /opt/local/lib/libhistory.5.dylib
 /opt/local/lib/libhistory.a
 /opt/local/lib/libhistory.dylib
 /opt/local/lib/libreadline.5.0.dylib
 /opt/local/lib/libreadline.5.dylib
 /opt/local/lib/libreadline.a
 /opt/local/lib/libreadline.dylib
 /opt/local/share/info/history.info
 /opt/local/share/info/readline.info
 /opt/local/share/info/rluserman.info
 /opt/local/share/man/man3/history.3.gz
 /opt/local/share/man/man3/readline.3.gz

When I run "chicken-setup readline.egg" I get this:

clown% chicken-setup readline.egg
 tar xvf ../readline.egg
readline.setup
readline.scm
 /usr/bin/csc -feature compiling-extension -s -O2 -d0 readline.scm -L
-lreadline -L -ltermcap
readline.c: In function 'stub27':
readline.c:37: warning: implicit declaration of function 'history_truncate_file'
/usr/bin/ld: Undefined symbols:
_history_truncate_file
collect2: ld returned 1 exit status
*** Shell command terminated with exit status 1: gcc readline.o
-lchicken -o readline.so -fPIC -bundle -L/usr/lib -lreadline -ltermcap
-ldl -lffi -lm  -ldl -lffi -lchicken
Error: shell invocation failed with non-zero return status
"/usr/bin/csc -feature compiling-extension -s -O2 -d0 readline.scm -L
-lreadlin...
1

I took this to mean that it couldn't find readline/history.h, so
edited readline.setup, specifying /opt/local/include with -I. It then
got a bit further, but the linker failed. Adding -L/opt/local/lib
hasn't helped (as you can see below):

clown% chicken-setup readline
 /usr/bin/csc -feature compiling-extension -s -O2 -d0
-I/opt/local/include readline.scm -L/opt/local/lib -lreadline -L
-ltermcap
/usr/bin/ld: Undefined symbols:
_history_truncate_file
collect2: ld returned 1 exit status
*** Shell command terminated with exit status 1: gcc readline.o
-lchicken -o readline.so -fPIC -bundle -L/usr/lib -L/opt/local/lib
-lreadline -ltermcap -ldl -lffi -lm  -ldl -lffi -lchicken
Error: shell invocation failed with non-zero return status
"/usr/bin/csc -feature compiling-extension -s -O2 -d0
-I/opt/local/include read...
1

Any ideas? I'd really like to get readline support in the interactive
interpreter...

Cheers,

Graham


_______________________________________________
Chicken-users mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/chicken-users



On NetBSD I added this to my environment vars to help chicken
find things.  Assuming chicken is installed in /usr/local

csh:
setenv CHICKEN_PREFIX  /usr/local

or

bash:
export CHICKEN_PREFIX=/usr/local








reply via email to

[Prev in Thread] Current Thread [Next in Thread]