[Ecls-list] broken local installation of ecl

Juan Jose Garcia-Ripoll juanjose.garciaripoll at googlemail.com
Wed Aug 27 05:03:12 UTC 2008


On Wed, Aug 27, 2008 at 5:42 AM, Robert Dodier <robert.dodier at gmail.com> wrote:
> I was able to get ECL to run without LD_LIBRARY_PATH.
>
> LDFLAGS=-Wl,-rpath=/tmp/ecl-foo/lib ./configure --prefix=/tmp/ecl-foo
> make; make install

This is the recommended way to tell an executable how to locate its
libraries if you do not want to mess around with the LD_LIBRARY_PATH
environment variable, nor with /etc/ld.config, etc

> However, I could not convince ECL to build Maxima.
> At least one problem (there may very well be others) is that at
> one step ECL wants to call GCC via SYSTEM.
> However the GCC command line (which, I guess, was generated
> by ECL) has -lecl in it, and GCC complains that it cannot find that
> library.

The location cannot be a problem for gcc. ECL passes a flag
-L$prefix/lib with the location of the ecl library, so there must be
some other problem or limitation on your system, because this has
worked for all systems I tried:

$ LDFLAGS="-Wl,--rpath,$HOME/lib" ./configure -prefix=$HOME ...
...
$ make; make instal
...
$ which ecl
/home/jjgarcia/bin/ecl
$ ldd `which ecl`
	linux-vdso.so.1 =>  (0x00007fffc61fe000)
	libecl.so => /home/jjgarcia/lib/libecl.so (0x00007f14bdb45000)
	libdl.so.2 => /lib/libdl.so.2 (0x00007f14bd941000)
	libm.so.6 => /lib/libm.so.6 (0x00007f14bd6c0000)
	libc.so.6 => /lib/libc.so.6 (0x00007f14bd35e000)
	libgc.so.1 => /usr/lib/libgc.so.1 (0x00007f14bd11e000)
	libgmp.so.3 => /usr/lib/libgmp.so.3 (0x00007f14bcedf000)
	/lib64/ld-linux-x86-64.so.2 (0x00007f14bded5000)
	libpthread.so.0 => /lib/libpthread.so.0 (0x00007f14bccc3000)
	libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00007f14bcab5000)
$ cd $HOME/src/test-files
$ cat foo.lsp
(print 'HOLA)
(print 'MUNDO)

$ ecl
ECL (Embeddable Common-Lisp) 0.9l (CVS 2008-06-19 17:09)
Copyright (C) 1984 Taiichi Yuasa and Masami Hagiya
Copyright (C) 1993 Giuseppe Attardi
Copyright (C) 2000 Juan J. Garcia-Ripoll
ECL is free software, and you are welcome to redistribute it
under certain conditions; see file 'Copyright' for details.
Type :h for Help.  Top level.
> (compile-file "foo" :load t)
;;; Compiling foo.
;;; OPTIMIZE levels: Safety=2, Space=0, Speed=3, Debug=0
;;; End of Pass 1.
;;; Note: Invoking external command:
;;;   gcc  -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -g -O2 -fPIC  -Dlinux
-O "-I/home/jjgarcia/include/" -w -c "/home/jjgarcia/foo.c" -o
"/home/jjgarcia/foo.o"
;;; Note: Invoking external command:
;;;   gcc -o "/home/jjgarcia/foo.fas" -L"/home/jjgarcia/lib/"
"/home/jjgarcia/foo.o"  -shared -Wl,--rpath,/home/jjgarcia/lib
-Wl,--rpath,/home/jjgarcia/lib  -lecl -ldl  -lm   -lgc -lgmp
;;; Finished compiling foo.
;;; Loading "/home/jjgarcia/foo.fas"
HOLA
MUNDO
#P"/home/jjgarcia/foo.fas"
NIL
NIL


-- 
Instituto de Física Fundamental
CSIC, Serrano, 113, Madrid 28040 (Spain)
http://juanjose.garciaripoll.googlepages.com


More information about the ecl-devel mailing list