! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Build error due to implicit DSO linking
Status:
RESOLVED: FIXED
Product:
Ristretto
Component:
Application

Comments

Description Christoph Wickert editbugs 2010-11-25 21:30:20 CET
Original bug report at https://bugzilla.redhat.com/show_bug.cgi?id=565114

Fedora, Ubuntu and other distributions changed the linker default behavior to --no-add-needed. The rationale for this change is outlined in 
http://fedoraproject.org/wiki/Features/ChangeInImplicitDSOLinking

With --no-add-needed rostretto 0.0.22 fails to build:
/usr/bin/ld: ristretto-main_window.o: undefined reference to symbol 'XInternAtom'
/usr/bin/ld: note: 'XInternAtom' is defined in DSO /usr/lib/libX11.so.6 so try adding it to the linker command line
/usr/lib/libX11.so.6: could not read symbols: Invalid operation
collect2: ld returned 1 exit status

In order to fix this, I changed:

--- ristretto-0.0.91.orig/src/Makefile.in	2010-07-12 23:17:27.000000000 +0200
+++ ristretto-0.0.91/src/Makefile.in	2010-07-13 12:46:30.000000000 +0200
@@ -146,7 +146,7 @@
 INTLTOOL_MERGE = @INTLTOOL_MERGE@
 INTLTOOL_PERL = @INTLTOOL_PERL@
 INTLTOOL_UPDATE = @INTLTOOL_UPDATE@
-LDFLAGS = @LDFLAGS@
+LDFLAGS = @LDFLAGS@ -lX11
 LIBEXIF_CFLAGS = @LIBEXIF_CFLAGS@
 LIBEXIF_LIBS = @LIBEXIF_LIBS@
 LIBEXIF_REQUIRED_VERSION = @LIBEXIF_REQUIRED_VERSION@

Of course this should needs to happen in Makefile.am, but I'm just a lazy packager.
Comment 1 Stephan Arts editbugs 2011-07-19 09:09:09 CEST
Confirmed.
Comment 2 Stephan Arts editbugs 2011-07-29 21:10:43 CEST
(In reply to comment #1)
> Confirmed.

Fixed in 0.0.92

Bug #6873

Reported by:
Christoph Wickert
Reported on: 2010-11-25
Last modified on: 2011-07-29

People

Assignee:
Stephan Arts
CC List:
0 users

Version

Version:
0.0.22

Attachments

Additional information