root/tags/release-0.5.0/configure.ac

Revision 556, 3.5 kB (checked in by andreas, 15 months ago)

- boost serialization support
- improved some boost detection stuff

Line 
1dnl Process this file with autoconf to produce a configure script.
2dnl Created by Anjuta application wizard.
3
4AC_INIT(mapnik, 0.4.0)
5
6AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
7AM_CONFIG_HEADER(config.h)
8AM_MAINTAINER_MODE
9
10dnl Disable libtool 1.5 support for languages we don't use
11define([AC_LIBTOOL_LANG_F77_CONFIG], [:])dnl
12define([AC_LIBTOOL_LANG_GCJ_CONFIG], [:])dnl
13
14AC_ISC_POSIX
15AC_PROG_CXX
16AM_PROG_CC_STDC
17AC_HEADER_STDC
18
19AM_PROG_LIBTOOL
20
21dnl Check for option to enable debug
22AC_MSG_CHECKING(whether to enable debugging)
23AC_ARG_ENABLE(debug,
24        [  --enable-debug=[no/yes]        enables debug build (default=no)],,
25                 enable_debug=no)
26
27dnl Checks for libraries
28if [ ! test "x$enable_debug" != "xyes"]; then
29  AC_DEFINE(DEBUG, 1, [Define to enable debug build])
30  CXXFLAGS="${CXXFLAGS} -g -DDEBUG -DMAPNIK_DEBUG"
31  AC_MSG_RESULT(yes)
32else
33  AC_MSG_RESULT(no)
34fi
35
36
37dnl Check for boost
38AX_BOOST_BASE
39if test "$succeeded" != "yes" ; then
40  echo "Error: You need to install the boost library!"
41  exit
42fi
43
44AX_BOOST_THREAD
45if test "x$ax_cv_boost_thread" = "xno"; then
46  echo
47  echo "Error: You need to install the boost thread library!"
48  echo
49  exit
50fi
51
52AX_BOOST_FILESYSTEM
53if test "x$ax_cv_boost_filesystem" = "xno"; then
54  echo
55  echo "Error: You need to install the boost filesystem library!"
56  echo
57  exit
58fi
59
60AX_BOOST_REGEX
61if test "x$ax_cv_boost_regex" = "xno"; then
62  echo
63  echo "Error: You need to install the boost regex library!"
64  echo
65  exit
66fi
67
68AX_BOOST_SERIALIZATION
69if test "x$ax_cv_boost_serialization" = "xno"; then
70  echo
71  echo "Error: You need to install the boost serialization library!"
72  echo
73  exit
74fi
75
76AX_LIB_POSTGRESQL
77if test "$found_postgresql" = "yes"; then
78  AM_CONDITIONAL(BUILD_POSTGRESQL, test "x$found_postgresql" = "xyes")
79fi
80
81AX_CHECK_TIFF
82if test "x$link_tiff" = "xno"; then
83  exit
84fi
85
86
87AX_CHECK_JPEG
88if test "x$link_jpeg" = "xno"; then
89  exit
90fi
91
92AX_CHECK_PROJ
93if test "x$link_proj" = "xno"; then
94  exit
95fi
96
97AX_CHECK_LTDL
98if test "x$link_ltdl" = "xno"; then
99  exit
100fi
101
102PKG_CHECK_MODULES(PNG, libpng)
103AC_SUBST(PNG_CFLAGS)
104AC_SUBST(PNG_LIBS)
105
106PKG_CHECK_MODULES(FREETYPE2, freetype2)
107AC_SUBST(FREETYPE2_CFLAGS)
108AC_SUBST(FREETYPE2_LIBS)
109
110dnl Check for option to enable included-agg
111AC_MSG_CHECKING(whether to enable included libagg building)
112AC_ARG_ENABLE(included_agg,
113        [  --enable-included-agg=[no/yes]        enables included libagg build (default=yes)],,
114                 enable_included_agg=yes)
115
116AM_CONDITIONAL(BUILD_AGG, test "x$enable_included_agg" = "xyes")
117
118if [ test "x$enable_included_agg" = "xyes"]; then
119  AGG_LIBS=-L../agg/src
120  AGG_CFLAGS=-I../agg/include
121  AC_SUBST(AGG_LIBS)
122  AC_SUBST(AGG_CFLAGS)
123 
124  AC_MSG_RESULT(yes)
125else
126  AC_MSG_RESULT(no)
127  PKG_CHECK_MODULES(AGG, libagg)
128fi
129
130
131dnl Check for option to enable libxml2
132AC_MSG_CHECKING(whether to enable included libxml2 building)
133AC_ARG_ENABLE(libxml2,
134        [  --enable-libxml2=[no/yes]        enables included libxml2 build (default=no)],,
135                 enable_libxml2=no)
136
137AM_CONDITIONAL(HAVE_LIBXML2, test "x$enable_libxml2" = "xyes")
138
139if [ test "x$enable_libxml2" = "xyes"]; then
140  AC_MSG_RESULT(yes)
141  PKG_CHECK_MODULES(LIBXML2, libxml-2.0)
142  AC_DEFINE(HAVE_LIBXML2, 1,"")
143else
144  AC_MSG_RESULT(no)
145fi
146
147AC_OUTPUT([
148Makefile
149include/Makefile
150include/mapnik/Makefile
151plugins/Makefile
152plugins/input/Makefile
153plugins/input/gdal/Makefile
154plugins/input/postgis/Makefile
155plugins/input/raster/Makefile
156plugins/input/shape/Makefile
157src/Makefile
158mapnik.pc
159mapnik-uninstalled.pc
160agg/Makefile
161agg/src/Makefile
162agg/include/Makefile
163])
Note: See TracBrowser for help on using the browser.