scons: add an option to turn on XML spirit debug output in addition to debug mode (note earlier commit added part of this patch http://trac.mapnik.org/changeset/1027/trunk/include/mapnik/filter_parser.hpp) - closes #150

This commit is contained in:
Dane Springmeyer 2009-04-01 03:31:24 +00:00
parent 72734cbda5
commit 08669a08fb
2 changed files with 8 additions and 0 deletions

View file

@ -101,6 +101,7 @@ opts.AddVariables(
EnumVariable('OPTIMIZATION','Set g++ optimization level','2', ['0','1','2','3']),
# Note: setting DEBUG=True will override any custom OPTIMIZATION level
BoolVariable('DEBUG', 'Compile a debug version of Mapnik', 'False'),
BoolVariable('XML_DEBUG', 'Compile a XML verbose debug version of mapnik', 'False'),
ListVariable('INPUT_PLUGINS','Input drivers to include',DEFAULT_PLUGINS,PLUGINS.keys()),
# SCons build behavior options
@ -449,6 +450,9 @@ if not preconfigured:
else:
mode = 'release mode'
if env['XML_DEBUG']:
mode += ' (with XML debug on)'
env['PLATFORM'] = platform.uname()[0]
color_print (4,"Configuring on %s in *%s*..." % (env['PLATFORM'],mode))
@ -739,6 +743,9 @@ if not preconfigured:
debug_flags = '-g -DDEBUG -DMAPNIK_DEBUG'
ndebug_flags = '-DNDEBUG'
if env['XML_DEBUG']:
common_cxx_flags += '-DMAPNIK_XML_DEBUG '
# Customizing the C++ compiler flags depending on:
# (1) the C++ compiler used; and
# (2) whether debug binaries are requested.

View file

@ -38,6 +38,7 @@
// boost
// XML Debugging output
#ifdef MAPNIK_XML_DEBUG
#define BOOST_SPIRIT_DEBUG
#endif