Print this page
10063 basic support for smatch
10153 checkpaths shouldn't check packaging exceptions

@@ -79,10 +79,13 @@
 # To disable shadow compilation, unset SHADOW_* or set them to the empty string.
 #
 export SHADOW_CCS=gcc7,/usr/gcc/7/bin/gcc,gnu
 export SHADOW_CCCS=gcc7,/usr/gcc/7/bin/g++,gnu
 
+# uncomment to enable smatch
+#export ENABLE_SMATCH=1
+
 # Comment this out to disable support for SMB printing, i.e. if you
 # don't want to bother providing the CUPS headers this needs.
 export ENABLE_SMB_PRINTING=
 
 # If your distro uses certain versions of Perl, make sure either Makefile.master

@@ -271,5 +274,10 @@
 #export LINTDIRS="$SRC y"
 
 # Set this flag to 'n' to disable the use of 'checkpaths'.  The default,
 # if the 'N' option is not specified, is to run this test.
 #CHECK_PATHS='y'
+
+if [[ "$ENABLE_SMATCH" = "1" ]]; then
+        SMATCHBIN=$CODEMGR_WS/usr/src/tools/proto/root_$MACH-nd/opt/onbld/bin/$MACH/smatch
+        export SHADOW_CCS="$SHADOW_CCS smatch,$SMATCHBIN,smatch"
+fi