Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

allow building against Mapnik 2.0.0 (10 of 81 tests will fail)

  • Loading branch information...
commit 8e5a8d329ec84597aa72a067a945ef3152189937 1 parent 8f17e83
@springmeyer springmeyer authored
View
7 src/mapnik_expression.hpp
@@ -6,8 +6,13 @@
#include <node_object_wrap.h>
// mapnik
-#include <mapnik/expression_node.hpp>
+#include <mapnik/version.hpp>
+#if MAPNIK_VERSION >= 200100
#include <mapnik/expression.hpp>
+#else
+#include <mapnik/filter_factory.hpp>
+#endif
+#include <mapnik/expression_node.hpp>
#include <mapnik/expression_string.hpp>
#include <mapnik/expression_evaluator.hpp>
View
20 src/mapnik_layer.cpp
@@ -9,8 +9,19 @@
#include <boost/make_shared.hpp>
// mapnik
+#include <mapnik/version.hpp>
#include <mapnik/layer.hpp>
+#if MAPNIK_VERSION <= 200000
+#define active isActive
+#define min_zoom getMinZoom
+#define max_zoom getMaxZoom
+#define queryable isQueryable
+#define active isActive
+#define visible isVisible
+#endif
+
+
Persistent<FunctionTemplate> Layer::constructor;
void Layer::Initialize(Handle<Object> target) {
@@ -268,3 +279,12 @@ Handle<Value> Layer::describe(const Arguments& args)
return scope.Close(description);
}
+
+#if MAPNIK_VERSION <= 200000
+#undef active
+#undef min_zoom
+#undef max_zoom
+#undef queryable
+#undef active
+#undef visible
+#endif
View
4 src/mapnik_map.cpp
@@ -14,7 +14,11 @@
#include <mapnik/map.hpp>
#include <mapnik/projection.hpp>
#include <mapnik/layer.hpp>
+#if MAPNIK_VERSION >= 200100
#include <mapnik/expression.hpp>
+#else
+#include <mapnik/filter_factory.hpp>
+#endif
#include <mapnik/image_util.hpp>
#include <mapnik/config_error.hpp>
#include <mapnik/load_map.hpp>

0 comments on commit 8e5a8d3

Please sign in to comment.
Something went wrong with that request. Please try again.