GNOME Bugzilla – Bug 317828
Fails to build on Solaris 10 when X11 not explicitly linked
Last modified: 2005-10-24 02:51:59 UTC
Version details: 2.12.0 Distribution/Version: s10 x86 On Solaris 10 I am getting an 'undefined symbol XKeysymToKeycode' linker error in the 'shell' directory. Attached patch adds '-lX11' to eog_LDADD to get it to build.
Created attachment 52978 [details] [review] Add '-lX11' to eog/shell/Makefile.am for Solaris.
See bug #309306 to check if this solves your problem. You need to use --enable-indirect-deps configure option to make pkg-config use indirect dependencies.
Created attachment 53687 [details] [review] replace [ ] by test in configure.in ld line doesn't include '-lX11' because of bad test in configure.in: In configure.in, you can read: " dnl ****************************************************** dnl X development libraries check dnl ****************************************************** if [ `$PKG_CONFIG --variable=target gtk+-2.0` = x11 ] ; then # # If Pango included the shared library dependencies from X11 in # the pkg-config output, then we use that (to avoid duplicates). # but if they were omitted to avoid binary compatibility problems # then we need to repeat the checks. " BUT, squared brackets are "lost" in configure. Then, configure runs if `$PKG_CONFIG --variable=target gtk+-2.0` = x11 ; then which equals if x11 = x11 ; then which produces x11 not found and '-lX11' is never added. My proposal is to replace brackets by "test" statement (see other tests): if test `$PKG_CONFIG --variable=target gtk+-2.0` = x11 ; then This works on every platform. (I tested it on AIX)
Applied in HEAD and gnome-2-12 branch, thanks!