summaryrefslogtreecommitdiffstats
path: root/sys/modules/dtrace/dtrace
diff options
context:
space:
mode:
authoravg <avg@FreeBSD.org>2013-08-06 15:51:56 +0000
committeravg <avg@FreeBSD.org>2013-08-06 15:51:56 +0000
commita07c9d34c39b8316691600e021968b318b087434 (patch)
tree43da06fcd1bc6c1b678d5db8fc0a0a2cfcf19f6e /sys/modules/dtrace/dtrace
parentcd60e1fa27e6b6272254aba34a77694d9954788c (diff)
downloadFreeBSD-src-a07c9d34c39b8316691600e021968b318b087434.zip
FreeBSD-src-a07c9d34c39b8316691600e021968b318b087434.tar.gz
opensolaris code: translate INVARIANTS to DEBUG and ZFS_DEBUG
Do this by forcing inclusion of sys/cddl/compat/opensolaris/sys/debug_compat.h via -include option into all source files from OpenSolaris. Note that this -include option must always be after -include opt_global.h. Additionally, remove forced definition of DEBUG for some modules and fix their build without DEBUG. Also, meaning of DEBUG was overloaded to enable WITNESS support for some OpenSolaris (primarily ZFS) locks. Now this overloading is removed and that use of DEBUG is replaced with a new option OPENSOLARIS_WITNESS. MFC after: 17 days
Diffstat (limited to 'sys/modules/dtrace/dtrace')
-rw-r--r--sys/modules/dtrace/dtrace/Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/modules/dtrace/dtrace/Makefile b/sys/modules/dtrace/dtrace/Makefile
index e6aaba7..3299a1e 100644
--- a/sys/modules/dtrace/dtrace/Makefile
+++ b/sys/modules/dtrace/dtrace/Makefile
@@ -40,7 +40,7 @@ CFLAGS+= -I${.CURDIR}/../../../cddl/compat/opensolaris \
-I${.CURDIR}/../../../cddl/contrib/opensolaris/uts/common \
-I${.CURDIR}/../../.. -DDIS_MEM
-CFLAGS+= -DSMP -DDEBUG
+CFLAGS+= -DSMP
EXPORT_SYMS= dtrace_register \
dtrace_unregister \
@@ -50,6 +50,9 @@ dtrace_asm.o: assym.s
.include <bsd.kmod.mk>
+CFLAGS+= -include ${.CURDIR}/../../../cddl/compat/opensolaris/sys/debug_compat.h
+
CWARNFLAGS+= -Wno-parentheses
CWARNFLAGS+= -Wno-uninitialized
CWARNFLAGS+= -Wno-cast-qual
+CWARNFLAGS+= -Wno-unused
OpenPOWER on IntegriCloud