svn commit: r268300 - head/share/mk

Rui Paulo rpaulo at FreeBSD.org
Sat Jul 5 20:08:35 UTC 2014


Author: rpaulo
Date: Sat Jul  5 20:08:35 2014
New Revision: 268300
URL: http://svnweb.freebsd.org/changeset/base/268300

Log:
  bsd.dep.mk: add support for generating DTrace header files from .d files.
  
  MFC after:	3 weeks

Modified:
  head/share/mk/bsd.dep.mk

Modified: head/share/mk/bsd.dep.mk
==============================================================================
--- head/share/mk/bsd.dep.mk	Sat Jul  5 20:08:25 2014	(r268299)
+++ head/share/mk/bsd.dep.mk	Sat Jul  5 20:08:35 2014	(r268300)
@@ -78,6 +78,7 @@ ${_S:R}.o: ${_S}
 .endfor
 .endif
 
+# Lexical analyzers
 .for _LSRC in ${SRCS:M*.l:N*/*}
 .for _LC in ${_LSRC:R}.c
 ${_LC}: ${_LSRC}
@@ -90,6 +91,7 @@ CLEANFILES+= ${_LC}
 .endfor
 .endfor
 
+# Yacc grammars
 .for _YSRC in ${SRCS:M*.y:N*/*}
 .for _YC in ${_YSRC:R}.c
 SRCS:=	${SRCS:S/${_YSRC}/${_YC}/}
@@ -117,6 +119,16 @@ ${_YC:R}.o: ${_YC}
 .endif
 .endfor
 .endfor
+
+# DTrace probe definitions
+.for _DSRC in ${SRCS:M*.d:N*/*}
+.for _DH in ${_DSRC:R}.h
+${_DH}: ${_DSRC}
+	${DTRACE} -xnolibs -h -s ${.ALLSRC} 
+SRCS:=	${SRCS:S/${_DSRC}/${_DH}/}
+CLEANFILES+= ${_DH}
+.endfor
+.endfor
 .endif
 
 .if !target(depend)


More information about the svn-src-head mailing list