aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--share/mk/Makefile6
1 files changed, 6 insertions, 0 deletions
diff --git a/share/mk/Makefile b/share/mk/Makefile
index d8aea5c5547e..eaa8e0f82867 100644
--- a/share/mk/Makefile
+++ b/share/mk/Makefile
@@ -1,6 +1,11 @@
# $FreeBSD$
# @(#)Makefile 8.1 (Berkeley) 6/8/93
+# Only parse this if executing make in this directory, not in other places
+# in src that lack a Makefile, such as sys/dev/*. Otherwise the MAKESYSPATH
+# will read this Makefile since it auto includes it into -I.
+.if ${.CURDIR} == ${.PARSEDIR}
+
.include <src.opts.mk>
FILES= \
@@ -63,3 +68,4 @@ FILES+= tap.test.mk
.endif
.include <bsd.prog.mk>
+.endif # CURDIR == PARSEDIR