GNOME Bugzilla – Bug 665784
build failure: glade-main.o: undefined reference to symbol 'g_module_supported'
Last modified: 2016-05-22 12:01:46 UTC
I am building glade git master via JHBuild on Fedora 16. Build fails with details below. This is how gtk+ fixed a similar failure: http://git.gnome.org/browse/gtk+/commit/?h=gtk-2-24&id=26b749440bb61c59f79d8be93ddf7bc529085c3e /usr/bin/ld: glade-main.o: undefined reference to symbol 'g_module_supported' /usr/bin/ld: note: 'g_module_supported' is defined in DSO /opt/gnome/lib64/libgmodule-2.0.so.0 so try adding it to the linker command line /opt/gnome/lib64/libgmodule-2.0.so.0: could not read symbols: Invalid operation collect2: ld returned 1 exit status make[2]: *** [glade] Error 1 make[2]: Leaving directory `/home/oxyde/gnome/glade/src' make[1]: Leaving directory `/home/oxyde/gnome/glade' make[1]: *** [all-recursive] Error 1 make: *** [all] Error 2
Created attachment 204023 [details] [review] build: Explicitly link to gmodule-2.0
A similar patch is also needed for the 3.8.x branch.
Review of attachment 204023 [details] [review]: Thanks for the patch, please commit this and leave the bug open (we'll port it back to 3.8 before closing).
Comment on attachment 204023 [details] [review] build: Explicitly link to gmodule-2.0 Pushed.
backported to 3.8 branch
Review of attachment 204023 [details] [review]: seemingly there was a problem with backporting: in file configure.ac , add "gmodule-2.0" must currently done manually, since it is missing from the source in glade3-3.8.1 and the Arch package. ------ https://aur.archlinux.org/packages/glade-gtk2/?comments=all g99 commented on 2016-05-22 FIX for https://bugzilla.gnome.org/show_bug.cgi?id=665784 in file configure.ac : add gmodule-2.0 so section looks like: dnl ================================================================ dnl Check for gtk+ dnl ================================================================ PKG_CHECK_MODULES(GTK, [gtk+-2.0 >= 2.24 gthread-2.0 gmodule-2.0 libxml-2.0 >= 2.4.0]) AC_SUBST(GTK_LIBS) AC_SUBST(GTK_CFLAGS) added explicit linking to gmodule-2.0 With that the package glade-gtk2 ( here: glade3-3.8.1 ) builds nicely if you run: make clean mv ./configure ./configure-broken make configure ./configure make sudo make install ## you are done! vr # to run visual ruby employing the glade-3 binary g99 commented on 2016-05-22 10:55 Edit comment The fix by leha200 to add "-lgmodule-2.0" compiler option after configure in src/glade3-3.8.1/Makefile and to add to LIBS variable: $(GNOME_LIBS) does not work currently. The package is broken. Still same problem as 2012: ld: glade_3-main.o: undefined reference to symbol 'g_module_supported'