summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc Espie <espie@cvs.openbsd.org>2003-10-28 17:09:34 +0000
committerMarc Espie <espie@cvs.openbsd.org>2003-10-28 17:09:34 +0000
commitb60ec40f73eb69dff7c535e1866b540488e9a7f6 (patch)
treea27884cbc248436685875d71315f79bdab0de693
parenta64e99aa2d2367702479964f5f1f19f67e8bff35 (diff)
indent tests for readability.
actually declare a _SUBDIRUSE target. (this allows one to just include bsd.obj.mk if bsd.subdir.mk is not actually needed, or to include bsd.obj.mk and bsd.subdir.mk in any order) okay millert@
-rw-r--r--share/mk/bsd.obj.mk34
1 files changed, 18 insertions, 16 deletions
diff --git a/share/mk/bsd.obj.mk b/share/mk/bsd.obj.mk
index 5d895f4e099..83f48886ee2 100644
--- a/share/mk/bsd.obj.mk
+++ b/share/mk/bsd.obj.mk
@@ -1,34 +1,36 @@
-# $OpenBSD: bsd.obj.mk,v 1.11 1997/08/22 14:52:11 flipk Exp $
+# $OpenBSD: bsd.obj.mk,v 1.12 2003/10/28 17:09:33 espie Exp $
# $NetBSD: bsd.obj.mk,v 1.9 1996/04/10 21:08:05 thorpej Exp $
.if !target(obj)
-.if defined(NOOBJ)
+. if defined(NOOBJ)
obj:
-.else
+. else
-.if defined(MAKEOBJDIR)
+. if defined(MAKEOBJDIR)
__baseobjdir= ${MAKEOBJDIR}
-.else
+. else
__baseobjdir= obj
-.endif
+. endif
-.if defined(OBJMACHINE)
+. if defined(OBJMACHINE)
__objdir= ${__baseobjdir}.${MACHINE}
-.else
+. else
__objdir= ${__baseobjdir}
-.endif
+. endif
-.if defined(USR_OBJMACHINE)
+. if defined(USR_OBJMACHINE)
__usrobjdir= ${BSDOBJDIR}.${MACHINE}
__usrobjdirpf=
-.else
+. else
__usrobjdir= ${BSDOBJDIR}
-.if defined(OBJMACHINE)
+. if defined(OBJMACHINE)
__usrobjdirpf= .${MACHINE}
-.else
+. else
__usrobjdirpf=
-.endif
-.endif
+. endif
+. endif
+
+_SUBDIRUSE:
obj! _SUBDIRUSE
@cd ${.CURDIR}; \
@@ -56,5 +58,5 @@ obj! _SUBDIRUSE
mkdir $$dest; \
fi ; \
fi;
-.endif
+. endif
.endif