summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2001-10-26 17:03:04 +0000
committerjlam <jlam@pkgsrc.org>2001-10-26 17:03:04 +0000
commit83a062506e02ebba79c3e05d3bc4b5a9691041b1 (patch)
treedf3d09fa2f101f4524f95eb147c76bd6cc4c3c84 /mk
parent2d3b50b92d64011daea12cea55bb7b1ff3ac4417 (diff)
downloadpkgsrc-83a062506e02ebba79c3e05d3bc4b5a9691041b1.tar.gz
If AUTOMAKE_OVERRIDE=YES then we touch files in ${WRKSRC} in such a way
that GNU autoconf/automake are not executed during the build process, even if the tools exist in the build environment. This prevents the build process from overwriting any changes made to the configure script or to the Makefile.in files.
Diffstat (limited to 'mk')
-rw-r--r--mk/bsd.pkg.mk26
1 files changed, 24 insertions, 2 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk
index c31403d791e..ab6aa798fab 100644
--- a/mk/bsd.pkg.mk
+++ b/mk/bsd.pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.834 2001/10/26 16:03:26 agc Exp $
+# $NetBSD: bsd.pkg.mk,v 1.835 2001/10/26 17:03:04 jlam Exp $
#
# This file is in the public domain.
#
@@ -1515,6 +1515,29 @@ do-libtool:
${_PKG_SILENT}${_PKG_DEBUG}${TRUE}
.endif
+.if defined(AUTOMAKE_OVERRIDE) && (${AUTOMAKE_OVERRIDE} == "YES")
+#
+# Prevent invocation of GNU "auto*" during the build process driven by the
+# generated Makefiles by touching various auto{conf,make} source files to
+# make them up-to-date.
+#
+AUTOMAKE_PATTERNS+= *.m4
+AUTOMAKE_PATTERNS+= *.in
+AUTOMAKE_PATTERNS+= configure
+_AUTOMAKE_PATTERNS_FIND= \
+ ${AUTOMAKE_PATTERNS:S/$/!/:S/^/-o -name !/:S/!/"/g:S/-o//1}
+
+_CONFIGURE_PREREQ+= suppress-automake
+suppress-automake:
+. if defined(HAS_CONFIGURE)
+ ${_PKG_SILENT}${_PKG_DEBUG} \
+ cd ${WRKSRC}; \
+ ${FIND} . ${_AUTOMAKE_PATTERNS_FIND} | ${XARGS} ${TOUCH} ${TOUCH_ARGS}
+. else
+ ${_PKG_SILENT}${_PKG_DEBUG}${TRUE}
+. endif
+.endif # AUTOMAKE_OVERRIDE
+
.if !target(do-configure)
do-configure: ${_CONFIGURE_PREREQ}
. if defined(HAS_CONFIGURE)
@@ -1527,7 +1550,6 @@ do-configure: ${_CONFIGURE_PREREQ}
INSTALL_PROGRAM="${INSTALL_PROGRAM}" \
INSTALL_SCRIPT="${INSTALL_SCRIPT}" \
${CONFIGURE_ENV} ${CONFIGURE_SCRIPT} ${CONFIGURE_ARGS}
-
. endif
. if defined(USE_IMAKE)
${_PKG_SILENT}${_PKG_DEBUG}cd ${WRKSRC} && ${SETENV} ${SCRIPTS_ENV} XPROJECTROOT=${X11BASE} ${XMKMF}