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 80577 - Missing -lintl
Missing -lintl
Status: RESOLVED FIXED
Product: gnome-print
Classification: Deprecated
Component: general
unspecified
Other opensolaris
: Normal major
: ---
Assigned To: Chema Celorio
Chema Celorio
Depends on:
Blocks:
 
 
Reported: 2002-05-02 17:24 UTC by Morten Welinder
Modified: 2009-08-21 03:21 UTC
See Also:
GNOME target: ---
GNOME version: 2.0



Description Morten Welinder 2002-05-02 17:24:04 UTC
Since you now use bind_textdomain_codeset, you must link in -lintl.
This blocks all non-glibc platforms.

gcc -O2 -g -Wall -I/home/welinder/gnome/include -o .libs/testprint
testprint.o  -L/home/welinder/gnome/lib -L/usr/local/lib
../libgnomeprintui/.libs/libgnomeprintui-2.so -L/usr/ucblib
-L/usr/local/products/freetype/2.0.2/lib
/home/welinder/gnome/lib/libgnomeprint-2.so
/usr/local/products/freetype/2.0.2/lib/libfreetype.so
/home/welinder/gnome/lib/libbonobo-2.so
/home/welinder/gnome/lib/libORBitCosNaming-2.so
/home/welinder/gnome/lib/libbonobo-activation.so
/home/welinder/gnome/lib/libORBit-2.so /home/welinder/gnome/lib/liblinc.so
-lresolv /home/welinder/gnome/lib/libgthread-2.0.so -lthread
/home/welinder/gnome/lib/libxml2.so -lz -lsocket -lnsl
/home/welinder/gnome/lib/libgnomecanvas-2.so
/home/welinder/gnome/lib/libart_lgpl_2.so
/home/welinder/gnome/lib/libpangoft2-1.0.so
/home/welinder/gnome/lib/libgtk-x11-2.0.so
/home/welinder/gnome/lib/libgdk-x11-2.0.so
/home/welinder/gnome/lib/libgdk_pixbuf-2.0.so -lm
/home/welinder/gnome/lib/libpangox-1.0.so
/home/welinder/gnome/lib/libpango-1.0.so
/home/welinder/gnome/lib/libatk-1.0.so
/home/welinder/gnome/lib/libgobject-2.0.so
/home/welinder/gnome/lib/libgmodule-2.0.so
/home/welinder/gnome/lib/libglib-2.0.so
/home/welinder/gnome/lib/libiconv.so /home/welinder/gnome/lib/libpopt.so
-R/home/welinder/gnome/lib -R/usr/local/products/freetype/2.0.2/lib
/usr/local/gnu/install/gcc/2.9.5.2/bin/gnu-ld: warning: libdga.so.1, needed
by /lib/libXext.so.0, not found (try using --rpath)
../libgnomeprintui/.libs/libgnomeprintui-2.so: undefined reference to
`bind_textdomain_codeset'
Comment 1 Damon Chaplin 2002-05-08 17:05:35 UTC
GTK+ has this in configure.in:

dnl
dnl Check for bind_textdomain_codeset, including -lintl if GLib brings
it in.
dnl
gtk_save_LIBS=$LIBS
LIBS="$LIBS $GLIB_LIBS"
AC_CHECK_FUNCS(bind_textdomain_codeset)
LIBS=$gtk_save_LIBS

then in main.c:

#ifdef HAVE_BIND_TEXTDOMAIN_CODESET
#include <libintl.h>
#endif

...

#ifdef ENABLE_NLS
  bindtextdomain (GETTEXT_PACKAGE, GTK_LOCALEDIR);
#    ifdef HAVE_BIND_TEXTDOMAIN_CODESET
  bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
#    endif
#endif  

Should we be doing something similar?
Comment 2 Luis Villa 2002-05-14 17:11:17 UTC
See also bug 70627. I'm going to mark this down from high priority,
because one can work around this in the build process by adding your
own CFLAGS, and both sun and ximian do in their builds. Yes, it should
work, and we should take a patch for it, but I can't see this as being
a big deal for the community as a whole. Please feel free to disagree :)
Comment 3 Chema Celorio 2002-06-01 15:35:05 UTC
Gmorten:

Can you provide me with a patch that contains the "right" fix please?
I'd like to get this bug out of the way.
Comment 4 Morten Welinder 2002-06-03 13:15:24 UTC
The right thing would be for owen to fix glib.

The second best thing is something like this in configure.in:

dnl FIXME: Does this really belong here?
AC_CHECK_FUNC(bind_textdomain_codeset,,[AC_CHECK_LIB(intl,bind_textdomain_codeset)])
Comment 5 Chema Celorio 2002-12-03 20:07:03 UTC
Fixed in cvs as per the "second best thing"
Comment 6 Chema Celorio 2002-12-03 20:07:15 UTC
Fixed in cvs as per the "second best thing"
Comment 7 Max Kanat-Alexander 2009-08-21 03:21:31 UTC
This bug was marked RESOLVED without a resolution, which Bugzilla does not allow (and so I am fixing it). It is assumed that the bug was intended to be marked as FIXED. If the bug should have some other resolution, please change its resolution.