summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2010-11-27 21:26:10 (GMT)
committerRemko Tronçon <git@el-tramo.be>2010-11-27 21:26:10 (GMT)
commit48ffe88bf768fd762a3bcb52717a9079ec803de5 (patch)
tree57c49fe3ba8b95f193bf1431d8ba819a4981b0ad /Swiften/SConscript
parent51517e2adaed04a10709f24c31138e7c2b60d4d8 (diff)
downloadswift-contrib-48ffe88bf768fd762a3bcb52717a9079ec803de5.zip
swift-contrib-48ffe88bf768fd762a3bcb52717a9079ec803de5.tar.bz2
Introduce SWIFTEN_DEP_FLAGS.
Diffstat (limited to 'Swiften/SConscript')
-rw-r--r--Swiften/SConscript23
1 files changed, 19 insertions, 4 deletions
diff --git a/Swiften/SConscript b/Swiften/SConscript
index 335dfa5..e81309e 100644
--- a/Swiften/SConscript
+++ b/Swiften/SConscript
@@ -7,10 +7,25 @@ Import("env")
################################################################################
if env["SCONS_STAGE"] == "flags" :
- env["SWIFTEN_FLAGS"] = {
- "LIBPATH": [Dir(".")],
- "LIBS": ["Swiften"]
- }
+ swiften_env = env.Clone()
+ swiften_env["LIBPATH"] = [Dir(".")]
+ swiften_env["LIBS"] = ["Swiften"]
+ dep_env = env.Clone()
+ dep_env.MergeFlags(dep_env["PLATFORM_FLAGS"])
+ for module in ["BOOST", "LIBIDN", "ZLIB", "OPENSSL", "LIBXML", "EXPAT"] :
+ if env.get(module + "_BUNDLED", False) :
+ swiften_env.MergeFlags(env.get(module + "_FLAGS", {}))
+ else :
+ dep_env.MergeFlags(env.get(module + "_FLAGS", {}))
+
+ for var, e in [("SWIFTEN_FLAGS", swiften_env), ("SWIFTEN_DEP_FLAGS", dep_env)] :
+ env[var] = {
+ "CPPDEFINES": e.get("CPPDEFINES", []),
+ "CPPPATH": e.get("CPPPATH", []),
+ "CPPFLAGS": e.get("CPPFLAGS", []),
+ "LIBPATH": e.get("LIBPATH", []),
+ "LIBS": e.get("LIBS", []),
+ }
################################################################################
# Build