Subject: pkg/23369: various gnome packages build fails due to -lintl
To: None <gnats-bugs@gnats.netbsd.org>
From: None <reed@reedmedia.net>
List: netbsd-bugs
Date: 11/04/2003 08:54:57
>Number:         23369
>Category:       pkg
>Synopsis:       various gnome packages build fails due to -lintl
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Nov 04 16:55:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     
>Release:        NetBSD 1.6.1_STABLE
>Organization:
http://bsd.reedmedia.net/
>Environment:
	
	
>Description:
pkgsrc/x11/gnome-libs/patches/patch-aa
and x11/gnome-core/patches/patch-aa
and x11/controlcenter/patches/patch-ab
all hard-code:

+INTLLIBS="-lintl"

But some systems don't need libintl (because their libc includes it).

And it may fail like:

gcc -O2 -I/tmp/pkgsrc/x11/gnome-libs/work.antelope/.buildlink/include
-I/tmp/pkgsrc/x11/gnome-libs/work.antelope/.buildlink-x11/include -Wall
-Wunused -Wl,-R/usr/lib -Wl,-R/usr/X11R6/lib -o .libs/gnome-dump-metadata
-Wl,-R/usr/lib gnome-dump.o -Wl,-R/usr/lib -Wl,-R/usr/lib -Wl,-R/usr/lib
-L/tmp/pkgsrc/x11/gnome-libs/work.antelope/.buildlink/lib
-L/tmp/pkgsrc/x11/gnome-libs/work.antelope/.buildlink-x11/lib
./.libs/libgnome.so ../support/.libs/libgnomesupport.so /usr/lib/libesd.so
/usr/lib/libaudiofile.so /usr/lib/libdb2.so /usr/lib/libglib.so -lintl
/usr/lib/libz.so -lm -Wl,--rpath -Wl,/usr/X11R6/lib
/usr/bin/ld: cannot find -lintl
collect2: ld returned 1 exit status
make[2]: *** [gnome-dump-metadata] Error 1
make[2]: Leaving directory
`/tmp/pkgsrc/x11/gnome-libs/work.antelope/gnome-libs-1.4.2/libgnome'

This breaks gnome-libs, gnome-core (and packages that use the same
PATCHDIR like x11/gnome1-session), and controlcenter

>How-To-Repeat:
Try to build gnome-libs, gnome-core (and packages that use the same
PATCHDIR like x11/gnome1-session), and controlcenter
on a system without and libintl library.
>Fix:
There is a new setting called ICONV_IS_GNU for libiconv.  Maybe
the same idea could be used where devel/gettext-lib/buildlink2.mk
can set a variable saying if it is used or not (like
USING_GETTEXT_LIB).

Or maybe those patches can reference some variable defined in
devel/gettext-lib/buildlink2.mk. Maybe something based on
_BLNK_INTL_LDFLAGS setting.

(My workaround was to just set INTLLIBS= to nothing. But that is
not a fix.)

This issue was reported to gnome-libs maintainer and to tech-pkg.
I am submitting this PR so it will not be forgotten about.
>Release-Note:
>Audit-Trail:
>Unformatted: