diff options
author | agc <agc@pkgsrc.org> | 2001-10-26 14:09:59 +0000 |
---|---|---|
committer | agc <agc@pkgsrc.org> | 2001-10-26 14:09:59 +0000 |
commit | d52dd5005a19d883c718553fa7ad3116889f3246 (patch) | |
tree | b205911a0374704e6a0378d88ec3a73be474ef3f | |
parent | 9f28ffc95eb2a823929bb7a8d76e25aeff7c9805 (diff) | |
download | pkgsrc-d52dd5005a19d883c718553fa7ad3116889f3246.tar.gz |
At present, if there is a pre-<target> or post-<target> script in
the scripts/ directory, it will be run automatically as part of
the build process, by bsd.pkg.mk. There are now exactly 5 packages
in pkgsrc which use this facility, and yet, for every package build,
the existence of a script is checked by bsd.pkg.mk once before the
target is executed, and once afterwards. This incurs needless
overhead.
Move the separate pre- and post- script handling out of bsd.pkg.mk into
the individual package Makefiles, where it's much more obvious what is
happening, anyway.
-rw-r--r-- | comms/mgetty+sendfax/Makefile | 5 | ||||
-rw-r--r-- | devel/ldapsdk/Makefile | 8 | ||||
-rw-r--r-- | mail/mailagent/Makefile | 5 | ||||
-rw-r--r-- | mk/bsd.pkg.mk | 10 | ||||
-rw-r--r-- | parallel/glunix/Makefile | 8 | ||||
-rw-r--r-- | www/navigator3/Makefile | 5 |
6 files changed, 23 insertions, 18 deletions
diff --git a/comms/mgetty+sendfax/Makefile b/comms/mgetty+sendfax/Makefile index 7314209e672..a6a639b78c5 100644 --- a/comms/mgetty+sendfax/Makefile +++ b/comms/mgetty+sendfax/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.17 2001/09/27 23:17:50 jlam Exp $ +# $NetBSD: Makefile,v 1.18 2001/10/26 14:10:00 agc Exp $ # FreeBSD Id: Makefile,v 1.25 1998/07/16 06:44:37 vanilla Exp # @@ -24,6 +24,9 @@ MAKE_ENV+= MGETTY_CONFDIR=${MGETTY_CONFDIR} USE_BUILDLINK_ONLY= # defined +do-configure: + cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/configure + post-configure: ${SED} -e 's#$${INSTALL_DATA_DIR}#${INSTALL_DATA_DIR}#' \ -e 's#$${MGETTY_CONFDIR}#${MGETTY_CONFDIR}#' \ diff --git a/devel/ldapsdk/Makefile b/devel/ldapsdk/Makefile index c2507c79297..575bc0d66a4 100644 --- a/devel/ldapsdk/Makefile +++ b/devel/ldapsdk/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.5 2001/05/17 08:38:43 abs Exp $ +# $NetBSD: Makefile,v 1.6 2001/10/26 14:10:00 agc Exp $ DISTNAME= ldapsdk_12311998 PKGNAME= ldapsdk-12311998 @@ -15,12 +15,10 @@ USE_GMAKE= yes USE_PERL5= yes WRKSRC= ${WRKDIR}/mozilla -# -# empty target. scripts/pre-build does the actual work do-build: + cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/pre-build -# -# empty target. scripts/pre-install does the actual work do-install: + cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/pre-install .include "../../mk/bsd.pkg.mk" diff --git a/mail/mailagent/Makefile b/mail/mailagent/Makefile index 4b51f55c75c..3a3fe03a086 100644 --- a/mail/mailagent/Makefile +++ b/mail/mailagent/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.7 2001/04/08 00:24:55 itojun Exp $ +# $NetBSD: Makefile,v 1.8 2001/10/26 14:10:01 agc Exp $ # FreeBSD: ports/mail/mailagent/Makefile,v 1.28 1999/08/31 06:47:24 mharo Exp # @@ -33,6 +33,9 @@ pre-extract: ${ECHO} "Do not build mailagent as root or it won't pass the sanity tests."; \ ${FALSE}; fi +pre-configure: + cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/pre-configure + post-install: @${INSTALL_DATA_DIR} ${PREFIX}/share/examples/mailagent @${INSTALL_DATA_DIR} ${PREFIX}/share/examples/mailagent/misc diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk index c31e2291e6a..151489d979f 100644 --- a/mk/bsd.pkg.mk +++ b/mk/bsd.pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.mk,v 1.831 2001/10/26 13:57:58 skrll Exp $ +# $NetBSD: bsd.pkg.mk,v 1.832 2001/10/26 14:09:59 agc Exp $ # # This file is in the public domain. # @@ -1627,16 +1627,8 @@ _PORT_USE: .USE ${_PKG_SILENT}${_PKG_DEBUG}cd ${.CURDIR} && ${MAKE} ${MAKEFLAGS} install-depends DEPENDS_TARGET=${DEPENDS_TARGET} .endif ${_PKG_SILENT}${_PKG_DEBUG}cd ${.CURDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKEFLAGS} ${.TARGET:S/^real-/pre-/} - ${_PKG_SILENT}${_PKG_DEBUG}if [ -f ${SCRIPTDIR}/${.TARGET:S/^real-/pre-/} ]; then \ - cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} \ - ${SCRIPTDIR}/${.TARGET:S/^real-/pre-/}; \ - fi ${_PKG_SILENT}${_PKG_DEBUG}cd ${.CURDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKEFLAGS} ${.TARGET:S/^real-/do-/} ${_PKG_SILENT}${_PKG_DEBUG}cd ${.CURDIR} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKEFLAGS} ${.TARGET:S/^real-/post-/} - ${_PKG_SILENT}${_PKG_DEBUG}if [ -f ${SCRIPTDIR}/${.TARGET:S/^real-/post-/} ]; then \ - cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} \ - ${SCRIPTDIR}/${.TARGET:S/^real-/post-/}; \ - fi .if !make(real-fetch) \ && (!make(real-package) || !defined(PACKAGE_NOINSTALL)) ${_PKG_SILENT}${_PKG_DEBUG} \ diff --git a/parallel/glunix/Makefile b/parallel/glunix/Makefile index e0f5945d122..f3eb173351c 100644 --- a/parallel/glunix/Makefile +++ b/parallel/glunix/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.20 2001/09/27 23:18:34 jlam Exp $ +# $NetBSD: Makefile,v 1.21 2001/10/26 14:10:01 agc Exp $ DISTNAME= glunix-release-1-0a PKGNAME= glunix-1.0a @@ -46,6 +46,12 @@ USER_CMD= ${LOCALBASE}/sbin/user GROUP_CMD= ${LOCALBASE}/sbin/group .endif +pre-fetch: + cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/pre-fetch + +post-patch: + cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/post-patch + # the glunix group needs to exist before building. pre-configure: ${CP} ${FILESDIR}/Makefile-2 ${WRKSRC}/Makefile diff --git a/www/navigator3/Makefile b/www/navigator3/Makefile index fc9bb25e9dc..a088518e748 100644 --- a/www/navigator3/Makefile +++ b/www/navigator3/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.6 2001/09/14 04:00:25 jlam Exp $ +# $NetBSD: Makefile,v 1.7 2001/10/26 14:10:01 agc Exp $ DISTNAME= netscape-v304-export.x86-unknown-bsd PKGNAME= navigator3-3.04 @@ -22,6 +22,9 @@ USE_X11BASE= YES SCRIPTS_ENV+= MACHINE_ARCH=${MACHINE_ARCH} NO_BUILD= YES +pre-configure: + cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/configure + do-install: ${INSTALL_DATA_DIR} ${PREFIX}/share/netscape ${INSTALL_DATA_DIR} ${PREFIX}/share/netscape/nls |