From 91221ac2563b301ccc3bd3dcec8bdf4dd1356e8d Mon Sep 17 00:00:00 2001
From: "Meredith L. Patterson" <mlp@thesmartpolitenerd.com>
Date: Tue, 19 Nov 2013 20:46:34 -0600
Subject: [PATCH] tweak SConstruct so that 'scan-build scons' works

---
 SConstruct | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/SConstruct b/SConstruct
index 623bc5d8..78090c3a 100644
--- a/SConstruct
+++ b/SConstruct
@@ -68,10 +68,15 @@ if GetOption("coverage"):
                LDFLAGS=["-fprofile-arcs", "-ftest-coverage"],
                LIBS=['gcov'])
 
+env["CC"] = os.getenv("CC") or env["CC"]
+env["CXX"] = os.getenv("CXX") or env["CXX"]
+
 if os.getenv("CC") == "clang" or env['PLATFORM'] == 'darwin':
     env.Replace(CC="clang",
                 CXX="clang++")
 
+env["ENV"].update(x for x in os.environ.items() if x[0].startswith("CCC_"))
+
 #rootpath = env['ROOTPATH'] = os.path.abspath('.')
 #env.Append(CPPPATH=os.path.join('#', "hammer"))
 
-- 
GitLab