1# $FreeBSD$ 2 3.include <src.opts.mk> 4 5.PATH: ${SRCTOP}/cddl/contrib/opensolaris/cmd/dtrace 6 7PACKAGE= dtrace 8PROG= dtrace 9SRCS= dtrace.c 10BINDIR?= /usr/sbin 11 12WARNS?= 1 13 14CFLAGS+= -DIN_BASE 15CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/include 16CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/ 17CFLAGS+= -I${SRCTOP}/sys/contrib/openzfs/lib/libspl/include/os/freebsd 18CFLAGS+= -I${SRCTOP}/sys 19CFLAGS+= -I${SRCTOP}/cddl/compat/opensolaris/include 20CFLAGS+= -I${SRCTOP}/sys/cddl/compat/opensolaris \ 21 -I${SRCTOP}/cddl/compat/opensolaris/include \ 22 -I${OPENSOLARIS_USR_DISTDIR}/head \ 23 -I${OPENSOLARIS_USR_DISTDIR}/lib/libdtrace/common \ 24 -I${OPENSOLARIS_USR_DISTDIR}/lib/libproc/common \ 25 -I${OPENSOLARIS_SYS_DISTDIR}/uts/common \ 26 -I${OPENSOLARIS_SYS_DISTDIR}/compat 27CFLAGS+= -DHAVE_ISSETUGID 28 29# Optional debugging stuff... 30#CFLAGS+= -DNEED_ERRLOC 31#YFLAGS+= -d 32 33.if ${MK_DTRACE_ASAN} != "no" 34CFLAGS+= -fsanitize=address -fsanitize=undefined 35LDFLAGS+= -fsanitize=address -fsanitize=undefined 36.endif 37 38LIBADD= dtrace ctf elf proc spl 39 40.if ${MK_DTRACE_TESTS} != "no" 41SUBDIR+= tests 42.endif 43 44.include <bsd.prog.mk> 45