[SCM] mapcache branch, upstream, updated. upstream/1.0.0-2-gb3e567f
Bas Couwenberg
sebastic at xs4all.nl
Tue Sep 17 22:46:05 UTC 2013
The following commit has been merged in the upstream branch:
commit b3e567f69c1dcef4c9d1b12211689df82d7d5d5f
Author: Bas Couwenberg <sebastic at xs4all.nl>
Date: Tue Sep 17 20:28:32 2013 +0200
Imported Upstream version 1.2.0
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3a53d36..c77ddeb 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -13,7 +13,7 @@ endif ()
set (MAPCACHE_VERSION_MAJOR 1)
-set (MAPCACHE_VERSION_MINOR 1)
+set (MAPCACHE_VERSION_MINOR 2)
set (MAPCACHE_VERSION_REVISION 0)
@@ -76,6 +76,7 @@ option(WITH_TIFF "Use TIFFs as a cache backend" OFF)
option(WITH_TIFF_WRITE_SUPPORT "Enable (experimental) support for writable TIFF cache backends" OFF)
option(WITH_GEOTIFF "Allow GeoTIFF metadata creation for TIFF cache backends" OFF)
option(WITH_PCRE "Use PCRE for regex tests" OFF)
+option(WITH_MAPSERVER "Enable (experimental) support for the mapserver library" OFF)
find_package(PNG)
if(PNG_FOUND)
@@ -212,6 +213,17 @@ if(WITH_GEOTIFF)
endif(GEOTIFF_FOUND)
endif (WITH_GEOTIFF)
+if(WITH_MAPSERVER)
+ find_package(MAPSERVER)
+ if(MAPSERVER_FOUND)
+ include_directories(${MAPSERVER_INCLUDE_DIR})
+ target_link_libraries(mapcache ${MAPSERVER_LIBRARY})
+ set (USE_MAPSERVER 1)
+ else(MAPSERVER_FOUND)
+ report_optional_not_found(MAPSERVER)
+ endif(MAPSERVER_FOUND)
+endif (WITH_MAPSERVER)
+
if(UNIX)
target_link_libraries(mapcache ${CMAKE_DL_LIBS} m )
@@ -259,6 +271,7 @@ status_optional_component("TIFF" "${USE_TIFF}" "${TIFF_LIBRARY}")
status_optional_component("GeoTIFF" "${USE_GEOTIFF}" "${GEOTIFF_LIBRARY}")
status_optional_component("Experimental TIFF write support" "${USE_TIFF_WRITE}" "${TIFF_LIBRARY}")
status_optional_component("PCRE" "${USE_PCRE}" "${PCRE_LIBRARY}")
+status_optional_component("Experimental mapserver support" "${USE_MAPSERVER}" "${MAPSERVER_LIBRARY}")
INSTALL(TARGETS mapcache DESTINATION ${CMAKE_INSTALL_LIBDIR})
diff --git a/acinclude.m4 b/acinclude.m4
deleted file mode 100644
index e69de29..0000000
diff --git a/cmake/FindMAPSERVER.cmake b/cmake/FindMAPSERVER.cmake
new file mode 100644
index 0000000..a40b418
--- /dev/null
+++ b/cmake/FindMAPSERVER.cmake
@@ -0,0 +1,15 @@
+
+FIND_PATH(MAPSERVER_INCLUDE_DIR
+ NAMES mapserver.h
+ PATH_SUFFIXES mapserver
+)
+
+FIND_LIBRARY(MAPSERVER_LIBRARY
+ NAMES mapserver
+)
+
+set(MAPSERVER_INCLUDE_DIRS ${MAPSERVER_INCLUDE_DIR})
+set(MAPSERVER_LIBRARIES ${MAPSERVER_LIBRARY})
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(MAPSERVER DEFAULT_MSG MAPSERVER_LIBRARY MAPSERVER_INCLUDE_DIR)
+mark_as_advanced(MAPSERVER_LIBRARY MAPSERVER_INCLUDE_DIR)
diff --git a/include/mapcache-config.h.in b/include/mapcache-config.h.in
index 156b6cb..537afca 100644
--- a/include/mapcache-config.h.in
+++ b/include/mapcache-config.h.in
@@ -10,6 +10,7 @@
#cmakedefine USE_TIFF_WRITE 1
#cmakedefine USE_GEOTIFF 1
#cmakedefine USE_PCRE 1
+#cmakedefine USE_MAPSERVER 1
#cmakedefine HAVE_STRNCASECMP 1
#cmakedefine HAVE_SYMLINK 1
diff --git a/lib/source_mapserver.c b/lib/source_mapserver.c
index 42d1169..7d3048f 100644
--- a/lib/source_mapserver.c
+++ b/lib/source_mapserver.c
@@ -27,10 +27,11 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
-#ifdef USE_MAPSERVER
#include "mapcache.h"
#include "ezxml.h"
+
+#ifdef USE_MAPSERVER
#include <apr_tables.h>
#include <apr_strings.h>
#ifdef APR_HAS_THREADS
@@ -273,7 +274,11 @@ mapcache_source* mapcache_source_mapserver_create(mapcache_context *ctx)
source->source.query_info = _mapcache_source_mapserver_query;
return (mapcache_source*)source;
}
-
+#else
+mapcache_source* mapcache_source_mapserver_create(mapcache_context *ctx)
+{
+ ctx->set_error(ctx, 500, "mapserver source not configured for this build");
+}
#endif
/* vim: ts=2 sts=2 et sw=2
diff --git a/release-notes.sh b/release-notes.sh
new file mode 100755
index 0000000..068dbff
--- /dev/null
+++ b/release-notes.sh
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+commitdiff=$1
+
+if test -z $commitdiff; then
+ echo "usage: $0 startcommit..endcommit"
+ exit
+fi
+
+git --no-pager log --no-merges --pretty=format:'%s (%an) : `%h <https://github.com/mapserver/mapcache/commit/%H>`__' $commitdiff | gsed 's!#\([0-9]\+\)! `#\1 <https://github.com/mapserver/mapcache/issues/\1>`__ !g'
+
diff --git a/util/mapcache_seed.c b/util/mapcache_seed.c
index 3b6da57..5f1e6c9 100644
--- a/util/mapcache_seed.c
+++ b/util/mapcache_seed.c
@@ -1072,11 +1072,11 @@ int main(int argc, const char **argv)
if (mode == MAPCACHE_CMD_TRANSFER) {
if (!tileset_transfer_name)
- return usage(argv[0],"tileset where tiles should be transfered to not specified");
+ return usage(argv[0],"tileset where tiles should be transferred to not specified");
tileset_transfer = mapcache_configuration_get_tileset(cfg,tileset_transfer_name);
if(!tileset_transfer)
- return usage(argv[0], "tileset where tiles should be transfered to not found in configuration");
+ return usage(argv[0], "tileset where tiles should be transferred to not found in configuration");
}
if(old) {
--
Packaging for MapCache
More information about the Pkg-grass-devel
mailing list