From c5f01be4e2b69a3f11741beb6f9e4d32060cf4d4 Mon Sep 17 00:00:00 2001 From: Dane Springmeyer Date: Sun, 2 Jun 2013 14:54:27 -0700 Subject: [PATCH] only build cpp test if >= boost 1.47 --- tests/cpp_tests/geometry_converters_test.cpp | 22 +++++++++++--------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/tests/cpp_tests/geometry_converters_test.cpp b/tests/cpp_tests/geometry_converters_test.cpp index fb6241cdc..0a18b5096 100644 --- a/tests/cpp_tests/geometry_converters_test.cpp +++ b/tests/cpp_tests/geometry_converters_test.cpp @@ -1,5 +1,11 @@ #include +#include +#include +#include +#include +#include "utils.hpp" +#if BOOST_VERSION >= 104700 #include #include #include @@ -8,19 +14,9 @@ #include #include #include - -#if BOOST_VERSION >= 104700 #include #include #include -#endif - -#include -#include -#include -#include - -#include "utils.hpp" struct output_geometry_backend { @@ -125,6 +121,7 @@ boost::optional polygon_bbox_clipping(mapnik::box2d bbox, return boost::optional(); } +#endif int main(int argc, char** argv) { @@ -137,6 +134,8 @@ int main(int argc, char** argv) BOOST_TEST(set_working_dir(args)); +#if BOOST_VERSION >= 104700 + // LineString/bbox clipping { std::string wkt_in("LineString(0 0,200 200)"); @@ -174,6 +173,9 @@ int main(int argc, char** argv) BOOST_TEST_EQ(*result,std::string("Polygon((50 50,50 100,75 150,125 150,150 100,150 50,50 50))")); } #endif + +#endif + if (!::boost::detail::test_errors()) { if (quiet) std::clog << "\x1b[1;32m.\x1b[0m";