mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-07-31 05:30:23 +02:00
fix lua related compiling errors on windows
This commit is contained in:
33
SConscript
33
SConscript
@@ -178,19 +178,22 @@ if not GetOption("macosx"):
|
|||||||
|
|
||||||
|
|
||||||
# if lua is enabled try to parse the lua pgk-config, or the lua-dir option if given
|
# if lua is enabled try to parse the lua pgk-config, or the lua-dir option if given
|
||||||
|
|
||||||
if(GetOption("lua-dir")):
|
if not GetOption("nolua"):
|
||||||
if not conf.CheckCHeader(GetOption("lua-dir") + '/lua.h'):
|
if(GetOption("lua-dir")):
|
||||||
print "lua5.1 headers not found or not installed"
|
if not conf.CheckCHeader(GetOption("lua-dir") + '/lua.h'):
|
||||||
raise SystemExit(1)
|
print "lua5.1 headers not found or not installed"
|
||||||
|
raise SystemExit(1)
|
||||||
|
else:
|
||||||
|
env.Append(CPPPATH=[GetOption("lua-dir")])
|
||||||
else:
|
else:
|
||||||
env.Append(CPPPATH=[GetOption("lua-dir")])
|
try:
|
||||||
else:
|
env.ParseConfig('pkg-config --cflags lua5.1')
|
||||||
try:
|
except:
|
||||||
env.ParseConfig('pkg-config --cflags lua5.1')
|
#Check for Lua lib
|
||||||
except:
|
if not conf.CheckLib('lua5.1') and not conf.CheckLib('lua-5.1') and not conf.CheckLib('lua51') and not conf.CheckLib('lua'):
|
||||||
print "lua5.1 headers not found or not installed"
|
print "liblua5.1 not found or not installed"
|
||||||
raise SystemExit(1)
|
raise SystemExit(1)
|
||||||
|
|
||||||
# if fft is enabled try to parse its config, fail otherwise.
|
# if fft is enabled try to parse its config, fail otherwise.
|
||||||
|
|
||||||
@@ -216,12 +219,6 @@ if not GetOption("macosx"):
|
|||||||
print "bzip2 headers not found"
|
print "bzip2 headers not found"
|
||||||
raise SystemExit(1)
|
raise SystemExit(1)
|
||||||
|
|
||||||
#Check for Lua lib
|
|
||||||
if not GetOption("nolua"):
|
|
||||||
if not conf.CheckLib('lua5.1') and not conf.CheckLib('lua-5.1') and not conf.CheckLib('lua51') and not conf.CheckLib('lua'):
|
|
||||||
print "liblua not found or not installed"
|
|
||||||
raise SystemExit(1)
|
|
||||||
|
|
||||||
# finish the configuration
|
# finish the configuration
|
||||||
|
|
||||||
env = conf.Finish();
|
env = conf.Finish();
|
||||||
|
Reference in New Issue
Block a user