From ad712272a3741d1ae8c50ab8c93609a49f4045e2 Mon Sep 17 00:00:00 2001 From: jacob1 Date: Wed, 20 Mar 2019 00:06:21 -0400 Subject: [PATCH] run curl-config on linux; remove hacks for detecting old mac compiler --- SConscript | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/SConscript b/SConscript index 8ebdfebf5..4baec2fe4 100644 --- a/SConscript +++ b/SConscript @@ -104,10 +104,8 @@ else: env = Environment(tools=['default'], ENV=os.environ) #attempt to automatically find cross compiler -if not tool and compilePlatform == "Linux" and compilePlatform != platform: - if platform == "Darwin": - crossList = ["i686-apple-darwin9", "i686-apple-darwin10"] - elif not GetOption('64bit'): +if not tool and compilePlatform == "Linux" and platform == "Windows" and compilePlatform != platform: + if not GetOption('64bit'): crossList = ["mingw32", "i686-w64-mingw32", "i386-mingw32msvc", "i486-mingw32msvc", "i586-mingw32msvc", "i686-mingw32msvc"] else: crossList = ["x86_64-w64-mingw32", "amd64-mingw32msvc"] @@ -129,10 +127,6 @@ if tool: env['STRIP'] = tool+'strip' if os.path.isdir("/usr/{0}/bin".format(tool[:-1])): env['ENV']['PATH'] = "/usr/{0}/bin:{1}".format(tool[:-1], os.environ['PATH']) - if platform == "Darwin": - sdlconfigpath = "/usr/lib/apple/SDKs/MacOSX10.5.sdk/usr/bin" - if os.path.isdir(sdlconfigpath): - env['ENV']['PATH'] = "{0}:{1}".format(sdlconfigpath, env['ENV']['PATH']) #copy environment variables because scons doesn't do this by default for var in ["CC","CXX","LD","LIBPATH","STRIP"]: @@ -336,6 +330,12 @@ def findLibs(env, conf): if not conf.CheckLib(['curl', 'libcurl']): FatalError("libcurl not found or not installed") + if platform == "Linux" or compilePlatform == "Linux" or platform == "FreeBSD": + if GetOption('static'): + env.ParseConfig("curl-config --static-libs") + else: + env.ParseConfig("curl-config --libs") + #Look for pthreads if not conf.CheckLib(['pthread', 'pthreadVC2']): FatalError("pthreads development library not found or not installed")