2005-07-15 20:27:48 +02:00
|
|
|
# $NetBSD: replace.mk,v 1.108 2005/07/15 18:27:55 jlam Exp $
|
2005-05-21 06:46:52 +02:00
|
|
|
#
|
|
|
|
# Copyright (c) 2005 The NetBSD Foundation, Inc.
|
|
|
|
# All rights reserved.
|
|
|
|
#
|
|
|
|
# This code is derived from software contributed to The NetBSD Foundation
|
2005-05-21 06:53:17 +02:00
|
|
|
# by Johnny C. Lam.
|
2005-05-21 06:46:52 +02:00
|
|
|
#
|
|
|
|
# Redistribution and use in source and binary forms, with or without
|
|
|
|
# modification, are permitted provided that the following conditions
|
|
|
|
# are met:
|
|
|
|
# 1. Redistributions of source code must retain the above copyright
|
|
|
|
# notice, this list of conditions and the following disclaimer.
|
|
|
|
# 2. Redistributions in binary form must reproduce the above copyright
|
|
|
|
# notice, this list of conditions and the following disclaimer in the
|
|
|
|
# documentation and/or other materials provided with the distribution.
|
|
|
|
# 3. All advertising materials mentioning features or use of this software
|
|
|
|
# must display the following acknowledgement:
|
|
|
|
# This product includes software developed by the NetBSD
|
|
|
|
# Foundation, Inc. and its contributors.
|
|
|
|
# 4. Neither the name of The NetBSD Foundation nor the names of its
|
|
|
|
# contributors may be used to endorse or promote products derived
|
|
|
|
# from this software without specific prior written permission.
|
|
|
|
#
|
|
|
|
# THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
|
|
|
|
# ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
|
|
|
# TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
|
|
|
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
|
|
|
|
# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
|
|
|
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
|
|
|
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
|
|
|
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
|
|
|
# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
|
|
|
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
|
|
|
# POSSIBILITY OF SUCH DAMAGE.
|
|
|
|
#
|
|
|
|
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
#
|
2005-04-24 05:07:36 +02:00
|
|
|
# This Makefile fragment handles "replacements" of system-supplied
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
# tools with pkgsrc versions.
|
|
|
|
#
|
|
|
|
# The replacement tools are placed under ${TOOLS_DIR} so that they
|
|
|
|
# appear earlier in the search path when invoked using the bare name
|
|
|
|
# of the tool.
|
|
|
|
#
|
|
|
|
# "TOOLS_TOOL" variables, e.g. TOOLS_AWK, TOOLS_SED, etc. are set to
|
|
|
|
# the full command lines necessary to invoke the real tools on the
|
|
|
|
# filesystem, and represent the tools required by the package.
|
|
|
|
#
|
|
|
|
# "TOOL" variables, e.g. AWK, SED, etc. are set to the full command
|
|
|
|
# lines necessary to invoke the real tools on the filesystem, and
|
|
|
|
# represent the tools required by pkgsrc itself.
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
#
|
|
|
|
# The tools that could be replaced with pkgsrc counterparts (usually
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
# GNU versions of the tools) that are required by pkgsrc itself, i.e.
|
|
|
|
# in targets that are part of pkgsrc infrastructure or part of the
|
2005-07-15 20:27:48 +02:00
|
|
|
# package Makefile, or by the package itself, i.e. within the
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
# software's own build system, should be listed as:
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
#
|
2005-07-15 20:27:48 +02:00
|
|
|
# USE_TOOLS+= awk gmake lex sed
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
#
|
|
|
|
# If a package requires yacc to generate a parser, then the package
|
|
|
|
# Makefile should contain one of the following two lines:
|
|
|
|
#
|
|
|
|
# USE_TOOLS+= yacc # any yacc will do
|
|
|
|
# USE_TOOLS+= bison # requires bison-specific features
|
|
|
|
#
|
|
|
|
# Adding either "yacc" or "bison" to USE_TOOLS will cause a "yacc" tool
|
|
|
|
# to be generated that may be used as a yacc-replacement.
|
|
|
|
#
|
2005-04-15 08:52:25 +02:00
|
|
|
# By default, any dependencies on the pkgsrc tools are build dependencies,
|
2005-04-28 04:10:56 +02:00
|
|
|
# but this may be changed by explicitly setting TOOLS_DEPMETHOD.<tool>,
|
2005-04-15 08:52:25 +02:00
|
|
|
# e.g.:
|
|
|
|
#
|
2005-04-28 04:10:56 +02:00
|
|
|
# TOOLS_DEPMETHOD.tbl= DEPENDS
|
2005-04-15 08:52:25 +02:00
|
|
|
#
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
|
2005-05-22 23:04:41 +02:00
|
|
|
# Continue to allow USE_PERL5 until packages have been taught to use the
|
|
|
|
# new syntax.
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
#
|
2005-05-19 05:52:23 +02:00
|
|
|
.if defined(USE_PERL5)
|
|
|
|
USE_TOOLS+= perl
|
|
|
|
. if empty(USE_PERL5:Mbuild)
|
|
|
|
TOOLS_DEPMETHOD.perl?= DEPENDS
|
|
|
|
. endif
|
|
|
|
.endif
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
|
2005-05-19 22:08:44 +02:00
|
|
|
# XXX Keep this hack here until the day that msgfmt and msgfmt-plurals
|
|
|
|
# XXX is handled directly by the tools framework.
|
|
|
|
# XXX
|
|
|
|
.if defined(USE_MSGFMT_PLURALS) && !empty(USE_MSGFMT_PLURALS:M[yY][eE][sS])
|
|
|
|
USE_TOOLS+= perl
|
|
|
|
.endif
|
|
|
|
|
2005-05-16 01:20:38 +02:00
|
|
|
# bison implies "bison-yacc"
|
|
|
|
.if !empty(USE_TOOLS:Mbison)
|
|
|
|
USE_TOOLS+= bison-yacc
|
|
|
|
.endif
|
|
|
|
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
######################################################################
|
|
|
|
|
2005-07-15 20:27:48 +02:00
|
|
|
# Create _USE_TOOLS, a sanitized version of USE_TOOLS that removes the
|
|
|
|
# ones that are overridden by superseding ones.
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
#
|
|
|
|
.if !defined(_USE_TOOLS)
|
2005-07-15 20:27:48 +02:00
|
|
|
_USE_TOOLS:= ${USE_TOOLS:O:u}
|
2005-05-16 01:20:38 +02:00
|
|
|
. if !empty(USE_TOOLS:Mbison-yacc) # bison-yacc > yacc
|
2005-04-28 17:47:43 +02:00
|
|
|
_USE_TOOLS:= ${_USE_TOOLS:Nyacc}
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
. endif
|
2005-05-23 03:20:50 +02:00
|
|
|
. if !empty(USE_TOOLS:Mflex) # flex > lex
|
|
|
|
_USE_TOOLS:= ${_USE_TOOLS:Nlex}
|
|
|
|
. endif
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
. if !empty(USE_TOOLS:Mgawk) # gawk > awk
|
2005-04-28 17:47:43 +02:00
|
|
|
_USE_TOOLS:= ${_USE_TOOLS:Nawk}
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
. endif
|
|
|
|
. if !empty(USE_TOOLS:Mgm4) # gm4 > m4
|
2005-04-28 17:47:43 +02:00
|
|
|
_USE_TOOLS:= ${_USE_TOOLS:Nm4}
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
. endif
|
|
|
|
. if !empty(USE_TOOLS:Mgsed) # gsed > sed
|
2005-04-28 17:47:43 +02:00
|
|
|
_USE_TOOLS:= ${_USE_TOOLS:Nsed}
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
. endif
|
2005-04-28 17:47:43 +02:00
|
|
|
.endif
|
2005-05-12 00:08:18 +02:00
|
|
|
MAKEVARS+= _USE_TOOLS
|
2005-04-28 17:47:43 +02:00
|
|
|
|
|
|
|
######################################################################
|
|
|
|
|
2005-04-25 08:16:38 +02:00
|
|
|
# _TOOLS_USE_PKGSRC.<tool> is "yes" or "no" depending on whether we're
|
|
|
|
# using a pkgsrc-supplied tool to replace the system-supplied one. We
|
2005-04-27 18:52:28 +02:00
|
|
|
# use the system-supplied one if TOOLS_PLATFORM.<tool> is non-empty, or
|
2005-04-25 08:16:38 +02:00
|
|
|
# otherwise if this is a particular ${MACHINE_PLATFORM} listed above.
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
#
|
2005-04-28 17:51:10 +02:00
|
|
|
.for _t_ in ${_USE_TOOLS}
|
2005-04-27 18:52:28 +02:00
|
|
|
. if defined(TOOLS_PLATFORM.${_t_}) && !empty(TOOLS_PLATFORM.${_t_})
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
_TOOLS_USE_PKGSRC.${_t_}?= no
|
2005-04-27 18:02:08 +02:00
|
|
|
. endif
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
_TOOLS_USE_PKGSRC.${_t_}?= yes
|
|
|
|
.endfor
|
|
|
|
|
2005-04-28 04:10:56 +02:00
|
|
|
# TOOLS_DEPMETHOD.<tool> defaults to BUILD_DEPENDS.
|
2005-04-28 17:51:10 +02:00
|
|
|
.for _t_ in ${_USE_TOOLS}
|
2005-04-28 04:10:56 +02:00
|
|
|
TOOLS_DEPMETHOD.${_t_}?= BUILD_DEPENDS
|
2005-04-15 08:52:25 +02:00
|
|
|
.endfor
|
|
|
|
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
######################################################################
|
|
|
|
|
|
|
|
# For each of the blocks below, we create either symlinks or wrappers
|
|
|
|
# for each of the tools requested. We need to be careful that we don't
|
|
|
|
# get into dependency loops; do this by setting and checking the value
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
# of TOOLS_IGNORE.<tool>. These blocks handle the case where we are
|
|
|
|
# using the pkgsrc-supplied tool.
|
|
|
|
#
|
|
|
|
# Always set the "TOOLS_TOOL" name for each tool to point to the real
|
|
|
|
# command, e.g., TOOLS_TBL, TOOLS_YACC, etc., provided that "TOOL" has
|
|
|
|
# been associated with <tool>.
|
|
|
|
#
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.[) && !empty(_USE_TOOLS:M\[)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.[=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.[:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.[?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= [
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.[=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.[= ${TOOLS_PREFIX.[}/bin/${GNU_PROGRAM_PREFIX}[
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.awk) && !empty(_USE_TOOLS:Mawk)
|
2005-05-18 07:31:55 +02:00
|
|
|
. if !empty(PKGPATH:Mlang/nawk)
|
2005-04-27 18:28:19 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.awk=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.awk:M[yY][eE][sS])
|
2005-05-18 07:31:55 +02:00
|
|
|
TOOLS_DEPENDS.awk?= nawk>=20040207:../../lang/nawk
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= awk
|
2005-05-18 07:31:55 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.awk=nawk
|
|
|
|
TOOLS_REAL_CMD.awk= ${TOOLS_PREFIX.awk}/bin/nawk
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.awk}= ${TOOLS_REAL_CMD.awk}
|
2005-04-27 18:28:19 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.basename) && !empty(_USE_TOOLS:Mbasename)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.basename=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.basename:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.basename?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= basename
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.basename=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.basename= ${TOOLS_PREFIX.basename}/bin/${GNU_PROGRAM_PREFIX}basename
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.basename}= ${TOOLS_REAL_CMD.basename}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-06-24 21:39:10 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.bash) && !empty(_USE_TOOLS:Mbash)
|
|
|
|
. if !empty(PKGPATH:Mshells/bash)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.bash=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.bash:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.bash?= bash-[0-9]*:../../shells/bash
|
|
|
|
TOOLS_CREATE+= bash
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.bash=bash
|
|
|
|
TOOLS_REAL_CMD.bash= ${TOOLS_PREFIX.bash}/bin/bash
|
2005-06-24 23:17:01 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.bash}= ${TOOLS_REAL_CMD.bash}
|
2005-06-24 21:39:10 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-06-03 23:11:06 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.bdftopcf) && !empty(_USE_TOOLS:Mbdftopcf)
|
|
|
|
. if !empty(PKGPATH:Mx11/XFree86-clients) || !empty(PKGPATH:Mx11/xorg-clients)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.bdftopcf=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.bdftopcf:M[yY][eE][sS])
|
|
|
|
TOOLS_CREATE+= bdftopcf
|
|
|
|
. if defined(X11_TYPE) && !empty(X11_TYPE:MXFree86)
|
|
|
|
TOOLS_DEPENDS.bdftopcf?= XFree86-clients>=4.4.0:../../x11/XFree86-clients
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.bdftopcf=imake
|
|
|
|
TOOLS_REAL_CMD.bdftopcf= ${TOOLS_PREFIX.bdftopcf}/${X11ROOT_PREFIX}/bin/bdftopcf
|
|
|
|
. elif defined(X11_TYPE) && !empty(X11_TYPE:Mxorg)
|
|
|
|
TOOLS_DEPENDS.bdftopcf?= xorg-clients>=6.8:../../x11/xorg-clients
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.bdftopcf=xorg-clients
|
|
|
|
TOOLS_REAL_CMD.bdftopcf= ${TOOLS_PREFIX.bdftopcf}/${X11ROOT_PREFIX}/bin/bdftopcf
|
|
|
|
. else # !empty(X11_TYPE:Mnative)
|
|
|
|
TOOLS_REAL_CMD.bdftopcf= ${X11BASE}/bin/bdftopcf
|
|
|
|
. endif
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.bison) && !empty(_USE_TOOLS:Mbison)
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. if !empty(PKGPATH:Mdevel/bison)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.bison=
|
2005-04-24 05:07:36 +02:00
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.bison:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.bison?= bison>=1.0:../../devel/bison
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= bison
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.bison=bison
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.bison= ${TOOLS_PREFIX.bison}/bin/bison
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. endif
|
2005-05-16 01:20:38 +02:00
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.bison-yacc) && !empty(_USE_TOOLS:Mbison-yacc)
|
|
|
|
. if !empty(PKGPATH:Mdevel/bison)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.bison-yacc=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.bison-yacc:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.bison-yacc?= bison>=1.0:../../devel/bison
|
|
|
|
TOOLS_CREATE+= bison-yacc
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.bison-yacc=bison
|
|
|
|
TOOLS_REAL_CMD.bison-yacc= ${TOOLS_PREFIX.bison-yacc}/bin/bison
|
|
|
|
TOOLS_REAL_ARGS.bison-yacc= -y
|
|
|
|
TOOLS_${_TOOLS_VARNAME.bison-yacc}= \
|
|
|
|
${TOOLS_REAL_CMD.bison-yacc} ${TOOLS_REAL_ARGS.bison-yacc}
|
|
|
|
. endif
|
|
|
|
TOOLS_CMD.bison-yacc= ${TOOLS_DIR}/bin/yacc
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
.endif
|
|
|
|
|
2005-05-02 04:50:33 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.bzcat) && !empty(_USE_TOOLS:Mbzcat)
|
|
|
|
. if !empty(PKGPATH:Marchivers/bzip2)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.bzcat=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.bzcat:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.bzcat?= bzip2>=0.9.0b:../../archivers/bzip2
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= bzcat
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.bzcat=bzip2
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.bzcat= ${TOOLS_PREFIX.bzcat}/bin/bzcat
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.bzcat}= ${TOOLS_REAL_CMD.bzcat}
|
2005-05-02 04:50:33 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.cat) && !empty(_USE_TOOLS:Mcat)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.cat=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.cat:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.cat?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= cat
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.cat=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.cat= ${TOOLS_PREFIX.cat}/bin/${GNU_PROGRAM_PREFIX}cat
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.cat}= ${TOOLS_REAL_CMD.cat}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.chgrp) && !empty(_USE_TOOLS:Mchgrp)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.chgrp=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.chgrp:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.chgrp?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= chgrp
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.chgrp=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.chgrp= ${TOOLS_PREFIX.chgrp}/bin/${GNU_PROGRAM_PREFIX}chgrp
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.chgrp}= ${TOOLS_REAL_CMD.chgrp}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.chmod) && !empty(_USE_TOOLS:Mchmod)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.chmod=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.chmod:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.chmod?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= chmod
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.chmod=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.chmod= ${TOOLS_PREFIX.chmod}/bin/${GNU_PROGRAM_PREFIX}chmod
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.chmod}= ${TOOLS_REAL_CMD.chmod}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.chown) && !empty(_USE_TOOLS:Mchown)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.chown=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.chown:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.chown?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= chown
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.chown=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.chown= ${TOOLS_PREFIX.chown}/bin/${GNU_PROGRAM_PREFIX}chown
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.chown}= ${TOOLS_REAL_CMD.chown}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.cmp) && !empty(_USE_TOOLS:Mcmp)
|
2005-04-27 01:20:35 +02:00
|
|
|
. if !empty(PKGPATH:Mdevel/diffutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.cmp=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.cmp:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.cmp?= diffutils>=2.8.1:../../devel/diffutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= cmp
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.cmp=diffutils
|
2005-06-23 22:35:55 +02:00
|
|
|
TOOLS_REAL_CMD.cmp= ${TOOLS_PREFIX.cmp}/bin/${GNU_PROGRAM_PREFIX}cmp
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.cmp}= ${TOOLS_REAL_CMD.cmp}
|
2005-04-27 01:20:35 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.cp) && !empty(_USE_TOOLS:Mcp)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.cp=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.cp:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.cp?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= cp
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.cp=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.cp= ${TOOLS_PREFIX.cp}/bin/${GNU_PROGRAM_PREFIX}cp
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.cp}= ${TOOLS_REAL_CMD.cp}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-06-24 22:59:59 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.csh) && !empty(_USE_TOOLS:Mcsh)
|
|
|
|
. if !empty(PKGPATH:Mshells/tcsh)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.csh=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.csh:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.csh?= tcsh-[0-9]*:../../shells/tcsh
|
|
|
|
TOOLS_CREATE+= csh
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.csh=tcsh
|
|
|
|
TOOLS_REAL_CMD.csh= ${TOOLS_PREFIX.csh}/bin/tcsh
|
2005-06-24 23:21:31 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.csh}= ${TOOLS_REAL_CMD.csh}
|
2005-06-24 22:59:59 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.cut) && !empty(_USE_TOOLS:Mcut)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.cut=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.cut:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.cut?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= cut
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.cut=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.cut= ${TOOLS_PREFIX.cut}/bin/${GNU_PROGRAM_PREFIX}cut
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.cut}= ${TOOLS_REAL_CMD.cut}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.date) && !empty(_USE_TOOLS:Mdate)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.date=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.date:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.date?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= date
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.date=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.date= ${TOOLS_PREFIX.date}/bin/${GNU_PROGRAM_PREFIX}date
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.date}= ${TOOLS_REAL_CMD.date}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-06-23 22:39:39 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.diff) && !empty(_USE_TOOLS:Mdiff)
|
|
|
|
. if !empty(PKGPATH:Mdevel/diffutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.diff=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.diff:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.diff?= diffutils>=2.8.1:../../devel/diffutils
|
|
|
|
TOOLS_CREATE+= diff
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.diff=diffutils
|
|
|
|
TOOLS_REAL_CMD.diff= ${TOOLS_PREFIX.diff}/bin/${GNU_PROGRAM_PREFIX}diff
|
|
|
|
TOOLS_${_TOOLS_VARNAME.diff}= ${TOOLS_REAL_CMD.diff}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.dirname) && !empty(_USE_TOOLS:Mdirname)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.dirname=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.dirname:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.dirname?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= dirname
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.dirname=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.dirname= ${TOOLS_PREFIX.dirname}/bin/${GNU_PROGRAM_PREFIX}dirname
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.dirname}= ${TOOLS_REAL_CMD.dirname}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.echo) && !empty(_USE_TOOLS:Mecho)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.echo=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.echo:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.echo?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= echo
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.echo=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.echo= ${TOOLS_PREFIX.echo}/bin/${GNU_PROGRAM_PREFIX}echo
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.echo}= ${TOOLS_REAL_CMD.echo}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.egrep) && !empty(_USE_TOOLS:Megrep)
|
2005-04-26 21:15:38 +02:00
|
|
|
. if !empty(PKGPATH:Mtextproc/grep)
|
2005-04-28 05:57:39 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.egrep=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.egrep:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.egrep?= grep>=2.5.1:../../textproc/grep
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= egrep
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.egrep=grep
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.egrep= ${TOOLS_PREFIX.egrep}/bin/${GNU_PROGRAM_PREFIX}egrep
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.egrep}= ${TOOLS_REAL_CMD.egrep}
|
2005-04-28 05:57:39 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.env) && !empty(_USE_TOOLS:Menv)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.env=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.env:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.env?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= env
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.env=coreutilsj
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.env= ${TOOLS_PREFIX.env}/bin/${GNU_PROGRAM_PREFIX}env
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.env}= ${TOOLS_REAL_CMD.env}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.expr) && !empty(_USE_TOOLS:Mexpr)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.expr=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.expr:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.expr?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= expr
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.expr=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.expr= ${TOOLS_PREFIX.expr}/bin/${GNU_PROGRAM_PREFIX}expr
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.expr}= ${TOOLS_REAL_CMD.expr}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.false) && !empty(_USE_TOOLS:Mfalse)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.false=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.false:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.false?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= false
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.false=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.false= ${TOOLS_PREFIX.false}/bin/${GNU_PROGRAM_PREFIX}false
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.false}= ${TOOLS_REAL_CMD.false}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.fgrep) && !empty(_USE_TOOLS:Mfgrep)
|
2005-04-28 05:57:39 +02:00
|
|
|
. if !empty(PKGPATH:Mtextproc/grep)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.fgrep=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.fgrep:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.fgrep?= grep>=2.5.1:../../textproc/grep
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= fgrep
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.fgrep=grep
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.fgrep= ${TOOLS_PREFIX.fgrep}/bin/${GNU_PROGRAM_PREFIX}fgrep
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.fgrep}= ${TOOLS_REAL_CMD.fgrep}
|
2005-04-26 21:15:38 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.file) && !empty(_USE_TOOLS:Mfile)
|
2005-04-15 18:01:23 +02:00
|
|
|
. if !empty(PKGPATH:Msysutils/file)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.file=
|
2005-04-24 05:07:36 +02:00
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.file:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.file?= file>=4.13:../../sysutils/file
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= file
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.file=file
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.file= ${TOOLS_PREFIX.file}/bin/file
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.file}= ${TOOLS_REAL_CMD.file}
|
2005-04-15 18:01:23 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.find) && !empty(_USE_TOOLS:Mfind)
|
2005-04-27 00:28:03 +02:00
|
|
|
. if !empty(PKGPATH:Msysutils/findutils)
|
2005-04-28 05:57:39 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.find=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.find:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.find?= findutils>=4.1:../../sysutils/findutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= find
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.find=findutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.find= ${TOOLS_PREFIX.find}/bin/${GNU_PROGRAM_PREFIX}find
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.find}= ${TOOLS_REAL_CMD.find}
|
2005-04-27 00:28:03 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-23 03:20:50 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.flex) && !empty(_USE_TOOLS:Mflex)
|
|
|
|
. if !empty(PKGPATH:Mdevel/flex)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.flex=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.flex:M[yY][eE][sS])
|
|
|
|
. include "../../devel/flex/buildlink3.mk"
|
|
|
|
_TOOLS_DEPENDS.flex= # empty
|
|
|
|
. for _dep_ in ${BUILDLINK_DEPENDS.flex}
|
|
|
|
_TOOLS_DEPENDS.flex+= ${_dep_}:${BUILDLINK_PKGSRCDIR.flex}
|
|
|
|
. endfor
|
|
|
|
TOOLS_DEPENDS.flex?= ${_TOOLS_DEPENDS.flex}
|
|
|
|
TOOLS_CREATE+= flex
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.flex=flex
|
|
|
|
TOOLS_REAL_CMD.flex= ${TOOLS_PREFIX.flex}/bin/flex
|
|
|
|
TOOLS_${_TOOLS_VARNAME.flex}= ${TOOLS_REAL_CMD.flex}
|
|
|
|
. endif
|
|
|
|
TOOLS_ALIASES.flex= lex
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.gawk) && !empty(_USE_TOOLS:Mgawk)
|
2005-04-25 00:34:35 +02:00
|
|
|
. if !empty(PKGPATH:Mlang/gawk)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.gawk=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.gawk:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.gawk?= gawk>=3.1.1:../../lang/gawk
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= gawk
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.gawk=gawk
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.gawk= ${TOOLS_PREFIX.gawk}/bin/${GNU_PROGRAM_PREFIX}awk
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.gawk}= ${TOOLS_REAL_CMD.gawk}
|
2005-04-25 00:34:35 +02:00
|
|
|
. endif
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_ALIASES.gawk= awk
|
2005-04-25 00:34:35 +02:00
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.gm4) && !empty(_USE_TOOLS:Mgm4)
|
2005-04-25 00:42:00 +02:00
|
|
|
. if !empty(PKGPATH:Mdevel/m4)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.gm4=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.gm4:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.gm4?= m4>=1.4:../../devel/m4
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= gm4
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.gm4=m4
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.gm4= ${TOOLS_PREFIX.gm4}/bin/gm4
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.gm4}= ${TOOLS_REAL_CMD.gm4}
|
2005-04-25 00:42:00 +02:00
|
|
|
. endif
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_ALIASES.gm4= m4
|
2005-04-25 00:42:00 +02:00
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.gmake) && !empty(_USE_TOOLS:Mgmake)
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. if !empty(PKGPATH:Mdevel/gmake)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.gmake=
|
2005-04-24 05:07:36 +02:00
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.gmake:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.gmake?= gmake>=3.78:../../devel/gmake
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= gmake
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.gmake=gmake
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.gmake= ${TOOLS_PREFIX.gmake}/bin/gmake
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.gmake}= ${TOOLS_REAL_CMD.gmake}
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.grep) && !empty(_USE_TOOLS:Mgrep)
|
2005-04-28 05:57:39 +02:00
|
|
|
. if !empty(PKGPATH:Mtextproc/grep)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.grep=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.grep:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.grep?= grep>=2.5.1:../../textproc/grep
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= grep
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.grep=grep
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.grep= ${TOOLS_PREFIX.grep}/bin/${GNU_PROGRAM_PREFIX}grep
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.grep}= ${TOOLS_REAL_CMD.grep}
|
2005-04-28 05:57:39 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.gsed) && !empty(_USE_TOOLS:Mgsed)
|
2005-04-28 06:00:15 +02:00
|
|
|
. if !empty(PKGPATH:Mtextproc/gsed)
|
2005-04-26 21:15:38 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.gsed=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.gsed:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.gsed?= gsed>=3.0.2:../../textproc/gsed
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= gsed
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.gsed=gsed
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.gsed= ${TOOLS_PREFIX.gsed}/bin/${GNU_PROGRAM_PREFIX}sed
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.gsed}= ${TOOLS_REAL_CMD.gsed}
|
2005-04-24 05:07:36 +02:00
|
|
|
. endif
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_ALIASES.gsed= sed
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.gtar) && !empty(_USE_TOOLS:Mgtar)
|
2005-05-14 23:15:07 +02:00
|
|
|
. if !empty(PKGPATH:Marchivers/gtar-base)
|
2005-04-28 05:57:39 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.gtar=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.gtar:M[yY][eE][sS])
|
2005-05-14 23:15:07 +02:00
|
|
|
TOOLS_DEPENDS.gtar?= gtar-base>=1.13.25:../../archivers/gtar-base
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= gtar
|
2005-05-14 23:15:07 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.gtar=gtar-base
|
|
|
|
TOOLS_REAL_CMD.gtar= ${TOOLS_PREFIX.gtar}/bin/${GNU_PROGRAM_PREFIX}tar
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.gtar}= ${TOOLS_REAL_CMD.gtar}
|
2005-04-27 05:41:17 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.gunzip) && !empty(_USE_TOOLS:Mgunzip)
|
2005-05-16 00:33:08 +02:00
|
|
|
. if !empty(PKGPATH:Marchivers/gzip-base)
|
2005-04-28 05:57:39 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.gunzip=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.gunzip:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.gunzip?= gzip-base>=1.2.4b:../../archivers/gzip-base
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= gunzip
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.gunzip=gzip-base
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.gunzip= ${TOOLS_PREFIX.gunzip}/bin/gunzip
|
2005-05-09 02:13:03 +02:00
|
|
|
TOOLS_REAL_ARGS.gunzip= -f
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.gunzip}= ${TOOLS_REAL_CMD.gunzip} ${TOOLS_REAL_ARGS.gunzip}
|
2005-04-28 05:57:39 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.gzcat) && !empty(_USE_TOOLS:Mgzcat)
|
2005-05-16 00:33:08 +02:00
|
|
|
. if !empty(PKGPATH:Marchivers/gzip-base)
|
2005-04-28 05:57:39 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.gzcat=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.gzcat:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.gzcat?= gzip-base>=1.2.4b:../../archivers/gzip-base
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= gzcat
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.gzcat=gzip-base
|
2005-05-16 00:34:43 +02:00
|
|
|
TOOLS_REAL_CMD.gzcat= ${TOOLS_PREFIX.gzcat}/bin/zcat
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.gzcat}= ${TOOLS_REAL_CMD.gzcat}
|
2005-04-28 05:57:39 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.gzip) && !empty(_USE_TOOLS:Mgzip)
|
2005-05-16 00:33:08 +02:00
|
|
|
. if !empty(PKGPATH:Marchivers/gzip-base)
|
2005-04-28 05:57:39 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.gzip=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.gzip:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.gzip?= gzip-base>=1.2.4b:../../archivers/gzip-base
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= gzip
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.gzip=gzip-base
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.gzip= ${TOOLS_PREFIX.gzip}/bin/gzip
|
2005-05-09 02:13:03 +02:00
|
|
|
TOOLS_REAL_ARGS.gzip= -nf ${GZIP}
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.gzip}= ${TOOLS_REAL_CMD.gzip} ${TOOLS_REAL_ARGS.gzip}
|
2005-04-24 05:59:44 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.head) && !empty(_USE_TOOLS:Mhead)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.head=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.head:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.head?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= head
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.head=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.head= ${TOOLS_PREFIX.head}/bin/${GNU_PROGRAM_PREFIX}head
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.head}= ${TOOLS_REAL_CMD.head}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.hostname) && !empty(_USE_TOOLS:Mhostname)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.hostname=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.hostname:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.hostname?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= hostname
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.hostname=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.hostname= ${TOOLS_PREFIX.hostname}/bin/${GNU_PROGRAM_PREFIX}hostname
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.hostname}= ${TOOLS_REAL_CMD.hostname}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.id) && !empty(_USE_TOOLS:Mid)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.id=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.id:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.id?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= id
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.id=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.id= ${TOOLS_PREFIX.id}/bin/${GNU_PROGRAM_PREFIX}id
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.id}= ${TOOLS_REAL_CMD.id}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-19 07:27:25 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.imake) && !empty(_USE_TOOLS:Mimake)
|
|
|
|
. if !empty(PKGPATH:Mx11/imake) || !empty(PKGPATH:Mx11/xorg-imake)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.imake=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.imake:M[yY][eE][sS])
|
|
|
|
TOOLS_CREATE+= imake
|
|
|
|
. if defined(X11_TYPE) && !empty(X11_TYPE:MXFree86)
|
|
|
|
TOOLS_DEPENDS.imake?= imake>=4.4.0:../../x11/imake
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.imake=imake
|
|
|
|
TOOLS_REAL_CMD.imake= ${TOOLS_PREFIX.imake}/${X11ROOT_PREFIX}/bin/imake
|
|
|
|
. elif defined(X11_TYPE) && !empty(X11_TYPE:Mxorg)
|
|
|
|
TOOLS_DEPENDS.imake?= xorg-imake>=6.8:../../x11/xorg-imake
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.imake=xorg-imake
|
|
|
|
TOOLS_REAL_CMD.imake= ${TOOLS_PREFIX.imake}/${X11ROOT_PREFIX}/bin/imake
|
|
|
|
. else # !empty(X11_TYPE:Mnative)
|
|
|
|
TOOLS_REAL_CMD.imake= ${X11BASE}/bin/imake
|
|
|
|
. endif
|
|
|
|
TOOLS_${_TOOLS_VARNAME.imake}= ${TOOLS_REAL_CMD.imake} ${TOOLS_REAL_ARGS.imake}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-03 22:41:53 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.install) && !empty(_USE_TOOLS:Minstall)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.install=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.install:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.install?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= install
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.install=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.install= ${TOOLS_PREFIX.install}/bin/${GNU_PROGRAM_PREFIX}install
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.install}= ${TOOLS_REAL_CMD.install}
|
2005-05-03 22:41:53 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.lex) && !empty(_USE_TOOLS:Mlex)
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. if !empty(PKGPATH:Mdevel/flex)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.lex=
|
2005-04-24 05:07:36 +02:00
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.lex:M[yY][eE][sS])
|
|
|
|
. include "../../devel/flex/buildlink3.mk"
|
2005-05-14 23:38:18 +02:00
|
|
|
_TOOLS_DEPENDS.lex= # empty
|
|
|
|
. for _dep_ in ${BUILDLINK_DEPENDS.flex}
|
|
|
|
_TOOLS_DEPENDS.lex+= ${_dep_}:${BUILDLINK_PKGSRCDIR.flex}
|
|
|
|
. endfor
|
|
|
|
TOOLS_DEPENDS.lex?= ${_TOOLS_DEPENDS.lex}
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= lex
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.lex=flex
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.lex= ${TOOLS_PREFIX.lex}/bin/flex
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.lex}= ${TOOLS_REAL_CMD.lex}
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-14 00:08:20 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.lha) && !empty(_USE_TOOLS:Mlha)
|
|
|
|
. if !empty(PKGPATH:Marchivers/lha)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.lha=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.lha:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.lha?= lha>=114.9:../../archivers/lha
|
|
|
|
TOOLS_CREATE+= lha
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.lha=lha
|
2005-05-14 00:08:20 +02:00
|
|
|
TOOLS_REAL_CMD.lha= ${TOOLS_PREFIX.lha}/bin/lha
|
|
|
|
TOOLS_${_TOOLS_VARNAME.lha}= ${TOOLS_REAL_CMD.lha}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.ln) && !empty(_USE_TOOLS:Mln)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.ln=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.ln:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.ln?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= ln
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.ln=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.ln= ${TOOLS_PREFIX.ln}/bin/${GNU_PROGRAM_PREFIX}ln
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.ln}= ${TOOLS_REAL_CMD.ln}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.ls) && !empty(_USE_TOOLS:Mls)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.ls=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.ls:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.ls?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= ls
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.ls=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.ls= ${TOOLS_PREFIX.ls}/bin/${GNU_PROGRAM_PREFIX}ls
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.ls}= ${TOOLS_REAL_CMD.ls}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.m4) && !empty(_USE_TOOLS:Mm4)
|
2005-04-27 18:28:19 +02:00
|
|
|
. if !empty(PKGPATH:Mdevel/m4)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.m4=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.m4:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.m4?= m4>=1.4:../../devel/m4
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= m4
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.m4=m4
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.m4= ${TOOLS_PREFIX.m4}/bin/gm4
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.m4}= ${TOOLS_REAL_CMD.m4}
|
2005-04-27 18:28:19 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-03 18:30:34 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.mail) && !empty(_USE_TOOLS:Mmail)
|
|
|
|
. if !empty(PKGPATH:Mmail/nail)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.mail=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.mail:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.mail?= nail>=11.22:../../mail/nail
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= mail
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.mail=nail
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.mail= ${TOOLS_PREFIX.mail}/bin/nail
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.mail}= ${TOOLS_REAL_CMD.mail}
|
2005-05-03 18:30:34 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.mkdir) && !empty(_USE_TOOLS:Mmkdir)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.mkdir=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.mkdir:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.mkdir?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= mkdir
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.mkdir=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.mkdir= ${TOOLS_PREFIX.mkdir}/bin/${GNU_PROGRAM_PREFIX}mkdir
|
2005-05-09 02:13:03 +02:00
|
|
|
TOOLS_REAL_ARGS.mkdir= -p
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.mkdir}= ${TOOLS_REAL_CMD.mkdir} ${TOOLS_REAL_ARGS.mkdir}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-06-04 00:54:44 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.mktemp) && !empty(_USE_TOOLS:Mmktemp)
|
|
|
|
. if !empty(PKGPATH:Msysutils/mktemp)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.mktemp=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.mktemp:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.mktemp?= mktemp>=1.5:../../sysutils/mktemp
|
|
|
|
TOOLS_CREATE+= mktemp
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.mktemp=mktemp
|
|
|
|
TOOLS_REAL_CMD.mktemp= ${TOOLS_PREFIX.mktemp}/bin/mktemp
|
|
|
|
TOOLS_${_TOOLS_VARNAME.mktemp}= ${TOOLS_REAL_CMD.mktemp}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.mtree) && !empty(_USE_TOOLS:Mmtree)
|
2005-04-27 08:15:53 +02:00
|
|
|
. if !empty(PKGPATH:Mpkgtools/mtree)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.mtree=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.mtree:M[yY][eE][sS])
|
2005-04-27 17:21:50 +02:00
|
|
|
#
|
|
|
|
# This is installed by pkgsrc bootstrap, and is never registered, so
|
|
|
|
# comment out the dependency on it.
|
|
|
|
#
|
2005-04-28 05:01:11 +02:00
|
|
|
#TOOLS_DEPENDS.mtree?= mtree>=20040722:../../pkgtools/mtree
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= mtree
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.mtree=mtree
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.mtree= ${TOOLS_PREFIX.mtree}/bin/mtree
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.mtree}= ${TOOLS_REAL_CMD.mtree}
|
2005-04-27 08:15:53 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.mv) && !empty(_USE_TOOLS:Mmv)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.mv=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.mv:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.mv?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= mv
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.mv=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.mv= ${TOOLS_PREFIX.mv}/bin/${GNU_PROGRAM_PREFIX}mv
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.mv}= ${TOOLS_REAL_CMD.mv}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.nice) && !empty(_USE_TOOLS:Mnice)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.nice=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.nice:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.nice?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= nice
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.nice=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.nice= ${TOOLS_PREFIX.nice}/bin/${GNU_PROGRAM_PREFIX}nice
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.nice}= ${TOOLS_REAL_CMD.nice}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-26 23:46:13 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.nroff) && !empty(_USE_TOOLS:Mnroff)
|
|
|
|
. if !empty(PKGPATH:Mtextproc/groff)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.nroff=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.nroff:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.nroff?= groff>=1.19nb4:../../textproc/groff
|
|
|
|
TOOLS_CREATE+= nroff
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.nroff=groff
|
|
|
|
TOOLS_REAL_CMD.nroff= ${TOOLS_PREFIX.nroff}/bin/nroff
|
|
|
|
TOOLS_${_TOOLS_VARNAME.nroff}= ${TOOLS_REAL_CMD.nroff}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.patch) && !empty(_USE_TOOLS:Mpatch)
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. if !empty(PKGPATH:Mdevel/patch)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.patch=
|
2005-04-24 05:07:36 +02:00
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.patch:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.patch?= patch>=2.2:../../devel/patch
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= patch
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.patch=patch
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.patch= ${TOOLS_PREFIX.patch}/bin/gpatch
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.patch}= ${TOOLS_REAL_CMD.patch}
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.pax) && !empty(_USE_TOOLS:Mpax)
|
2005-04-28 05:57:39 +02:00
|
|
|
. if !empty(PKGPATH:Marchivers/pax)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.pax=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.pax:M[yY][eE][sS])
|
|
|
|
#
|
|
|
|
# This is installed by pkgsrc bootstrap, and is never registered, so
|
|
|
|
# comment out the dependency on it.
|
|
|
|
#
|
|
|
|
#TOOLS_DEPENDS.pax?= pax>=20040802:../../archivers/pax
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= pax
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.pax=pax
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.pax= ${TOOLS_PREFIX.pax}/bin/pax
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.pax}= ${TOOLS_REAL_CMD.pax}
|
2005-04-28 05:57:39 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-06-02 23:03:32 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.perl) && !empty(_USE_TOOLS:Mperl)
|
2005-06-24 08:43:43 +02:00
|
|
|
. if !empty(PKGPATH:Mlang/perl5)
|
2005-05-19 05:52:23 +02:00
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.perl=
|
2005-06-02 23:03:32 +02:00
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.perl:M[yY][eE][sS])
|
2005-05-19 05:52:23 +02:00
|
|
|
. include "../../lang/perl5/version.mk"
|
2005-06-24 08:43:43 +02:00
|
|
|
TOOLS_DEPENDS.perl?= {perl>=${PERL5_REQD},perl-thread>=${PERL5_REQD}}:../../lang/perl5
|
2005-05-19 05:52:23 +02:00
|
|
|
TOOLS_CREATE+= perl
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.perl=perl
|
|
|
|
TOOLS_REAL_CMD.perl= ${TOOLS_PREFIX.perl}/bin/perl
|
|
|
|
TOOLS_${_TOOLS_VARNAME.perl}= ${TOOLS_REAL_CMD.perl}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.pwd) && !empty(_USE_TOOLS:Mpwd)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.pwd=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.pwd:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.pwd?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= pwd
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.pwd=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.pwd= ${TOOLS_PREFIX.pwd}/bin/${GNU_PROGRAM_PREFIX}pwd
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.pwd}= ${TOOLS_REAL_CMD.pwd}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.rm) && !empty(_USE_TOOLS:Mrm)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.rm=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.rm:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.rm?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= rm
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.rm=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.rm= ${TOOLS_PREFIX.rm}/bin/${GNU_PROGRAM_PREFIX}rm
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.rm}= ${TOOLS_REAL_CMD.rm}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.rmdir) && !empty(_USE_TOOLS:Mrmdir)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.rmdir=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.rmdir:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.rmdir?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= rmdir
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.rmdir=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.rmdir= ${TOOLS_PREFIX.rmdir}/bin/${GNU_PROGRAM_PREFIX}rmdir
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.rmdir}= ${TOOLS_REAL_CMD.rmdir}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.sed) && !empty(_USE_TOOLS:Msed)
|
2005-04-27 18:28:19 +02:00
|
|
|
. if !empty(PKGPATH:Mtextproc/nbsed)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.sed=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.sed:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.sed?= nbsed>=20040821:../../textproc/nbsed
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= sed
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.sed=nbsed
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.sed= ${TOOLS_PREFIX.nbsed}/bin/nbsed
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.sed}= ${TOOLS_REAL_CMD.sed}
|
2005-04-27 18:28:19 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.sh) && !empty(_USE_TOOLS:Msh)
|
2005-04-27 06:47:41 +02:00
|
|
|
. if !empty(PKGPATH:Mshells/pdksh)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.sh=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.sh:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.sh?= pdksh>=5.2.14:../../shells/pdksh
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= sh
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.sh=pdksh
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.sh= ${TOOLS_PREFIX.sh}/bin/pdksh
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.sh}= ${TOOLS_REAL_CMD.sh}
|
2005-04-27 06:47:41 +02:00
|
|
|
. endif
|
|
|
|
TOOLS_CMD.sh= ${TOOLS_DIR}/bin/sh
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.shlock) && !empty(_USE_TOOLS:Mshlock)
|
2005-04-27 06:47:41 +02:00
|
|
|
. if !empty(PKGPATH:Mpkgtools/shlock)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.shlock=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.shlock:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.shlock?= shlock>=20020114:../../pkgtools/shlock
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= shlock
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.shlock=shlock
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.shlock= ${TOOLS_PREFIX.shlock}/bin/shlock
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.shlock}= ${TOOLS_REAL_CMD.shlock}
|
2005-04-27 06:47:41 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.sort) && !empty(_USE_TOOLS:Msort)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.sort=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.sort:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.sort?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= sort
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.sort=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.sort= ${TOOLS_PREFIX.sort}/bin/${GNU_PROGRAM_PREFIX}sort
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.sort}= ${TOOLS_REAL_CMD.sort}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.tail) && !empty(_USE_TOOLS:Mtail)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.tail=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.tail:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.tail?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= tail
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.tail=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.tail= ${TOOLS_PREFIX.tail}/bin/${GNU_PROGRAM_PREFIX}tail
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.tail}= ${TOOLS_REAL_CMD.tail}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-14 23:15:07 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.tar) && !empty(_USE_TOOLS:Mtar)
|
|
|
|
. if !empty(PKGPATH:Marchivers/pax)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.tar=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.tar:M[yY][eE][sS])
|
|
|
|
#
|
|
|
|
# This is installed by pkgsrc bootstrap, and is never registered, so
|
|
|
|
# comment out the dependency on it.
|
|
|
|
#
|
|
|
|
#TOOLS_DEPENDS.tar?= pax>=20040802:../../archivers/pax
|
|
|
|
TOOLS_CREATE+= tar
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.tar=pax
|
|
|
|
TOOLS_REAL_CMD.tar= ${TOOLS_PREFIX.tar}/bin/tar
|
|
|
|
TOOLS_${_TOOLS_VARNAME.tar}= ${TOOLS_REAL_CMD.tar}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.tbl) && !empty(_USE_TOOLS:Mtbl)
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. if !empty(PKGPATH:Mtextproc/groff)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.tbl=
|
2005-04-24 05:07:36 +02:00
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.tbl:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.tbl?= groff>=1.19nb4:../../textproc/groff
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= tbl
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.tbl=groff
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.tbl= ${TOOLS_PREFIX.tbl}/bin/tbl
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.tbl}= ${TOOLS_REAL_CMD.tbl}
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.tee) && !empty(_USE_TOOLS:Mtee)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.tee=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.tee:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.tee?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= tee
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.tee=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.tee= ${TOOLS_PREFIX.tee}/bin/${GNU_PROGRAM_PREFIX}tee
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.tee}= ${TOOLS_REAL_CMD.tee}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.test) && !empty(_USE_TOOLS:Mtest)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.test=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.test:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.test?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= test
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.test=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.test= ${TOOLS_PREFIX.test}/bin/${GNU_PROGRAM_PREFIX}test
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.test}= ${TOOLS_REAL_CMD.test}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.touch) && !empty(_USE_TOOLS:Mtouch)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.touch=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.touch:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.touch?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= touch
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.touch=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.touch= ${TOOLS_PREFIX.touch}/bin/${GNU_PROGRAM_PREFIX}touch
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.touch}= ${TOOLS_REAL_CMD.touch}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.tr) && !empty(_USE_TOOLS:Mtr)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.tr=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.tr:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.tr?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= tr
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.tr=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.tr= ${TOOLS_PREFIX.tr}/bin/${GNU_PROGRAM_PREFIX}tr
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.tr}= ${TOOLS_REAL_CMD.tr}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.true) && !empty(_USE_TOOLS:Mtrue)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.true=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.true:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.true?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= true
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.true=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.true= ${TOOLS_PREFIX.true}/bin/${GNU_PROGRAM_PREFIX}true
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.true}= ${TOOLS_REAL_CMD.true}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.tsort) && !empty(_USE_TOOLS:Mtsort)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.tsort=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.tsort:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.tsort?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= tsort
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.tsort=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.tsort= ${TOOLS_PREFIX.tsort}/bin/${GNU_PROGRAM_PREFIX}tsort
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.tsort}= ${TOOLS_REAL_CMD.tsort}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-14 00:08:20 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.unrar) && !empty(_USE_TOOLS:Munrar)
|
|
|
|
. if !empty(PKGPATH:Marchivers/unrar)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.unrar=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.unrar:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.unrar?= unrar>=3.3.4:../../archivers/unrar
|
|
|
|
TOOLS_CREATE+= unrar
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.unrar=unrar
|
2005-05-14 00:08:20 +02:00
|
|
|
TOOLS_REAL_CMD.unrar= ${TOOLS_PREFIX.unrar}/bin/unrar
|
|
|
|
TOOLS_${_TOOLS_VARNAME.unrar}= ${TOOLS_REAL_CMD.unrar}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.unzip) && !empty(_USE_TOOLS:Munzip)
|
|
|
|
. if !empty(PKGPATH:Marchivers/unzip)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.unzip=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.unzip:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.unzip?= unzip-[0-9]*:../../archivers/unzip
|
|
|
|
TOOLS_CREATE+= unzip
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.unzip=unzip
|
2005-05-14 00:08:20 +02:00
|
|
|
TOOLS_REAL_CMD.unzip= ${TOOLS_PREFIX.unzip}/bin/unzip
|
|
|
|
TOOLS_${_TOOLS_VARNAME.unzip}= ${TOOLS_REAL_CMD.unzip}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(TOOLS_IGNORE.unzoo) && !empty(_USE_TOOLS:Munzoo)
|
|
|
|
. if !empty(PKGPATH:Marchivers/unzoo)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.unzoo=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.unzoo:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.unzoo?= unzoo-[0-9]*:../../archivers/unzoo
|
|
|
|
TOOLS_CREATE+= unzoo
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.unzoo=unzoo
|
2005-05-14 00:08:20 +02:00
|
|
|
TOOLS_REAL_CMD.unzoo= ${TOOLS_PREFIX.unzoo}/bin/unzoo
|
|
|
|
TOOLS_${_TOOLS_VARNAME.unzoo}= ${TOOLS_REAL_CMD.unzoo}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 19:35:48 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.wc) && !empty(_USE_TOOLS:Mwc)
|
|
|
|
. if !empty(PKGPATH:Msysutils/coreutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.wc=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.wc:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.wc?= coreutils>=5.2.1:../../sysutils/coreutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= wc
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.wc=coreutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.wc= ${TOOLS_PREFIX.wc}/bin/${GNU_PROGRAM_PREFIX}wc
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.wc}= ${TOOLS_REAL_CMD.wc}
|
2005-04-28 19:35:48 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.xargs) && !empty(_USE_TOOLS:Mxargs)
|
2005-04-28 05:57:39 +02:00
|
|
|
. if !empty(PKGPATH:Msysutils/findutils)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.xargs=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.xargs:M[yY][eE][sS])
|
|
|
|
TOOLS_DEPENDS.xargs?= findutils>=4.1:../../sysutils/findutils
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= xargs
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.xargs=findutils
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.xargs= ${TOOLS_PREFIX.xargs}/bin/${GNU_PROGRAM_PREFIX}xargs
|
2005-05-09 02:13:03 +02:00
|
|
|
TOOLS_REAL_ARGS.xargs= -r # don't run command if stdin is empty
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.xargs}= ${TOOLS_REAL_CMD.xargs} ${TOOLS_REAL_ARGS.xargs}
|
2005-04-28 05:57:39 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-19 07:27:25 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.xmkmf) && !empty(_USE_TOOLS:Mxmkmf)
|
|
|
|
. if !empty(PKGPATH:Mx11/imake) || !empty(PKGPATH:Mx11/xorg-imake)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.xmkmf=
|
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.xmkmf:M[yY][eE][sS])
|
|
|
|
TOOLS_CREATE+= xmkmf
|
|
|
|
. if defined(X11_TYPE) && !empty(X11_TYPE:MXFree86)
|
|
|
|
TOOLS_DEPENDS.xmkmf?= imake>=4.4.0:../../x11/imake
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.xmkmf=imake
|
|
|
|
TOOLS_REAL_CMD.xmkmf= ${TOOLS_PREFIX.xmkmf}/${X11ROOT_PREFIX}/bin/xmkmf
|
|
|
|
. elif defined(X11_TYPE) && !empty(X11_TYPE:Mxorg)
|
|
|
|
TOOLS_DEPENDS.xmkmf?= xorg-imake>=6.8:../../x11/xorg-imake
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.xmkmf=xorg-imake
|
|
|
|
TOOLS_REAL_CMD.xmkmf= ${TOOLS_PREFIX.xmkmf}/${X11ROOT_PREFIX}/bin/xmkmf
|
|
|
|
. else # !empty(X11_TYPE:Mnative)
|
|
|
|
TOOLS_REAL_CMD.xmkmf= ${X11BASE}/bin/xmkmf
|
|
|
|
. endif
|
|
|
|
#
|
|
|
|
# If we're using xpkgwedge, then we need to invoke the special xmkmf
|
|
|
|
# script that will find imake config files in both ${PREFIX} and in
|
|
|
|
# ${X11BASE}.
|
|
|
|
#
|
|
|
|
. if !empty(USE_XPKGWEDGE:M[yY][eE][sS])
|
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.xpkgwedge=xpkgwedge
|
|
|
|
TOOLS_REAL_CMD.xmkmf= ${TOOLS_PREFIX.xpkgwedge}/bin/pkgxmkmf
|
|
|
|
. endif
|
|
|
|
TOOLS_${_TOOLS_VARNAME.xmkmf}= ${TOOLS_REAL_CMD.xmkmf} ${TOOLS_REAL_ARGS.xmkmf}
|
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-04-28 17:47:43 +02:00
|
|
|
.if !defined(TOOLS_IGNORE.yacc) && !empty(_USE_TOOLS:Myacc)
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. if !empty(PKGPATH:Mdevel/bison)
|
|
|
|
MAKEFLAGS+= TOOLS_IGNORE.yacc=
|
2005-04-24 05:07:36 +02:00
|
|
|
. elif !empty(_TOOLS_USE_PKGSRC.yacc:M[yY][eE][sS])
|
2005-04-28 05:01:11 +02:00
|
|
|
TOOLS_DEPENDS.yacc?= bison>=1.0:../../devel/bison
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= yacc
|
2005-05-14 07:57:43 +02:00
|
|
|
TOOLS_FIND_PREFIX+= TOOLS_PREFIX.yacc=bison
|
2005-05-11 21:42:17 +02:00
|
|
|
TOOLS_REAL_CMD.yacc= ${TOOLS_PREFIX.yacc}/bin/bison
|
2005-05-09 02:13:03 +02:00
|
|
|
TOOLS_REAL_ARGS.yacc= -y
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.yacc}= ${TOOLS_REAL_CMD.yacc} ${TOOLS_REAL_ARGS.yacc}
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. endif
|
|
|
|
.endif
|
|
|
|
|
2005-05-14 07:57:43 +02:00
|
|
|
# Compute the locations of the pkgsrc-supplied tools.
|
|
|
|
FIND_PREFIX:= ${TOOLS_FIND_PREFIX}
|
|
|
|
.include "../../mk/find-prefix.mk"
|
|
|
|
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
######################################################################
|
|
|
|
|
2005-04-28 05:01:11 +02:00
|
|
|
# Add the dependencies for each pkgsrc-supplied tool.
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
#
|
2005-04-28 17:51:10 +02:00
|
|
|
.for _t_ in ${_USE_TOOLS}
|
|
|
|
. if defined(TOOLS_DEPMETHOD.${_t_}) && defined(TOOLS_DEPENDS.${_t_})
|
2005-05-19 04:27:38 +02:00
|
|
|
. for _dep_ in ${TOOLS_DEPENDS.${_t_}}
|
|
|
|
. if empty(${TOOLS_DEPMETHOD.${_t_}}:C/\:.*$//:M${_dep_:C/\:.*$//})
|
|
|
|
${TOOLS_DEPMETHOD.${_t_}}+= ${_dep_}
|
|
|
|
. endif
|
|
|
|
. endfor
|
2005-04-28 05:01:11 +02:00
|
|
|
. endif
|
|
|
|
.endfor
|
|
|
|
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
######################################################################
|
|
|
|
|
2005-07-15 20:27:48 +02:00
|
|
|
# For each tool, make sure that the "TOOL" name points to the real
|
|
|
|
# command, e.g., AWK, SED, etc., provided that "TOOL" has been
|
|
|
|
# associated with <tool>.
|
2005-05-11 07:05:03 +02:00
|
|
|
#
|
2005-07-15 20:27:48 +02:00
|
|
|
.for _t_ in ${_USE_TOOLS}
|
2005-05-11 07:05:03 +02:00
|
|
|
_TOOLS_USE_PKGSRC.${_t_}?= no
|
|
|
|
. if defined(_TOOLS_VARNAME.${_t_})
|
|
|
|
. if !empty(_TOOLS_USE_PKGSRC.${_t_}:M[nN][oO])
|
|
|
|
. if defined(TOOLS_PLATFORM.${_t_}) && !empty(TOOLS_PLATFORM.${_t_})
|
2005-05-13 23:57:13 +02:00
|
|
|
${_TOOLS_VARNAME.${_t_}}= ${TOOLS_PLATFORM.${_t_}}
|
2005-05-11 07:05:03 +02:00
|
|
|
. endif
|
|
|
|
. else
|
2005-05-13 23:57:13 +02:00
|
|
|
${_TOOLS_VARNAME.${_t_}}= ${TOOLS_${_TOOLS_VARNAME.${_t_}}}
|
2005-05-11 07:05:03 +02:00
|
|
|
. endif
|
|
|
|
. endif
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
######################################################################
|
|
|
|
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
# If we are using the system-supplied tool, create symlinks or wrappers
|
|
|
|
# for each of the tools requested.
|
|
|
|
#
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
# Set TOOLS_REAL_CMD.<tool> appropriately in the case where we are
|
2005-04-26 18:19:37 +02:00
|
|
|
# using the system-supplied tool. Here, we first check to see if
|
2005-04-30 06:35:54 +02:00
|
|
|
# TOOLS_PLATFORM.<tool> is defined. If it is, then use that as the
|
|
|
|
# path to the real command and extract any arguments into
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
# TOOLS_REAL_ARGS.<tool>.
|
|
|
|
#
|
|
|
|
# Always set the "TOOLS_TOOL" name for each tool to point to the real
|
|
|
|
# command, e.g., TOOLS_TBL, TOOLS_YACC, etc., provided that "TOOL" has
|
2005-05-11 07:05:03 +02:00
|
|
|
# been associated with <tool>. If the "TOOL" name is undefined, then
|
|
|
|
# set it to the same value to provide a simple name for use by package
|
|
|
|
# Makefiles.
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
#
|
2005-04-28 17:51:10 +02:00
|
|
|
.for _t_ in ${_USE_TOOLS}
|
|
|
|
. if !defined(TOOLS_IGNORE.${_t_}) && \
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
!empty(_TOOLS_USE_PKGSRC.${_t_}:M[nN][oO])
|
2005-04-27 18:52:28 +02:00
|
|
|
. if defined(TOOLS_PLATFORM.${_t_}) && !empty(TOOLS_PLATFORM.${_t_})
|
2005-04-25 08:16:38 +02:00
|
|
|
TOOLS_REAL_CMD.${_t_}?= \
|
2005-04-27 18:52:28 +02:00
|
|
|
${TOOLS_PLATFORM.${_t_}:C/^/_asdf_/1:M_asdf_*:S/^_asdf_//}
|
2005-05-09 02:13:03 +02:00
|
|
|
TOOLS_REAL_ARGS.${_t_}?= \
|
2005-04-27 18:52:28 +02:00
|
|
|
${TOOLS_PLATFORM.${_t_}:C/^/_asdf_/1:N_asdf_*}
|
2005-04-28 19:40:52 +02:00
|
|
|
. if defined(_TOOLS_VARNAME.${_t_})
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.${_t_}}= ${TOOLS_PLATFORM.${_t_}}
|
2005-04-28 19:40:52 +02:00
|
|
|
. endif
|
2005-05-09 03:11:58 +02:00
|
|
|
TOOLS_CREATE+= ${_t_}
|
2005-04-26 20:59:48 +02:00
|
|
|
. elif defined(_TOOLS_VARNAME.${_t_})
|
|
|
|
. if defined(TOOLS_REAL_CMD.${_t_})
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.${_t_}}= ${TOOLS_REAL_CMD.${_t_}} ${TOOLS_REAL_ARGS.${_t_}}
|
2005-04-26 20:59:48 +02:00
|
|
|
. else
|
Make a distinction between the tools that pkgsrc needs and the tools
that a package needs. Tools that pkgsrc needs are listed in
PKGSRC_USE_TOOLS, and tools that a package needs on top of that are
listed in USE_TOOLS.
Define "TOOL" variables, e.g. SED, AWK, MKDIR, etc. for each of the
tools that pkgsrc needs, and "TOOLS_TOOL" variables, e.g. TOOLS_SED,
TOOLS_AWK, TOOLS_MKDIR, etc. for each of the tools that a package
needs. These variables contain the full command line to the real
command and arguments needed to invoke the tool.
2005-05-10 21:06:58 +02:00
|
|
|
TOOLS_${_TOOLS_VARNAME.${_t_}}= ${_TOOLS_VARNAME.${_t_}}_not_defined_
|
|
|
|
. endif
|
|
|
|
. endif
|
|
|
|
. endif
|
|
|
|
. if defined(_TOOLS_VARNAME.${_t_})
|
2005-05-11 07:05:03 +02:00
|
|
|
. if defined(TOOLS_${_TOOLS_VARNAME.${_t_}})
|
2005-05-12 05:57:40 +02:00
|
|
|
. for _v_ in ${_TOOLS_VARNAME.${_t_}}
|
|
|
|
${_v_}?= ${TOOLS_${_TOOLS_VARNAME.${_t_}}}
|
|
|
|
. endfor
|
Initial commit of the new tools framework. This is currently designed
to be a drop-in replacement for mk/tools.mk, but isn't yet enabled
pending further testing. To use, edit bsd.pkg.mk to include bsd.tools.mk
instead of tools.mk.
The major changes from the old tools framework are:
(1) The new interface to using the tools framework is through setting
USE_TOOLS in the package Makefile, e.g.,
USE_TOOLS+= autoconf gmake yacc
(2) Bison/yacc handling is improved. Instead of adding checks for
/usr/bin/yacc to the package Makefile and explicitly setting YACC,
e.g., security/mit-krb5/Makefile, simply add "yacc" to USE_TOOLS.
If bison is explicitly required, then add "bison" to USE_TOOLS
instead.
(3) GNU auto* tools are handled differently. "autoconf", "aclocal",
"automake", etc. will be tools in ${TOOLS_DIR} that point to the
correct versions of the auto* tools. Instead of patching Makefiles
or scripts to use ${AUTOCONF}, ${ACLOCAL}, etc., the correct
versions of the tools will be called if they are invoked simply
by their bare names. This is selected by adding either "autoconf"
or "autoconf213", or "automake" or "automake14" to USE_TOOLS.
The new tools framework will deprecate the following variables:
ACLOCAL AUTORECONF
AUTOCONF BUILD_USES_GETTEXT_M4
AUTOHEADER USE_GNU_TOOLS
AUTOMAKE USE_TBL
The new tools framework will deprecate the following *.mk files:
mk/autoconf.mk
mk/automake.mk
mk/tools.mk
Additional documentation on how to use bsd.tools.mk to create new tools
under ${TOOLS_DIR} may be found in the header comments in bsd.tools.mk.
2005-04-15 02:00:21 +02:00
|
|
|
. endif
|
|
|
|
. endif
|
|
|
|
.endfor
|
2005-05-22 01:09:36 +02:00
|
|
|
|
|
|
|
######################################################################
|
|
|
|
|
|
|
|
# For packages that use GNU configure scripts, pass the real command
|
|
|
|
# paths for the tools that the package uses through the shell environment.
|
|
|
|
# We do this since these paths may be hardcoded into package scripts,
|
|
|
|
# and if they're not pre-specified, then they'll be searched for in the
|
|
|
|
# PATH, which would find the ones in ${TOOLS_DIR}.
|
|
|
|
#
|
|
|
|
.if defined(GNU_CONFIGURE)
|
|
|
|
. for _t_ in ${_USE_TOOLS}
|
2005-05-22 03:56:27 +02:00
|
|
|
. if defined(TOOLS_${_TOOLS_VARNAME.${_t_}})
|
|
|
|
. for _v_ in ${_TOOLS_VARNAME_GNU.${_t_}}
|
|
|
|
CONFIGURE_ENV+= ${_v_}=${TOOLS_${_TOOLS_VARNAME.${_t_}}:Q}
|
|
|
|
. endfor
|
2005-05-22 01:09:36 +02:00
|
|
|
. endif
|
|
|
|
. endfor
|
|
|
|
.endif
|