summaryrefslogtreecommitdiffstats
path: root/cddl
diff options
context:
space:
mode:
authorjb <jb@FreeBSD.org>2008-05-22 23:06:19 +0000
committerjb <jb@FreeBSD.org>2008-05-22 23:06:19 +0000
commitb64f9e972e44459a0eea5a3726f39f8f7e716956 (patch)
treee5a0ec293f1d7736d21aa45a111331d77e9eb26f /cddl
parentd352221a97ec5e2b130c03a430e8870d333c2447 (diff)
downloadFreeBSD-src-b64f9e972e44459a0eea5a3726f39f8f7e716956.zip
FreeBSD-src-b64f9e972e44459a0eea5a3726f39f8f7e716956.tar.gz
Add the dtrace client app to the build.
Diffstat (limited to 'cddl')
-rw-r--r--cddl/usr.sbin/Makefile3
-rw-r--r--cddl/usr.sbin/dtrace/Makefile37
2 files changed, 39 insertions, 1 deletions
diff --git a/cddl/usr.sbin/Makefile b/cddl/usr.sbin/Makefile
index 5d1cea3..06c6894 100644
--- a/cddl/usr.sbin/Makefile
+++ b/cddl/usr.sbin/Makefile
@@ -2,7 +2,8 @@
.include <bsd.own.mk>
-SUBDIR= ${_zdb}
+SUBDIR= dtrace \
+ ${_zdb}
.if ${MK_ZFS} != "no"
.if ${MK_LIBTHR} != "no"
diff --git a/cddl/usr.sbin/dtrace/Makefile b/cddl/usr.sbin/dtrace/Makefile
new file mode 100644
index 0000000..44116fc
--- /dev/null
+++ b/cddl/usr.sbin/dtrace/Makefile
@@ -0,0 +1,37 @@
+# $FreeBSD$
+
+.include "../../Makefile.inc"
+
+PROG= dtrace
+
+BINDIR?= /usr/sbin
+
+SRCS= dtrace.c
+
+WARNS= 1
+
+CFLAGS+= -I${.CURDIR}/../../../sys/cddl/compat/opensolaris \
+ -I${.CURDIR}/../../../cddl/compat/opensolaris/include \
+ -I${OPENSOLARIS_USR_DISTDIR}/head \
+ -I${OPENSOLARIS_USR_DISTDIR}/lib/libdtrace/common \
+ -I${OPENSOLARIS_USR_DISTDIR}/lib/libproc/common \
+ -I${OPENSOLARIS_SYS_DISTDIR}/uts/common \
+ -I${OPENSOLARIS_SYS_DISTDIR}/compat
+
+.PATH: ${OPENSOLARIS_USR_DISTDIR}/cmd/dtrace
+
+# Optional debugging stuff...
+#CFLAGS+= -DNEED_ERRLOC
+#YFLAGS+= -d
+
+LDFLAGS+= -pthread \
+ -L${.OBJDIR}/../../lib/libdtrace \
+ -L${.OBJDIR}/../../lib/libproc \
+ -L${.OBJDIR}/../../lib/libctf \
+ -L${.OBJDIR}/../../../lib/libelf
+
+LDADD+= -ldtrace -ly -ll -lproc -lctf -lelf -lz
+
+DPADD+= ${LIBDTRACE} ${LIBCTF} ${LIBELF} ${LIBPTHREAD} ${LIBL} ${LIBY} ${LIBZ}
+
+.include <bsd.prog.mk>
OpenPOWER on IntegriCloud