aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rw-r--r--Makefile.inc111
2 files changed, 5 insertions, 8 deletions
diff --git a/Makefile b/Makefile
index eba5c1cfe9ee..a80dec9b3470 100644
--- a/Makefile
+++ b/Makefile
@@ -146,7 +146,7 @@ TGTS+= ${BITGTS}
PATH= /sbin:/bin:/usr/sbin:/usr/bin
MAKEOBJDIRPREFIX?= /usr/obj
-_MAKEOBJDIRPREFIX!= /usr/bin/env -i PATH=${PATH} ${MAKE} \
+_MAKEOBJDIRPREFIX!= /usr/bin/env -i PATH=${PATH} MK_AUTO_OBJ=no ${MAKE} \
${.MAKEFLAGS:MMAKEOBJDIRPREFIX=*} __MAKE_CONF=${__MAKE_CONF} \
-f /dev/null -V MAKEOBJDIRPREFIX dummy
.if !empty(_MAKEOBJDIRPREFIX)
diff --git a/Makefile.inc1 b/Makefile.inc1
index 6c744d8ab7f8..85e1a60876c3 100644
--- a/Makefile.inc1
+++ b/Makefile.inc1
@@ -179,9 +179,9 @@ OSRELDATE= 0
.endif
# Set VERSION for CTFMERGE to use via the default CTFFLAGS=-L VERSION.
-.if !defined(VERSION) && !make(showconfig)
-REVISION!= ${MAKE} -C ${SRCDIR}/release -V REVISION
-BRANCH!= ${MAKE} -C ${SRCDIR}/release -V BRANCH
+.if !defined(VERSION)
+REVISION!= MK_AUTO_OBJ=no ${MAKE} -C ${SRCDIR}/release -V REVISION
+BRANCH!= MK_AUTO_OBJ=no ${MAKE} -C ${SRCDIR}/release -V BRANCH
SRCRELDATE!= awk '/^\#define[[:space:]]*__FreeBSD_version/ { print $$3 }' \
${SRCDIR}/sys/sys/param.h
VERSION= FreeBSD ${REVISION}-${BRANCH:C/-p[0-9]+$//} ${TARGET_ARCH} ${SRCRELDATE}
@@ -229,14 +229,11 @@ _TARGET_CPUTYPE=${TARGET_CPUTYPE}
.else
_TARGET_CPUTYPE=dummy
.endif
-# Skip for showconfig as it is just wasted time and may invoke auto.obj.mk.
-.if !make(showconfig)
-_CPUTYPE!= MAKEFLAGS= CPUTYPE=${_TARGET_CPUTYPE} ${MAKE} \
+_CPUTYPE!= MK_AUTO_OBJ=no MAKEFLAGS= CPUTYPE=${_TARGET_CPUTYPE} ${MAKE} \
-f /dev/null -m ${.CURDIR}/share/mk -V CPUTYPE
.if ${_CPUTYPE} != ${_TARGET_CPUTYPE}
.error CPUTYPE global should be set with ?=.
.endif
-.endif
.if make(buildworld)
BUILD_ARCH!= uname -p
.if ${MACHINE_ARCH} != ${BUILD_ARCH}