Fix LUA_R_INCL not being used on linux

This commit is contained in:
mniip 2015-03-06 00:12:56 +03:00
parent 84f6ede2b8
commit 1eb8940c9a

View File

@ -268,15 +268,16 @@ def findLibs(env, conf):
if not conf.CheckLib(['lua5.1', 'lua-5.1', 'lua51', 'lua']):
if platform != "Darwin" or not conf.CheckFramework("Lua"):
FatalError("lua5.1 development library not found or not installed")
foundpkg = False
if platform == "Linux":
try:
env.ParseConfig("pkg-config --cflags {0}".format(luaver))
env.ParseConfig("pkg-config --libs {0}".format(luaver))
env.Append(CPPDEFINES=["LUA_R_INCL"])
foundpkg = True
except:
pass
else:
if not foundpkg:
#Look for lua.h
foundheader = False
if GetOption('luajit'):