Postgres Dimensions cause example mapcache.xml services to fail
MapCache is included on OSGeoLive . This deployment includes the demo application based on mapcache.xml.
As part of RFC 121 Postgres support was added via this commit.
Postgres support is OFF by default: https://github.com/MapServer/mapcache/blob/a5c1eab096467b9e3b288ff42e8e119780b36682/CMakeLists.txt#L89
Yet the mapcache.xml example file includes a Postgres example: https://github.com/MapServer/mapcache/blob/aeda6dee3cd3412407f0be47b2e10739bbd364bb/mapcache.xml#L57
This leads to the following error when running the demo on OSGeoLive:
AH00526: Syntax error on line 6 of etc/apache2/conf-enable/mapcache.conf: postgres dimension support requires POSTGRESQL support to be built in Action '-k graceful' failed.
I can think of two solutions to this:
- Move the Postgres example to a different demo XML file e.g. mapcache-postgres.xml and continue to use mapcache.xml
- Set the Debian MapCache builds to use Postgres.
The first I can implement, the second option would fall to Debian packagers. Any preferences?
@geographika: I see a third solution:
- Conditional compile of Postgres-related code.
If you don't mind, I let you work on the first solution and I'll take a look at the third one. Anyway, the second solution should be implemented as well in the future.