diff options
author | jlam <jlam@pkgsrc.org> | 2006-07-05 09:08:35 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2006-07-05 09:08:35 +0000 |
commit | 990d0b53771974e8526315776af82fd9b4961c14 (patch) | |
tree | 266445424a702f9333f761cfa65f977c42683645 /mk/configure | |
parent | e3b97d774b9eb87dcd011ba0aeca7f60d35eeb86 (diff) | |
download | pkgsrc-990d0b53771974e8526315776af82fd9b4961c14.tar.gz |
Make the check-vulnerable target more self-sufficient, by moving some
of the logic from fetch/fetch.mk into flavor/pkg/check.mk, so that
check-vulnerable can be used as a source target.
Make check-vulnerable a source target for every phase of the build
workflow, which ensures that it is always run if the user starts a
new phase from the command line.
Fix the cookie-generation targets so that they don't append, only
overwrite to the cookie file. This works around potential problems
due to recursive makes.
Move the cookie checks so that they surround the corresponding phase
target. The presence of the cookie should now inform the make process
to avoid doing any processing of phases that occur before the phase
corresponding to the cookie.
Diffstat (limited to 'mk/configure')
-rw-r--r-- | mk/configure/bsd.configure.mk | 4 | ||||
-rw-r--r-- | mk/configure/configure.mk | 13 |
2 files changed, 9 insertions, 8 deletions
diff --git a/mk/configure/bsd.configure.mk b/mk/configure/bsd.configure.mk index e90efd600d8..901954186fe 100644 --- a/mk/configure/bsd.configure.mk +++ b/mk/configure/bsd.configure.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.configure.mk,v 1.1 2006/07/05 06:09:15 jlam Exp $ +# $NetBSD: bsd.configure.mk,v 1.2 2006/07/05 09:08:35 jlam Exp $ # # This Makefile fragment is included by bsd.pkg.mk and provides all # variables and targets related to configuring packages for building. @@ -36,4 +36,4 @@ configure: patch configure-cookie .PHONY: configure-cookie configure-cookie: ${_PKG_SILENT}${_PKG_DEBUG}${MKDIR} ${_CONFIGURE_COOKIE:H} - ${_PKG_SILENT}${_PKG_DEBUG}${ECHO} ${PKGNAME} >> ${_CONFIGURE_COOKIE} + ${_PKG_SILENT}${_PKG_DEBUG}${ECHO} ${PKGNAME} > ${_CONFIGURE_COOKIE} diff --git a/mk/configure/configure.mk b/mk/configure/configure.mk index fe504e2bba4..fcf990e9e12 100644 --- a/mk/configure/configure.mk +++ b/mk/configure/configure.mk @@ -1,4 +1,4 @@ -# $NetBSD: configure.mk,v 1.1 2006/07/05 06:09:15 jlam Exp $ +# $NetBSD: configure.mk,v 1.2 2006/07/05 09:08:35 jlam Exp $ # # CONFIGURE_SCRIPT is the path to the script to run in order to # configure the software for building. If the path is relative, @@ -40,6 +40,7 @@ BUILD_DEFS+= CONFIGURE_ENV CONFIGURE_ARGS ###################################################################### ### configure is a public target to configure the sources for building. ### +_CONFIGURE_TARGETS+= check-vulnerable _CONFIGURE_TARGETS+= wrapper _CONFIGURE_TARGETS+= acquire-configure-lock _CONFIGURE_TARGETS+= ${_CONFIGURE_COOKIE} @@ -47,20 +48,20 @@ _CONFIGURE_TARGETS+= release-configure-lock .PHONY: configure .if !target(configure) +. if !exists(${_CONFIGURE_COOKIE}) configure: ${_CONFIGURE_TARGETS} +. else +configure: + @${DO_NADA} +. endif .endif .PHONY: acquire-configure-lock release-configure-lock acquire-configure-lock: acquire-lock release-configure-lock: release-lock -.if !exists(${_CONFIGURE_COOKIE}) ${_CONFIGURE_COOKIE}: ${_PKG_SILENT}${_PKG_DEBUG}cd ${.CURDIR} && ${SETENV} ${BUILD_ENV} ${MAKE} ${MAKEFLAGS} real-configure PKG_PHASE=configure || ${PKG_ERROR_HANDLER.configure} -.else -${_CONFIGURE_COOKIE}: - @${DO_NADA} -.endif PKG_ERROR_CLASSES+= configure PKG_ERROR_MSG.configure= \ |