From 54fc74b0d831a63e713340ffb8dc2056407f6adc Mon Sep 17 00:00:00 2001 From: punkrockguy318 Date: Fri, 21 Oct 2011 02:34:45 +0000 Subject: [PATCH] scons: dont pass -llua to linker if lua cannot be found --- SConstruct | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/SConstruct b/SConstruct index d6567607..0277d8d8 100644 --- a/SConstruct +++ b/SConstruct @@ -98,7 +98,8 @@ else: # If we're POSIX, we use LUA_USE_LINUX since that combines usual lua posix defines with dlfcn calls for dynamic library loading. # Should work on any *nix env.Append(CCFLAGS = ["-DLUA_USE_LINUX"]) - env.Append(LINKFLAGS = ["-ldl", "-llua"]) + if conf.CheckLib('lua'): + env.Append(LINKFLAGS = ["-ldl", "-llua"]) ### Search for gd if we're not in Windows if env['PLATFORM'] != 'win32' and env['PLATFORM'] != 'cygwin' and env['CREATE_AVI'] and env['LOGO']: