diff --git a/geo/postgis/patches/patch-configure b/geo/postgis/patches/patch-configure new file mode 100644 index 00000000000..7a3ac381c44 --- /dev/null +++ b/geo/postgis/patches/patch-configure @@ -0,0 +1,12 @@ +$OpenBSD: patch-configure,v 1.1 2014/04/24 16:21:27 landry Exp $ +--- configure.orig Thu Apr 24 18:03:19 2014 ++++ configure Thu Apr 24 18:04:04 2014 +@@ -18376,7 +18376,7 @@ fi + + CPPFLAGS_SAVE="$CPPFLAGS" + CPPFLAGS="$JSON_CPPFLAGS" +-ac_fn_c_check_header_mongrel "$LINENO" "json/json.h" "ac_cv_header_json_json_h" "$ac_includes_default" ++ac_fn_c_check_header_mongrel "$LINENO" "json-c/json.h" "ac_cv_header_json_json_h" "$ac_includes_default" + if test "x$ac_cv_header_json_json_h" = x""yes; then : + HAVE_JSON=yes + fi diff --git a/geo/postgis/patches/patch-liblwgeom_lwin_geojson_c b/geo/postgis/patches/patch-liblwgeom_lwin_geojson_c new file mode 100644 index 00000000000..64e884f607d --- /dev/null +++ b/geo/postgis/patches/patch-liblwgeom_lwin_geojson_c @@ -0,0 +1,39 @@ +$OpenBSD: patch-liblwgeom_lwin_geojson_c,v 1.1 2014/04/24 16:21:27 landry Exp $ + +json_tokener.h had this at some point, then it got completely removed.. + +/** + * @b XXX do not use json_tokener_errors directly. + * After v0.10 this will be removed. + * + * See json_tokener_error_desc() instead. + */ +extern const char* json_tokener_errors[]; + +commit f9136f68520db4761f05810f97922900ba459f46 +Author: Eric Haszlakiewicz +Date: Sat Mar 22 21:41:24 2014 -0400 + +Make the json_tokener_errors array local. It has been deprecated for a while, and json_tokener_error_desc() should be used instead. +--- liblwgeom/lwin_geojson.c.orig Thu Feb 28 18:42:49 2013 ++++ liblwgeom/lwin_geojson.c Thu Apr 24 18:10:55 2014 +@@ -17,8 +17,8 @@ + + #ifdef HAVE_LIBJSON + +-#include +-#include ++#include ++#include + #include + + static void geojson_lwerror(char *msg, int error_code) +@@ -512,7 +512,7 @@ lwgeom_from_geojson(const char *geojson, char **srs) + if( jstok->err != json_tokener_success) + { + char err[256]; +- snprintf(err, 256, "%s (at offset %d)", json_tokener_errors[jstok->err], jstok->char_offset); ++ snprintf(err, 256, "%s (at offset %d)", json_tokener_error_desc(jstok->err), jstok->char_offset); + json_tokener_free(jstok); + json_object_put(poObj); + geojson_lwerror(err, 1);