always link to boost system - closes #931
This commit is contained in:
parent
db87b41555
commit
d8f19fab05
4 changed files with 8 additions and 21 deletions
|
@ -425,7 +425,6 @@ pickle_store = [# Scons internal variables
|
||||||
'PYTHON_INSTALL_LOCATION',
|
'PYTHON_INSTALL_LOCATION',
|
||||||
'PYTHON_SYS_PREFIX',
|
'PYTHON_SYS_PREFIX',
|
||||||
'COLOR_PRINT',
|
'COLOR_PRINT',
|
||||||
'HAS_BOOST_SYSTEM',
|
|
||||||
'SVN_REVISION',
|
'SVN_REVISION',
|
||||||
'HAS_CAIRO',
|
'HAS_CAIRO',
|
||||||
'HAS_PYCAIRO',
|
'HAS_PYCAIRO',
|
||||||
|
@ -1126,18 +1125,14 @@ if not preconfigured:
|
||||||
|
|
||||||
conf.FindBoost(BOOST_SEARCH_PREFIXES,thread_flag)
|
conf.FindBoost(BOOST_SEARCH_PREFIXES,thread_flag)
|
||||||
|
|
||||||
# boost system is used in boost 1.35 and greater
|
|
||||||
env['HAS_BOOST_SYSTEM'] = False
|
|
||||||
boost_lib_version_from_header = conf.GetBoostLibVersion()
|
boost_lib_version_from_header = conf.GetBoostLibVersion()
|
||||||
if boost_lib_version_from_header:
|
if boost_lib_version_from_header:
|
||||||
boost_version_from_header = int(boost_lib_version_from_header.split('_')[1])
|
boost_version_from_header = int(boost_lib_version_from_header.split('_')[1])
|
||||||
if boost_version_from_header >= 35:
|
|
||||||
env['HAS_BOOST_SYSTEM'] = True
|
|
||||||
|
|
||||||
|
|
||||||
# The other required boost headers.
|
# The other required boost headers.
|
||||||
BOOST_LIBSHEADERS = [
|
BOOST_LIBSHEADERS = [
|
||||||
['system', 'boost/system/system_error.hpp', env['HAS_BOOST_SYSTEM']],
|
['system', 'boost/system/system_error.hpp', True],
|
||||||
['filesystem', 'boost/filesystem/operations.hpp', True],
|
['filesystem', 'boost/filesystem/operations.hpp', True],
|
||||||
['regex', 'boost/regex.hpp', True],
|
['regex', 'boost/regex.hpp', True],
|
||||||
['program_options', 'boost/program_options.hpp', False]
|
['program_options', 'boost/program_options.hpp', False]
|
||||||
|
|
|
@ -53,9 +53,11 @@ ABI_VERSION = env['ABI_VERSION']
|
||||||
|
|
||||||
filesystem = 'boost_filesystem%s' % env['BOOST_APPEND']
|
filesystem = 'boost_filesystem%s' % env['BOOST_APPEND']
|
||||||
regex = 'boost_regex%s' % env['BOOST_APPEND']
|
regex = 'boost_regex%s' % env['BOOST_APPEND']
|
||||||
|
system = 'boost_system%s' % env['BOOST_APPEND']
|
||||||
|
|
||||||
# clear out and re-set libs for this env
|
# clear out and re-set libs for this env
|
||||||
lib_env['LIBS'] = ['freetype','ltdl','png','tiff','z','jpeg','proj',env['ICU_LIB_NAME'],filesystem,regex]
|
lib_env['LIBS'] = ['freetype','ltdl','png','tiff','z','jpeg','proj',env['ICU_LIB_NAME'],filesystem,system,regex]
|
||||||
|
|
||||||
|
|
||||||
if len(env['EXTRA_FREETYPE_LIBS']):
|
if len(env['EXTRA_FREETYPE_LIBS']):
|
||||||
lib_env['LIBS'].extend(copy(env['EXTRA_FREETYPE_LIBS']))
|
lib_env['LIBS'].extend(copy(env['EXTRA_FREETYPE_LIBS']))
|
||||||
|
@ -67,8 +69,6 @@ lib_env['LIBS'].append('xml2')
|
||||||
if env['THREADING'] == 'multi':
|
if env['THREADING'] == 'multi':
|
||||||
lib_env['LIBS'].append('boost_thread%s' % env['BOOST_APPEND'])
|
lib_env['LIBS'].append('boost_thread%s' % env['BOOST_APPEND'])
|
||||||
|
|
||||||
if env['HAS_BOOST_SYSTEM']:
|
|
||||||
lib_env['LIBS'].append('boost_system%s' % env['BOOST_APPEND'])
|
|
||||||
|
|
||||||
|
|
||||||
if not env['RUNTIME_LINK'] == 'static':
|
if not env['RUNTIME_LINK'] == 'static':
|
||||||
|
|
|
@ -10,13 +10,9 @@ system = 'boost_system%s' % env['BOOST_APPEND']
|
||||||
regex = 'boost_regex%s' % env['BOOST_APPEND']
|
regex = 'boost_regex%s' % env['BOOST_APPEND']
|
||||||
|
|
||||||
libraries = [filesystem, 'mapnik2']
|
libraries = [filesystem, 'mapnik2']
|
||||||
|
libraries.append(env['ICU_LIB_NAME'])
|
||||||
if env['PLATFORM'] == 'Darwin':
|
libraries.append(regex)
|
||||||
libraries.append(env['ICU_LIB_NAME'])
|
libraries.append(system)
|
||||||
libraries.append(regex)
|
|
||||||
|
|
||||||
if env['HAS_BOOST_SYSTEM']:
|
|
||||||
libraries.append(system)
|
|
||||||
|
|
||||||
for cpp_test in glob.glob('path_element_test.cpp'):
|
for cpp_test in glob.glob('path_element_test.cpp'):
|
||||||
env.Program(cpp_test.replace('.cpp',''), [cpp_test], CPPPATH=headers, LIBS=libraries)
|
env.Program(cpp_test.replace('.cpp',''), [cpp_test], CPPPATH=headers, LIBS=libraries)
|
|
@ -38,12 +38,8 @@ headers = ['#plugins/input/shape'] + env['CPPPATH']
|
||||||
|
|
||||||
boost_program_options = 'boost_program_options%s' % env['BOOST_APPEND']
|
boost_program_options = 'boost_program_options%s' % env['BOOST_APPEND']
|
||||||
boost_filesystem = 'boost_filesystem%s' % env['BOOST_APPEND']
|
boost_filesystem = 'boost_filesystem%s' % env['BOOST_APPEND']
|
||||||
libraries = [boost_program_options, boost_filesystem]
|
|
||||||
|
|
||||||
boost_system = 'boost_system%s' % env['BOOST_APPEND']
|
boost_system = 'boost_system%s' % env['BOOST_APPEND']
|
||||||
|
libraries = [boost_program_options, boost_filesystem, boost_system]
|
||||||
if env['HAS_BOOST_SYSTEM']:
|
|
||||||
libraries.append(boost_system)
|
|
||||||
|
|
||||||
shapeindex = program_env.Program('shapeindex', source, CPPPATH=headers, LIBS=libraries, LINKFLAGS=env['CUSTOM_LDFLAGS'])
|
shapeindex = program_env.Program('shapeindex', source, CPPPATH=headers, LIBS=libraries, LINKFLAGS=env['CUSTOM_LDFLAGS'])
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue