Problems compiling inetutils against readline-6.0

Matthew Burgess matthew at linuxfromscratch.org
Sat Feb 28 05:10:53 PST 2009


On Sat, 28 Feb 2009 3:46:58 -0700, Matthew Burgess <matthew at linuxfromscratch.org> wrote:
> Hi all,
> 
> I get this in my latest build logs, when trying to compile inetutils-1.6
> against readline.6.0:
> 
> mv -f .deps/ruserpass.Tpo .deps/ruserpass.Po
> gcc -std=gnu99  -g -O2   -o ftp cmds.o cmdtab.o domacro.o ftp.o main.o
> ruserpass.o -L../libinetutils -linetutils -L../lib -lgnu  -lreadline
> -lcurses -lhistory -lresolv -lnsl
> /usr/lib/gcc/i686-pc-linux-gnu/4.3.3/../../../libreadline.a(xmalloc.o): In
> function `xrealloc':
> /sources/readline-6.0/xmalloc.c:71: multiple definition of `xrealloc'
> ../lib/libgnu.a(xmalloc.o):/sources/inetutils-1.6/lib/xmalloc.c:60: first
> defined here
> /usr/lib/gcc/i686-pc-linux-gnu/4.3.3/../../../libreadline.a(xmalloc.o): In
> function `xmalloc':
> /sources/readline-6.0/xmalloc.c:58: multiple definition of `xmalloc'
> ../lib/libgnu.a(xmalloc.o):/sources/inetutils-1.6/lib/xmalloc.c:48: first
> defined here
> collect2: ld returned 1 exit status

This was caused by my build scripts having not updated the .so version number
in readline's instructions when we create the softlinks for libreadline.so.*
and libhistory.so.*.  Those files are obviously called lib{readline,history}.so.6
now, but my scripts were still trying to operate on lib{readline,history.so.5.
That caused inetutils to try to link against the static version of libreadline
instead of the dynamic version.  Once the symlinks were fixed up, inetutils now
correctly links against the dynamic version again, and it compiles cleanly.

Regards,

Matt.




More information about the lfs-dev mailing list