GNOME Bugzilla – Bug 106434
GIMP/libgimp link against libgimp-*.so.* from older installation
Last modified: 2003-03-25 23:18:51 UTC
SSIA, when I build 1.3.12, the following files linked against libgimp*.so.9 /from gimp-1.3.9 which was installed until now): /usr/bin/gimp-1.3 /usr/lib/gimp/1.3/python/gimpmodule.so /usr/lib/libgimpmodule-1.3.so.12 /usr/lib/libgimpmodule-1.3.so.12.0.0 I guess (but haven't checked) that it is libgimpmodule.so linking against it and the other ones are only "innocent victims" of this.
I'm pretty sure it doesn't do this here. You will need to investigate further instead of guessing.
I'm pretty sure it doesn't do this with you because you don't have older libgimp*.so* files installed in /usr/lib (which is in the compiler's link path by default) but somewhere else (like /opt/gimp/... or /usr/local/...), just a guess. I rebuilt my 1.3.9 RPM packages, installed them, rebuilt the 1.3.12 packages and voila! the files listed above are linked against libgimp*.so.9 _and_ libgimp*.so.12. I'm not really into GIMP development, I'm just packaging the betas for "my own pleasure" so I can't really help you with this (my guesses are just that -- my observations from packaging combined with my little experience from building own stuff). On request, I can attach any source or binary RPMs though (you may need the Red Hat Phoebe beta or Rawhide for the binaries).
How can the files be linked against libgimp*.so.9 _and_ libgimp*.so.12 at the same time? Could you please investigate if libgimpmodule is the cause of the problem as you guessed (but never checked).
Yes it is ;-). There's something really strange going on: when building gimp, libgimpmodule gets linked against the new libgimpbase, when installing it spits out (here 1.3.13 with 1.3.12 installed, long snippet at bottom): [...] libtool: install: warning: relinking `libgimpmodule-1.3.la' [...] which builds a (new) ".libs/libgimpmodule-1.3.so.13.0.0T" (yes, with a T at the end, but what's that?) which is linked against the old lib (libgimpbase-1.3.12.so). After that, the prograsm itself gets relinked against that lib as well. I assume a bug in either automake or libtool (it simply shouldn't relink) and tried playing around with "aclocal && automake && autoconf" as well as "libtoolize --copy --force --automake" to work around the problem (having recent versions of it installed) but to no avail. Upon further digging I saw an ominous '-L/usr/lib' before any other -L lines in the gcc link line so I think that's the culprit. I think it comes from gimp-print (at least it's in `gimpprint-config --libs`), so I'll close this bug and rather file one against gimp-print. Cheers, Nils long "make install" snippet: [...] Making install in libgimpmodule make[1]: Entering directory `/home/nils/redhat/BUILD/gimp-1.3.13/libgimpmodule' make[2]: Entering directory `/home/nils/redhat/BUILD/gimp-1.3.13/libgimpmodule' /bin/sh ../mkinstalldirs /var/tmp/gimp-beta-1.3.13-root/usr/lib /bin/sh ../libtool --mode=install /usr/bin/install -c libgimpmodule-1.3.la /var/tmp/gimp-beta-1.3.13-root/usr/lib/libgimpmodule-1.3.la libtool: install: warning: relinking `libgimpmodule-1.3.la' (cd /home/nils/redhat/BUILD/gimp-1.3.13/libgimpmodule; /bin/sh ../libtool --mode=relink gcc -O2 -g -pipe -march=i386 -mcpu=i686 -Wall -o libgimpmodule-1.3.la -rpath /usr/lib -version-info 13:0:0 gimpmodule.lo gimpmoduledb.lo ../libgimpbase/libgimpbase-1.3.la -lgobject-2.0 -lglib-2.0 -Wl,--export-dynamic -lgmodule-2.0 -ldl -lglib-2.0 -inst-prefix-dir /var/tmp/gimp-beta-1.3.13-root) gcc -shared gimpmodule.lo gimpmoduledb.lo -L/usr/lib -L/var/tmp/gimp-beta-1.3.13-root/usr/lib -lgimpbase-1.3 -lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0 -Wl,--export-dynamic -Wl,-soname -Wl,libgimpmodule-1.3.so.13 -o .libs/libgimpmodule-1.3.so.13.0.0 /usr/bin/install -c .libs/libgimpmodule-1.3.so.13.0.0T /var/tmp/gimp-beta-1.3.13-root/usr/lib/libgimpmodule-1.3.so.13.0.0 (cd /var/tmp/gimp-beta-1.3.13-root/usr/lib && rm -f libgimpmodule-1.3.so.13 && ln -s libgimpmodule-1.3.so.13.0.0 libgimpmodule-1.3.so.13) (cd /var/tmp/gimp-beta-1.3.13-root/usr/lib && rm -f libgimpmodule-1.3.so && ln -s libgimpmodule-1.3.so.13.0.0 libgimpmodule-1.3.so) /usr/bin/install -c .libs/libgimpmodule-1.3.lai /var/tmp/gimp-beta-1.3.13-root/usr/lib/libgimpmodule-1.3.la /usr/bin/install -c .libs/libgimpmodule-1.3.a /var/tmp/gimp-beta-1.3.13-root/usr/lib/libgimpmodule-1.3.a ranlib /var/tmp/gimp-beta-1.3.13-root/usr/lib/libgimpmodule-1.3.a chmod 644 /var/tmp/gimp-beta-1.3.13-root/usr/lib/libgimpmodule-1.3.a libtool: install: warning: remember to run `libtool --finish /usr/lib' /bin/sh ../mkinstalldirs /var/tmp/gimp-beta-1.3.13-root/usr/include/gimp-1.3/libgimpmodule mkdir -p -- /var/tmp/gimp-beta-1.3.13-root/usr/include/gimp-1.3/libgimpmodule /usr/bin/install -c -m 644 gimpmoduletypes.h /var/tmp/gimp-beta-1.3.13-root/usr/include/gimp-1.3/libgimpmodule/gimpmoduletypes.h /usr/bin/install -c -m 644 gimpmodule.h /var/tmp/gimp-beta-1.3.13-root/usr/include/gimp-1.3/libgimpmodule/gimpmodule.h /usr/bin/install -c -m 644 gimpmoduledb.h /var/tmp/gimp-beta-1.3.13-root/usr/include/gimp-1.3/libgimpmodule/gimpmoduledb.h make[2]: Leaving directory `/home/nils/redhat/BUILD/gimp-1.3.13/libgimpmodule' make[1]: Leaving directory `/home/nils/redhat/BUILD/gimp-1.3.13/libgimpmodule' Making install in libgimpwidgets [...]
Well, the output from gimpprint-config is only used to link the print plug-in. No other Makefile.am refers to the variable PRINT_LIBS.
Hmm, seems like a libtool weirdness: - It relinks (why?). - It uses "-L/usr/lib -L/var/tmp/gimp-beta-1.3.13-root/usr/lib" instead of "-L/var/tmp/gimp-beta-1.3.13-root/usr/lib -L/usr/lib" (which links correctly), so libgimpmodule links against the installed (old) library version instead of the new version. Which version of libtool do you use?
This bug seems related to: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=71989 I will escalate it there.