make libxml2 optional dependency (XMLPARSER=libxml2)
This commit is contained in:
parent
f8fd60dc69
commit
ffcacf3509
2 changed files with 14 additions and 13 deletions
|
@ -1266,8 +1266,9 @@ if not preconfigured:
|
|||
|
||||
# libxml2 should be optional but is currently not
|
||||
# https://github.com/mapnik/mapnik/issues/913
|
||||
if env.get('XMLPARSER') and env['XMLPARSER'] == 'libxml2':
|
||||
if env.get('XML2_LIBS') or env.get('XML2_INCLUDES'):
|
||||
REQUIRED_LIBSHEADERS.insert(0,['libxml2','libxml/parser.h',True,'C'])
|
||||
OPTIONAL_LIBSHEADERS.insert(0,['libxml2','libxml/parser.h',True,'C'])
|
||||
if env.get('XML2_INCLUDES'):
|
||||
inc_path = env['XML2_INCLUDES']
|
||||
env.AppendUnique(CPPPATH = fix_path(inc_path))
|
||||
|
|
|
@ -84,7 +84,7 @@ if '-DHAVE_WEBP' in env['CPPDEFINES']:
|
|||
lib_env['LIBS'].append('webp')
|
||||
enabled_imaging_libraries.append('webp_reader.cpp')
|
||||
|
||||
lib_env['LIBS'].append('xml2')
|
||||
if '-DHAVE_LIBXML2' in env['CPPDEFINES'] : lib_env['LIBS'].append('xml2')
|
||||
|
||||
if '-DBOOST_REGEX_HAS_ICU' in env['CPPDEFINES']:
|
||||
lib_env['LIBS'].append('icui18n')
|
||||
|
|
Loading…
Reference in a new issue