maintain boost 1.42/1.41 compatibility as lemexe appears to behave like no_skip with boost 1.42
This commit is contained in:
parent
8c8f303429
commit
04b7f5aa6f
2 changed files with 14 additions and 4 deletions
|
@ -189,6 +189,7 @@ SCONS_CONFIGURE_CACHE = 'config.cache'
|
|||
SCONF_TEMP_DIR = '.sconf_temp'
|
||||
# auto-search directories for boost libs/headers
|
||||
BOOST_SEARCH_PREFIXES = ['/usr/local','/opt/local','/sw','/usr',]
|
||||
BOOST_MIN_VERSION = '1.41'
|
||||
|
||||
|
||||
# Core plugin build configuration
|
||||
|
@ -852,11 +853,11 @@ if not preconfigured:
|
|||
BOOST_LIBSHEADERS.append(['thread', 'boost/thread/mutex.hpp', True])
|
||||
|
||||
# if the user is not setting custom boost configuration
|
||||
# enforce boost version greater than or equal to 1.43
|
||||
if not conf.CheckBoost('1.43'):
|
||||
color_print(1,'Boost version 1.43 or greater is requred')
|
||||
# enforce boost version greater than or equal to BOOST_MIN_VERSION
|
||||
if not conf.CheckBoost(BOOST_MIN_VERSION):
|
||||
color_print(1,'Boost version %s or greater is required' % BOOST_MIN_VERSION)
|
||||
if not env['BOOST_VERSION']:
|
||||
env['MISSING_DEPS'].append('boost version >=1.43')
|
||||
env['MISSING_DEPS'].append('boost version >=%s' % BOOST_MIN_VERSION)
|
||||
else:
|
||||
color_print(4,'Found boost lib version... %s' % boost_lib_version_from_header )
|
||||
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
#include <mapnik/expression_node.hpp>
|
||||
|
||||
// boost
|
||||
#include <boost/version.hpp>
|
||||
#include <boost/variant.hpp>
|
||||
#include <boost/shared_ptr.hpp>
|
||||
#include <boost/concept_check.hpp>
|
||||
|
@ -128,7 +129,11 @@ struct expression_grammar : qi::grammar<Iterator, expr_node(), space_type>
|
|||
using qi::_a;
|
||||
using qi::_b;
|
||||
using qi::_r1;
|
||||
#if BOOST_VERSION > 104200
|
||||
using qi::no_skip;
|
||||
#else
|
||||
using qi::lexeme;
|
||||
#endif
|
||||
using qi::_val;
|
||||
using qi::lit;
|
||||
using qi::int_;
|
||||
|
@ -213,7 +218,11 @@ struct expression_grammar : qi::grammar<Iterator, expr_node(), space_type>
|
|||
;
|
||||
|
||||
attr %= '[' >> +(char_ - ']') >> ']';
|
||||
#if BOOST_VERSION > 104200
|
||||
ustring %= '\'' >> no_skip[*~char_('\'')] >> '\'';
|
||||
#else
|
||||
ustring %= '\'' >> lexeme[*(char_-'\'')] >> '\'';
|
||||
#endif
|
||||
}
|
||||
|
||||
qi::real_parser<double, qi::strict_real_policies<double> > strict_double;
|
||||
|
|
Loading…
Reference in a new issue