Compiling gargoyle under Fedora 13

48 views
Skip to first unread message

Heiko Reese

unread,
Nov 8, 2010, 5:45:04 PM11/8/10
to garglk-dev
Hi folks,

just a short info on how to compile gargoyle under Fedora 13.

Jam produces this error message:

Link build/linux.release/garglk/gargoyle
/usr/bin/ld: build/linux.release/garglk/launchgtk.o: undefined
reference to symbol 'gtk_file_chooser_set_current_folder'
/usr/bin/ld: note: 'gtk_file_chooser_set_current_folder' is defined in
DSO /usr/lib64/libgtk-x11-2.0.so.0 so try adding it to the linker
command line
/usr/lib64/libgtk-x11-2.0.so.0: could not read symbols: Invalid
operation
collect2: ld returned 1 exit status

cc -o build/linux.release/garglk/gargoyle build/linux.release/garglk/
launchgtk.o build/linux.release/garglk/launcher.o build/linux.release/
garglk/libgarglk.so -lz -lm

...failed Link build/linux.release/garglk/gargoyle ...
...failed updating 1 target(s)...

The problem seems to be related to this Fedora feature:
https://fedoraproject.org/wiki/Features/ChangeInImplicitDSOLinking
https://fedoraproject.org/wiki/UnderstandingDSOLinkChange

Adding the libraries for gtk (and the related stuff) to the linker
call seems to fix the problem. Here's the patch:

---------
--- Jamrules.org 2010-09-27 15:05:16.000000000 +0200
+++ Jamrules 2010-11-08 22:25:24.245974982 +0100
@@ -60,7 +60,7 @@
PKGCONFIG = "pkg-config freetype2 gtk+-2.0 gdk-x11-2.0
gobject-2.0 fontconfig" ;
GARGLKCCFLAGS = "`$(PKGCONFIG) --cflags`" -fPIC ;
GARGLKLIBS = "`$(PKGCONFIG) --libs`" -ljpeg -lpng -lz ;
- LINKLIBS = -lz -lm ;
+ LINKLIBS = -lz -lm -lgtk-x11-2.0 -lgdk-x11-2.0 -lgobject-2.0 -
lglib-2.0 ;

if $(USESDL) = yes
{
--------

Could anyone not using a redhat-based distribution try this?

Cheers,
Heiko

Ben Cressey

unread,
Jan 6, 2011, 12:40:47 PM1/6/11
to google...@heiko-reese.de, garglk-dev
Heiko,

My apologies for the long radio silence on this one.

Can you try the attached patch? It uses the pkgconfig mechanism instead, but it should be equivalent to yours.

I've tested under Ubuntu 10.04 and haven't seen any issues. If it works on Fedora as well, we can get it merged in.

Thanks,
Ben


--
You received this message because you are subscribed to the Google Groups "garglk-dev" group.
To post to this group, send email to gargl...@googlegroups.com.
To unsubscribe from this group, send email to garglk-dev+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/garglk-dev?hl=en.


linker_gtk.diff

Carlo

unread,
Jan 17, 2011, 6:42:08 PM1/17/11
to garglk-dev
> Can you try the attached patch? It uses the pkgconfig mechanism instead, but
> it should be equivalent to yours.

This patch works for me. I had the same issue as Heiko and had
effectively been using his patch, but yours works too.

Carlo

Ben Cressey

unread,
Jan 17, 2011, 6:51:15 PM1/17/11
to carlo....@gmail.com, garglk-dev
This patch works for me. I had the same issue as Heiko and had
effectively been using his patch, but yours works too. 

Great, thanks! I've added the patch to trunk.

Regards,
Ben 
Reply all
Reply to author
Forward
0 new messages