After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 608217 - Missing link against libgthread
Missing link against libgthread
Status: RESOLVED FIXED
Product: gnome-settings-daemon
Classification: Core
Component: general
unspecified
Other Mac OS
: Normal normal
: ---
Assigned To: gnome-settings-daemon-maint
gnome-settings-daemon-maint
Depends on:
Blocks:
 
 
Reported: 2010-01-27 02:25 UTC by Daniel Macks
Modified: 2010-01-27 19:21 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Daniel Macks 2010-01-27 02:25:20 UTC
A Fink user reported the following build failure:

attempting to rebuild gnome-settings-daemon 2.26.1 (system 10.6.2, x86_64) gets me:

gcc -Os -pipe -o gnome-settings-daemon gnome_settings_daemon-main.o gnome_settings_daemon-gnome-settings-manager.o gnome_settings_daemon-gnome-settings-plugin.o gnome_settings_daemon-gnome-settings-plugin-info.o gnome_settings_daemon-gnome-settings-module.o -Wl,-framework -Wl,CoreServices -Wl,-framework -Wl,ApplicationServices  -L/sw/lib/fontconfig2/lib -L/sw/lib ./.libs/libgsd-profile.a /sw/lib/libgtk-x11-2.0.dylib /sw/lib/libgdk-x11-2.0.dylib /sw/lib/libatk-1.0.dylib /sw/lib/libgio-2.0.dylib /sw/lib/pango-ft219/lib/libpangoft2-1.0.dylib /sw/lib/libgdk_pixbuf-2.0.dylib /sw/lib/pango-ft219/lib/libpangocairo-1.0.dylib /sw/lib/libcairo.dylib /sw/lib/pango-ft219/lib/libpango-1.0.dylib /sw/lib/freetype219/lib/libfreetype.dylib -lz /sw/lib/fontconfig2/lib/libfontconfig.dylib /sw/lib/libgconf-2.dylib /sw/lib/libgmodule-2.0.dylib /sw/lib/libdbus-glib-1.dylib /sw/lib/libdbus-1.dylib -lpthread /sw/lib/libgobject-2.0.dylib /sw/lib/libglib-2.0.dylib /sw/lib/libintl.dylib  
Undefined symbols:
  "_g_thread_init", referenced from:
      _main in gnome_settings_daemon-main.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[3]: *** [gnome-settings-daemon] Error 1
make[2]: *** [all] Error 2
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
### execution of make failed, exit code 2


and this situation appears to be the same in git trunk. gnome-settings-daemon/main.c calls g_thread_init() but autoconf doesn't test for or propagate the gthread lib that supplies that symbol. The deficient test is configure.ac in PKG_CHECK_MODULES(SETTINGS_DAEMON,...easy solution is to add gthread-2.0 to the list of packages there. Could either reuse $GLIB_REQUIRED_VERSION or else have a separate $GTHREAD_REQUIRED_VERSION variable. This has probably worked in the past because other libs leak(ed) an -lgthread-2.0 flag in the .la file of some dependent lib, but several vendors seem to be no longer shipping .la files. Alternately, on linux, it probably was okay because some dependent lib had a dyld link against libthread, but on darwin, indirect symbol refs are prohibited...must directly link everything that is used directly.
Comment 1 Jens Granseuer 2010-01-27 19:21:05 UTC
commit e0921d7fedf411402b15b3b5d29b4e2323ff8927
Author: Jens Granseuer <...>
Date:   Wed Jan 27 20:20:26 2010 +0100

    Add gthread-2.0 to required modules for the daemon
    
    Closes bug #608217.