summaryrefslogtreecommitdiffstats
path: root/Sluift
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2011-02-26 18:07:32 (GMT)
committerRemko Tronçon <git@el-tramo.be>2011-02-26 18:08:01 (GMT)
commitd375363472a5a4fb1f59b6e695d5c68db14d97fd (patch)
treee07529caf8f07c7043c9b38e9fb690398243dbdb /Sluift
parent15e91f62a93c1cba6b7a36828837c69759ea8d46 (diff)
downloadswift-contrib-d375363472a5a4fb1f59b6e695d5c68db14d97fd.zip
swift-contrib-d375363472a5a4fb1f59b6e695d5c68db14d97fd.tar.bz2
Patch Sluift console.
Diffstat (limited to 'Sluift')
-rw-r--r--Sluift/.gitignore1
-rw-r--r--Sluift/SConscript12
2 files changed, 12 insertions, 1 deletions
diff --git a/Sluift/.gitignore b/Sluift/.gitignore
index d6ff3b9..e343aca 100644
--- a/Sluift/.gitignore
+++ b/Sluift/.gitignore
@@ -1,2 +1,3 @@
lua.c
+sluift_dll.cpp
sluift
diff --git a/Sluift/SConscript b/Sluift/SConscript
index 3a7d32f..1e36b6e 100644
--- a/Sluift/SConscript
+++ b/Sluift/SConscript
@@ -12,8 +12,18 @@ if env["SCONS_STAGE"] == "build" :
elif myenv["PLATFORM"] == "darwin" :
myenv["SHLIBSUFFIX"] = ".so"
+ def patchLua(env, target, source) :
+ f = open(source[0].abspath, "r")
+ contents = f.read()
+ f.close()
+ contents = contents.replace("LUA_RELEASE", "\"Sluift XMPP Console\"")
+ contents = contents.replace("LUA_COPYRIGHT", "")
+ f = open(target[0].abspath, "w")
+ f.write(contents)
+ f.close()
+
sluift_bin_env = myenv.Clone()
- sluift_bin_env.Install(".", "#/3rdParty/Lua/src/lua.c")
+ sluift_bin_env.Command("lua.c", ["#/3rdParty/Lua/src/lua.c"], env.Action(patchLua, cmdstr = "$GENCOMSTR"))
if sluift_bin_env.get("HAVE_READLINE", False) :
sluift_bin_env.Append(CPPDEFINES = ["LUA_USE_READLINE"])
sluift_bin_env.MergeFlags(sluift_bin_env["READLINE_FLAGS"])