pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/mk/tools Move the gettext tools handling to mk/tools/g...
details: https://anonhg.NetBSD.org/pkgsrc/rev/68d8b47b3b09
branches: trunk
changeset: 511380:68d8b47b3b09
user: jlam <jlam%pkgsrc.org@localhost>
date: Thu Apr 13 19:24:29 2006 +0000
description:
Move the gettext tools handling to mk/tools/gettext.mk. We ensure
that we use the pkgsrc versions of xgettext and gettext if we're also
using the pkgsrc version of msgfmt.
diffstat:
mk/tools/gettext.mk | 41 +++++++++++++++++++++++++++++++++++++++--
mk/tools/replace.mk | 24 +-----------------------
2 files changed, 40 insertions(+), 25 deletions(-)
diffs (104 lines):
diff -r a18361a54183 -r 68d8b47b3b09 mk/tools/gettext.mk
--- a/mk/tools/gettext.mk Thu Apr 13 19:17:02 2006 +0000
+++ b/mk/tools/gettext.mk Thu Apr 13 19:24:29 2006 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: gettext.mk,v 1.1 2006/04/13 18:45:01 jlam Exp $
+# $NetBSD: gettext.mk,v 1.2 2006/04/13 19:24:29 jlam Exp $
#
# Copyright (c) 2006 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -35,6 +35,23 @@
# POSSIBILITY OF SUCH DAMAGE.
#
+# These tools are all supplied by the devel/gettext-tools package if there
+# is no native tool available. Don't add "msgfmt" to this list as it's
+# treated specially below.
+#
+_TOOLS.gettext-tools= gettext xgettext
+_TOOLS_DEP.gettext-tools= {gettext>=0.10.36,gettext-tools>=0.14.5}
+
+.for _t_ in ${_TOOLS.gettext-tools}
+. if !defined(TOOLS_IGNORE.${_t_}) && !empty(USE_TOOLS:C/:.*//:M${_t_})
+USE_TOOLS+= msgfmt
+. endif
+.endfor
+
+###
+### Handle "msgfmt". We use either the pkgsrc version or the built-in
+### version of msgfmt depending on availability and version.
+###
.if !defined(TOOLS_IGNORE.msgfmt) && !empty(USE_TOOLS:C/:.*//:Mmsgfmt)
. if !empty(PKGPATH:Mdevel/gettext-tools)
MAKEFLAGS+= TOOLS_IGNORE.msgfmt=
@@ -72,7 +89,7 @@
. if !empty(_TOOLS_USE_PKGSRC.msgfmt:M[yY][eE][sS])
TOOLS_CREATE+= msgfmt
-TOOLS_DEPENDS.msgfmt?= {gettext>=0.10.36,gettext-tools>=0.14.5}:../../devel/gettext-tools
+TOOLS_DEPENDS.msgfmt?= ${_TOOLS_DEP.gettext-tools}:../../devel/gettext-tools
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.msgfmt=${TOOLS_DEPENDS.msgfmt:C/:.*//}
TOOLS_PATH.msgfmt= ${TOOLS_PREFIX.msgfmt}/bin/msgfmt
. else
@@ -84,3 +101,23 @@
. endif
. endif
.endif
+
+.for _t_ in ${_TOOLS.gettext-tools}
+. if !defined(TOOLS_IGNORE.${_t_}) && !empty(USE_TOOLS:C/:.*//:M${_t_})
+. if !empty(_TOOLS_USE_PKGSRC.msgfmt:M[yY][eE][sS])
+_TOOLS_USE_PKGSRC.${_t_}= yes
+. elif defined(TOOLS_PLATFORM.msgfmt) && !empty(TOOLS_PLATFORM.msgfmt)
+_TOOLS_USE_PKGSRC.${_t_}?= no
+. else
+_TOOLS_USE_PKGSRC.${_t_}?= yes
+. endif
+. if !empty(PKGPATH:Mdevel/gettext-tools)
+MAKEFLAGS+= TOOLS_IGNORE.${_t_}=
+. elif !empty(_TOOLS_USE_PKGSRC.${_t_}:M[yY][eE][sS])
+TOOLS_DEPENDS.${_t_}?= ${_TOOLS_DEP.gettext-tools}:../../devel/gettext-tools
+TOOLS_CREATE+= ${_t_}
+TOOLS_FIND_PREFIX+= TOOLS_PREFIX.${_t_}=${TOOLS_DEPENDS.${_t_}:C/:.*//}
+TOOLS_PATH.${_t_}= ${TOOLS_PREFIX.${_t_}}/bin/${_t_}
+. endif
+. endif
+.endfor
diff -r a18361a54183 -r 68d8b47b3b09 mk/tools/replace.mk
--- a/mk/tools/replace.mk Thu Apr 13 19:17:02 2006 +0000
+++ b/mk/tools/replace.mk Thu Apr 13 19:24:29 2006 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: replace.mk,v 1.165 2006/04/13 16:35:58 jlam Exp $
+# $NetBSD: replace.mk,v 1.166 2006/04/13 19:24:29 jlam Exp $
#
# Copyright (c) 2005 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -877,28 +877,6 @@
######################################################################
-# These tools are all supplied by the devel/gettext-tools package if there
-# is no native tool available. Don't add "msgfmt" to this list since it
-# needs special handling -- see mk/tools/msgfmt.mk.
-#
-_TOOLS.gettext-tools= gettext xgettext
-_TOOLS_DEP.gettext-tools= {gettext>0.10.35,gettext-tools>=0.14.5}
-
-.for _t_ in ${_TOOLS.gettext-tools}
-. if !defined(TOOLS_IGNORE.${_t_}) && !empty(_USE_TOOLS:M${_t_})
-. if !empty(PKGPATH:Mdevel/gettext-tools)
-MAKEFLAGS+= TOOLS_IGNORE.${_t_}=
-. elif !empty(_TOOLS_USE_PKGSRC.${_t_}:M[yY][eE][sS])
-TOOLS_DEPENDS.${_t_}?= ${_TOOLS_DEP.gettext-tools}:../../devel/gettext-tools
-TOOLS_CREATE+= ${_t_}
-TOOLS_FIND_PREFIX+= TOOLS_PREFIX.${_t_}=${TOOLS_DEPENDS.${_t_}:C/:.*//}
-TOOLS_PATH.${_t_}= ${TOOLS_PREFIX.${_t_}}/bin/${_t_}
-. endif
-. endif
-.endfor
-
-######################################################################
-
# These tools are all supplied by a Ghostscript package if there is no
# native tool available.
#
Home |
Main Index |
Thread Index |
Old Index