Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Dec 2015 01:19:20 +0000 (UTC)
From:      Bryan Drewery <bdrewery@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r292239 - stable/10/share/mk
Message-ID:  <201512150119.tBF1JKNA023928@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bdrewery
Date: Tue Dec 15 01:19:19 2015
New Revision: 292239
URL: https://svnweb.freebsd.org/changeset/base/292239

Log:
  Add SRCTOP and RELDIR support.
  
  This is a direct commit to stable/10.  It allows simpler MFCing from head where
  these are being used more frequently.
  
  Sponsored by:	EMC / Isilon Storage Division

Added:
  stable/10/share/mk/local.sys.mk   (contents, props changed)

Added: stable/10/share/mk/local.sys.mk
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/10/share/mk/local.sys.mk	Tue Dec 15 01:19:19 2015	(r292239)
@@ -0,0 +1,13 @@
+# $FreeBSD$
+
+.if defined(.PARSEDIR)
+SRCTOP:= ${.PARSEDIR:tA:H:H}
+.else
+SRCTOP:= ${.MAKE.MAKEFILES:M*/local.sys.mk:H:H:H}
+.endif
+
+.if ${.CURDIR} == ${SRCTOP}
+RELDIR = .
+.elif ${.CURDIR:M${SRCTOP}/*}
+RELDIR := ${.CURDIR:S,${SRCTOP}/,,}
+.endif



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201512150119.tBF1JKNA023928>