pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/devel/gettext-lib gettext-lib: Always add -lintl on Su...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/5389b223898e
branches:  trunk
changeset: 396728:5389b223898e
user:      jperkin <jperkin%pkgsrc.org@localhost>
date:      Sat Jun 08 09:34:29 2019 +0000

description:
gettext-lib: Always add -lintl on SunOS.

This effectively turns on BROKEN_GETTEXT_DETECTION=yes on SunOS and adds
-lintl whenever a package pulls in gettext-lib.  The SunOS linker is
more strict than others and will ensure that library dependencies are
explicit.  Recent changes to gettext-lib and glib made the dependency
implicit and caused a lot of fallout.

Use BUILDLINK_LDFLAGS instead of BUILDLINK_LIBS so that it actually gets
added through buildlink, not only when packages honour ${LIBS}.

diffstat:

 devel/gettext-lib/buildlink3.mk |  9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diffs (25 lines):

diff -r 37ef16192e46 -r 5389b223898e devel/gettext-lib/buildlink3.mk
--- a/devel/gettext-lib/buildlink3.mk   Sat Jun 08 09:31:33 2019 +0000
+++ b/devel/gettext-lib/buildlink3.mk   Sat Jun 08 09:34:29 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink3.mk,v 1.37 2014/01/04 11:14:37 richard Exp $
+# $NetBSD: buildlink3.mk,v 1.38 2019/06/08 09:34:29 jperkin Exp $
 
 BUILDLINK_TREE+=       gettext
 
@@ -19,11 +19,12 @@
 # "-lintl" to the linker command line.
 #
 # If BROKEN_GETTEXT_DETECTION is "yes", then automatically add "-lintl"
-# to LIBS to workaround this brokenness.
+# to LIBS to workaround this brokenness.  This is also the default on SunOS
+# due to stricter linker requirements for implicit libraries.
 #
 BROKEN_GETTEXT_DETECTION?=     no
-.if !empty(BROKEN_GETTEXT_DETECTION:M[yY][eE][sS])
-BUILDLINK_LIBS.gettext+=       ${BUILDLINK_LDADD.gettext}
+.if !empty(BROKEN_GETTEXT_DETECTION:M[yY][eE][sS]) || ${OPSYS} == "SunOS"
+BUILDLINK_LDFLAGS.gettext+=    ${BUILDLINK_LDADD.gettext}
 CONFIGURE_ENV+=                        INTLLIBS="${BUILDLINK_LDADD.gettext}"
 .endif
 



Home | Main Index | Thread Index | Old Index