summaryrefslogtreecommitdiff
path: root/devel/gettext-lib
diff options
context:
space:
mode:
authorgrant <grant>2004-10-04 10:42:39 +0000
committergrant <grant>2004-10-04 10:42:39 +0000
commitc717f7c9213c59e05041132b6efd1b3b89ac2961 (patch)
treee66fd6ab3c5f12abf713521ae7eba976985aba7f /devel/gettext-lib
parentd3ff7ab11e3b1ee91ebfc80b02253ca3580d6f51 (diff)
downloadpkgsrc-c717f7c9213c59e05041132b6efd1b3b89ac2961.tar.gz
older versions of GNU gettext do not provide ngettext() and a bunch
of other functions. only consider the base system's gettext suitable if it provides at least ngettext().
Diffstat (limited to 'devel/gettext-lib')
-rw-r--r--devel/gettext-lib/builtin.mk20
1 files changed, 15 insertions, 5 deletions
diff --git a/devel/gettext-lib/builtin.mk b/devel/gettext-lib/builtin.mk
index 7512a4ea00c..6781a550d7e 100644
--- a/devel/gettext-lib/builtin.mk
+++ b/devel/gettext-lib/builtin.mk
@@ -1,4 +1,4 @@
-# $NetBSD: builtin.mk,v 1.9 2004/10/03 22:37:16 heinz Exp $
+# $NetBSD: builtin.mk,v 1.10 2004/10/04 10:42:39 grant Exp $
.if !defined(_BLNK_LIBINTL_FOUND)
_BLNK_LIBINTL_FOUND!= \
@@ -66,12 +66,22 @@ USE_BUILTIN.gettext!= \
. endif
. if ${PREFER.gettext} == "native"
-# XXX
-# XXX By default, assume that the native gettext implementation is good
-# XXX enough.
-# XXX
+#
+# By default, assume that the native gettext implementation is good
+# enough if it has a prototype for ngettext().
+#
. if exists(${_LIBINTL_H})
+_GETTEXT_NGETTEXT!= \
+ if ${GREP} -q ngettext ${_LIBINTL_H}; then \
+ echo yes; \
+ else \
+ echo no; \
+ fi
+. if !empty(_GETTEXT_NGETTEXT:Myes)
USE_BUILTIN.gettext= yes
+. else
+USE_BUILTIN.gettext= no
+. endif
#
# The listed platforms have an implementation of gettext that isn't
# GNUish enough.