Module Name: src
Committed By: martin
Date: Sun Jun 28 09:28:46 UTC 2015
Modified Files:
src/etc/mtree: Makefile
Log Message:
Guard a few $MK... != "no" tests by an additional defined(MK...) clause
and make the emit_dist_file target depend on EXTRA_DIST_FILES.
Part of fixing PR toolchain/50004.
To generate a diff of this commit:
cvs rdiff -u -r1.27 -r1.28 src/etc/mtree/Makefile
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/etc/mtree/Makefile
diff -u src/etc/mtree/Makefile:1.27 src/etc/mtree/Makefile:1.28
--- src/etc/mtree/Makefile:1.27 Sat Jun 27 20:34:11 2015
+++ src/etc/mtree/Makefile Sun Jun 28 09:28:46 2015
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.27 2015/06/27 20:34:11 matt Exp $
+# $NetBSD: Makefile,v 1.28 2015/06/28 09:28:46 martin Exp $
.include <bsd.own.mk>
@@ -12,7 +12,7 @@ EXTRA_DIST_FILES= ${.CURDIR}/NetBSD.dist
# XXX these are only used by compat currently, but they could be used
# by something else; this may need to be fixed properly in the future.
-.if ${MKCOMPAT} != "no"
+.if defined(MKCOMPAT) && ${MKCOMPAT} != "no"
.include "${NETBSDSRCDIR}/compat/archdirs.mk"
.if exists(NetBSD.dist.${MACHINE_ARCH})
EXTRA_DIST_FILES+= ${.CURDIR}/NetBSD.dist.${MACHINE_ARCH}
@@ -20,14 +20,15 @@ EXTRA_DIST_FILES+= ${.CURDIR}/NetBSD.dis
EXTRA_DIST_FILES+= ${.CURDIR}/NetBSD.dist.earm
.endif
EXTRA_DIST_FILES+= NetBSD.dist.compat # autogenerated
-.if ${MKCOMPATX11} != "no" && ${MKX11} != "no" && ${X11FLAVOUR} == "Xorg"
+.if defined(MKCOMPATX11) && ${MKCOMPATX11} != "no" && ${MKX11} != "no" \
+ && ${X11FLAVOUR} == "Xorg"
EXTRA_DIST_FILES+= NetBSD.dist.xcompat # autogenerated
.endif
.endif
.if ${MKATF} != "no"
EXTRA_DIST_FILES+= ${.CURDIR}/NetBSD.dist.tests
-.if ${MKCOMPATTESTS} != "no"
+.if defined(MKCOMPATTESTS) && ${MKCOMPATTESTS} != "no"
EXTRA_DIST_FILES+= NetBSD.dist.tests.compat
.endif
.endif
@@ -83,7 +84,7 @@ TOOL_MTREE.unpriv= -W
# /etc/mtree/NetBSD.dist content without duplicating logic from
# the Makefile.
#
-emit_dist_file:
+emit_dist_file: ${EXTRA_DIST_FILES}
@cat ${.CURDIR}/NetBSD.dist.base ${EXTRA_DIST_FILES}
distrib-dirs: .PHONY check_DESTDIR NetBSD.dist