aboutsummaryrefslogtreecommitdiff
path: root/share/mk
diff options
context:
space:
mode:
authorRui Paulo <rpaulo@FreeBSD.org>2010-09-10 17:44:11 +0000
committerRui Paulo <rpaulo@FreeBSD.org>2010-09-10 17:44:11 +0000
commit51ccb83a3923175922a8abde93fb985e719f71e2 (patch)
tree573688ddfb862174b7aa1185b3d3f78ef4b04f9f /share/mk
parent9feea9c1f41f12d8c656962ed9cb19b0082e30ac (diff)
downloadsrc-51ccb83a3923175922a8abde93fb985e719f71e2.tar.gz
src-51ccb83a3923175922a8abde93fb985e719f71e2.zip
Fix bugs introduced in the previous rev:
* add a phatom target for the DTRACEOBJS * when invoking DTrace, don't add DTRACEOBJS to the command line. Sponsored by: The FreeBSD Foundation
Notes
Notes: svn path=/head/; revision=212428
Diffstat (limited to 'share/mk')
-rw-r--r--share/mk/bsd.dtrace.mk14
1 files changed, 9 insertions, 5 deletions
diff --git a/share/mk/bsd.dtrace.mk b/share/mk/bsd.dtrace.mk
index bc4d90679903..bebe969ccf10 100644
--- a/share/mk/bsd.dtrace.mk
+++ b/share/mk/bsd.dtrace.mk
@@ -37,19 +37,23 @@ CFLAGS+=-DWITH_DTRACE
DTRACEHEADERS=${DTRACEOBJS:S/o$/h/}
DTRACESRCS=${DTRACEOBJS:S/o$/d/}
CLEANFILES+=${DTRACEOBJS} ${DTRACEHEADERS}
+
+DPADD+=${LIBELF}
+LDADD+=-lelf
+
.if defined(PROG)
-_DTRACELINKING:=${OBJS}
+_DTRACELINKING=${OBJS}
OBJS+=${DTRACEOBJS}
.else
-_DTRACELINKING:=${SOBJS}
+_DTRACELINKING=${SOBJS}
SOBJS+=${DTRACEOBJS}
.endif
-DPADD+=${LIBELF}
-LDADD+=-lelf
+
+${DTRACEOBJS}:
beforedepend:
${DTRACE} -C -h -s ${DTRACESRCS}
beforelinking:
- ${DTRACE} -G -s ${DTRACESRCS} ${_DTRACELINKING}
+ ${DTRACE} -G -s ${DTRACESRCS} ${_DTRACELINKING:S/${DTRACEOBJS}//}
.endif