From 63bff33f35e5f6b5e148045a388df4845909e45f Mon Sep 17 00:00:00 2001 From: Dane Springmeyer Date: Fri, 16 May 2014 19:00:37 -0700 Subject: [PATCH] minor benchmark build tweaks to be consistent with master --- benchmark/build.py | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/benchmark/build.py b/benchmark/build.py index 5a7db1f4e..ca2eb7f30 100644 --- a/benchmark/build.py +++ b/benchmark/build.py @@ -8,19 +8,16 @@ test_env = env.Clone() test_env['LIBS'] = copy(env['LIBMAPNIK_LIBS']) test_env.AppendUnique(LIBS='mapnik') -#test_env.AppendUnique(LIBS='sqlite3') test_env.AppendUnique(CXXFLAGS='-g') -linkflags = copy(env['CUSTOM_LDFLAGS']) -linkflags +if 'g++' in env['CXX']: + test_env.Append(CXXFLAGS='-fPIC') if env['PLATFORM'] == 'Darwin': - linkflags += ' -F/ -framework CoreFoundation' + test_env.Append(LINKFLAGS='-F/ -framework CoreFoundation') -for cpp_test in glob.glob('run*.cpp'): - name = cpp_test.replace('.cpp','') - source_files = [cpp_test] - test_env_local = test_env.Clone() - test_program = test_env_local.Program(name, source=source_files, LINKFLAGS=linkflags) - Depends(test_program, env.subst('../src/%s' % env['MAPNIK_LIB_NAME'])) - # build locally if installing +test_env_local = test_env.Clone() + +for cpp_test in glob.glob('*cpp'): + test_program = test_env_local.Program('out/'+cpp_test.replace('.cpp',''), source=[cpp_test]) if 'install' in COMMAND_LINE_TARGETS: env.Alias('install',test_program) + #Depends(test_program, env.subst('../src/%s' % env['MAPNIK_LIB_NAME']))