Re: linking problem on Solaris 2.5.1

Aleksandar Bakic (bakicale@cps.msu.edu)
Sat, 30 Aug 1997 13:18:59 -0400 (EDT)

I changed the qt's Makefile.am so that it uses libtool. It almost
passed. The problem is that in solaris.s (an Assembler file),
there are references to qt_error and that symbol is defined in
qt.c. The linker reports that the object file generated from the
Assembler code cannot find the symbol it referes to. How do I fix this?

Aleksandar

>
> Aleksandar Bakic <bakicale@cps.msu.edu> writes:
>
> > When trying to install guile-tcltk, I am getting this error on
> >
> > SunOS element 5.5.1 Generic_103640-04 sun4u sparc SUNW,Ultra-1
> >
> > and I didn't get in on a Linux i586 machine. Any hints?
> >
> > /usr/ccs/bin/ld -G -z text -h libgtcltk.so.0 -o .libs/libgtcltk.so.0.0.0 guile-tcl.lo guile-tk.lo gtcltk-module.lo -ltcl7.5 -ltk4.1 -ltcl7.5 -lguile -lqt -lnsl -lsocket -ldl -lm -lX11 -L/user/bakicale/hsnp/install/lib -L/usr/openwin/lib
> > Text relocation remains referenced
>
> I'm not sure, but I think the problem comes from trying to link a
> shared libguile library with a static libqt.
>
> One way to fix would then be to issue --disable-shared when
> configuring Guile, but the correct solution would be to improve the qt
> configuration so that it uses libtool.
>
> I found the following file in my directory:
>
> fixqt:
> ----------------------------------------------------------------------
> ../libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I/afs/nada.kth.se/misc/lang/guile/1.3a.pre1/.obj/sun4_5X/guile-core/../../../../gnu/guile-core/qt -I../libguile -g -O2 -I/afs/nada.th.se/misc/lang/guile/gnu/guile-core/qt -I../qt -Wall -Wpointer-arith -c /afs/nada.kth.se/misc/lang/guile/gnu/guile-core/qt/qt.c
> ../libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I/afs/nada.kth.se/misc/lang/guile/1.3a.pre1/.obj/sun4_5X/guile-core/../../../../gnu/guile-core/qt -I../libguile -g -O2 -I/afs/nada.th.se/misc/lang/guile/gnu/guile-core/qt -I../qt -Wall -Wpointer-arith -c /afs/nada.kth.se/misc/lang/guile/gnu/guile-core/qt/md/null.c
> mv -f null.o qtmdc.o
> mv -f null.lo qtmdc.lo
> gcc -DHAVE_CONFIG_H -I. -I/afs/nada.kth.se/misc/lang/guile/1.3a.pre1/.obj/sun4_5X/guile-core/../../../../gnu/guile-core/qt -I../libguile -g -O2 -I/afs/nada.th.se/misc/lang/guile/gnu/guile-core/qt -I../qt -Wall -Wpointer-arith -c -fPIC -DPIC /afs/nada.kth.se/misc/lang/guile/gnu/guile-core/qt/md/sparc.s
> mv -f sparc.o qtmds.lo
> ../libtool --mode=link gcc -g -o libqt.la -rpath /afs/nada.kth.se/misc/lang/guile/1.3a.pre1/lib -version-info 0:0 -rpath /afs/nada.kth.se/misc/lang/guile/1.3a.pre1/lib qt.lo qtmds.lo qtmdc.lo
> ../libtool --mode=install /usr/gnu/bin/install -c libqt.la /misc/lang/guile/1.3a.pre1/lib/libqt.la
> ----------------------------------------------------------------------
>
> Presumably some other thread of ME put it there to remind other
> threads to use it in case qt doesn't build properly. I guess you
> could use it if you query-replace the paths. It looks like it builds
> a shared libqt...
>
> /mdj
>

-- 
Aleksandar Bakic, Comp.Sci. graduate student at Michigan State University
e-mail: bakicale@cps.msu.edu