2 AC_CONFIG_MACRO_DIR([m4])
6 AM_CONFIG_HEADER(config.h)
9 AM_CONDITIONAL(SOURCE_MODE_SVN, [test "x${SOURCE_MODE}" = "xsvn"])
11 if test "x${SOURCE_MODE}" = "xsvn" ; then
12 USE_MAINTAINER_MODE=yes
14 USE_MAINTAINER_MODE=no
17 AC_DEFUN([AM_MAINTAINER_MODE],
18 [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
19 dnl maintainer-mode is enabled by default (reason of inclusion of this function)
20 AC_ARG_ENABLE(maintainer-mode,
21 [ --enable-maintainer-mode enable make rules and dependencies not useful
22 (and sometimes confusing) to the casual installer],
23 USE_MAINTAINER_MODE=$enableval)
24 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
25 AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
26 MAINT=$MAINTAINER_MODE_TRUE
31 AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
36 plugins=yes; plugins_reason=default
37 postgresql=yes; postgresql_reason=default
38 samplemap=yes; samplemap_reason=default
39 binding_dbus=yes; binding_dbus_reason=default
40 binding_dbus_use_system_bus=no
41 binding_python=yes; binding_python_reason=default
42 binding_win32=no; binding_win32_reason=default
43 font_freetype=yes; font_freetype_reason=default
44 fontconfig=yes; fontconfig_reason=default
45 fribidi=yes; fribidi_reason=default
46 gui_gtk=no; gui_gtk_reason=default
47 gui_win32=no; gui_win32_reason=default
48 gui_internal=yes; gui_internal_reason=default
49 gui_qml=no; gui_qml_reason=default
50 graphics=yes; graphics_reason=default
51 graphics_gd=no; graphics_gd_reason=default
52 graphics_gtk_drawing_area=no; graphics_gtk_drawing_area_reason=default
53 graphics_qt_qpainter=yes; graphics_qt_qpainter_reason=default
54 graphics_null=yes; graphics_null_reason=default
55 graphics_opengl=yes; graphics_opengl_reason=default
56 graphics_sdl=yes; graphics_sdl_reason=default
57 graphics_win32=no; graphics_win32_reason=default
58 maptool=yes; maptool_reason=default
59 map_binfile=yes; map_binfile_reason=default
60 map_filter=yes; map_filter_reason=default
61 map_mg=yes; map_mg_reason=default
62 map_shapefile=yes; map_shapefile_reason=default
63 map_textfile=yes; map_textfile_reason=default
64 map_csv=yes; map_csv_reason=default
65 osd_core=yes; osd_core_reason=default
66 plugin_pedestrian=no; plugin_pedestrian_reason=default
67 routing=yes; routing_reason=default
68 speech_android=no; speech_android_reason=default
69 speech_cmdline=yes; speech_cmdline_reason=default
70 speech_dbus=no; speech_dbus_reason=default
71 speech_espeak=no; speech_espeak_reason=default
72 speech_speech_dispatcher=yes; speech_speech_dispatcher_reason=default
73 vehicle_demo=yes; vehicle_demo_reason=default
74 vehicle_file=yes; vehicle_file_reason=default
75 vehicle_gpsd=yes; vehicle_gpsd_reason=default
76 vehicle_gpsd_dbus=no; vehicle_gpsd_dbus_reason=default
77 vehicle_gypsy=yes; vehicle_gypsy_reason=default
78 vehicle_null=no; vehicle_null_reason=default
79 vehicle_wince=no; vehicle_wince_reason=default
80 vehicle_iphone=no; vehicle_iphone_reason=default
81 vehicle_android=no; vehicle_android_reason=default
82 graphics_android=no; graphics_android_reason=default
83 vehicle_maemo=no; vehicle_maemo_reason=default
84 vehicle_webos=no; vehicle_webos_reason=default
94 wince|mingw32ce|cegcc)
97 AC_DEFINE(HAVE_API_WIN32_BASE, 1, [Have Windows Base API])
98 AC_DEFINE(HAVE_API_WIN32_CE, 1, [Have Windows CE API])
99 AC_DEFINE(HAVE_PRAGMA_PACK, 1, [Have pragma pack])
100 binding_win32=yes; binding_win32_reason="host_os is wince"
101 gui_win32=yes; gui_win32_reason="host_os is wince"
102 graphics_win32=yes; graphics_win32_reason="host_os is wince"
103 vehicle_wince=yes; vehcile_wince_reason="host_os is wince"
104 speech_espeak=yes; speech_espeak_reason="host_os is wince"
106 maptool=no; maptool_reason="host_os is wince"
110 AC_DEFINE(HAVE_API_WIN32_BASE, 1, [Have Windows Base API])
111 AC_DEFINE(HAVE_API_WIN32, 1, [Have Windows API])
112 binding_win32=yes; binding_win32_reason="host_os is mingw32"
113 gui_win32=yes; gui_win32_reason="host_os is mingw32"
114 graphics_win32=yes; graphics_win32_reason="host_os is mingw32"
115 speech_espeak=yes; speech_espeak_reason="host_os is mingw32"
122 AC_DEFINE(HAVE_API_ANDROID, 1, [Have Android API])
123 echo "void dl_unwind_find_exidx(void) {}" >crt0.c
126 vehicle_android=yes; vehicle_android_reason="host_os is android"
127 graphics_android=yes; graphics_android_reason="host_os is android"
128 speech_android=yes; speech_android_reason="host_os is android"
129 MODULE_LDFLAGS="-module -Xcompiler -nostdlib -Xcompiler -Wl,-rpath -Xcompiler -Wl,/data/data/org.navitproject.navit/lib"
130 MODULE_LIBADD="-llog"
131 LIBNAVIT=_data_data_org.navitproject.navit_lib_navit
132 NAVIT_MODULE_LDFLAGS="$MODULE_LDFLAGS -L\$(top_builddir)/navit -l$LIBNAVIT"
135 if test "x$win32" = "xyes"
137 NAVIT_CFLAGS="$NAVIT_CFLAGS -I\$(top_srcdir)/navit/support/win32"
138 NAVIT_LIBS="$NAVIT_LIBS -L\$(top_builddir)/navit/support/win32 -lsupport_win32"
139 NAVIT_SOCKET_LDFLAGS="$MODULE_LDFLAGS -lws2_32"
143 AM_CONDITIONAL(SUPPORT_WIN32, [test "x$win32" = "xyes"])
144 AM_CONDITIONAL(SUPPORT_WIN32CE, [test "x$win32ce" = "xyes"])
145 AM_CONDITIONAL(SUPPORT_ANDROID, [test "x$android" = "xyes"])
147 if test "x$support_libpng" = "xyes"
149 NAVIT_CFLAGS="$NAVIT_CFLAGS -I\$(top_srcdir)/navit/support/libpng"
150 NAVIT_LIBS="$NAVIT_LIBS -L\$(top_builddir)/navit/support/libpng -lsupport_libpng"
152 AM_CONDITIONAL(SUPPORT_LIBPNG, [test "x$support_libpng" = "xyes"])
154 AC_SUBST(MODULE_LDFLAGS)
155 AC_SUBST(MODULE_LIBADD)
156 AC_SUBST(NAVIT_MODULE_LDFLAGS)
157 AC_SUBST(NAVIT_SOCKET_LDFLAGS)
160 if test "$win32" == "no" -a test "$host_os" != "cygwin"; then
161 LIBS="$LIBS -rdynamic"
164 m4_ifndef([AC_USE_SYSTEM_EXTENSIONS],
165 [AC_DEFUN([AC_USE_SYSTEM_EXTENSIONS], [AC_GNU_SOURCE])])
167 AC_USE_SYSTEM_EXTENSIONS
169 m4_ifdef([AC_PROG_OBJC],[AC_PROG_OBJC])
171 m4_ifdef([AC_PROG_OBJC],[AC_PROG_OBJC],[AC_SUBST([OBJC],["$CC"])
172 AC_SUBST([OBJCFLAGS],["$CFLAGS"])])
173 m4_ifndef([AC_PROG_OBJC],[_AM_DEPENDENCIES(OBJC)])
175 if eval "test x`uname` = xDarwin"; then
176 CFLAGS="$CFLAGS -I/opt/local/include -L/opt/local/lib"
178 if eval "test x$GCC = xyes"; then
179 CFLAGS="$CFLAGS -Wall -Wcast-align -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wreturn-type -D_GNU_SOURCE"
184 if eval "test x$GXX = xyes"; then
185 CXXFLAGS="$CXXFLAGS -Wall -Wcast-align -Wpointer-arith -Wreturn-type -D_GNU_SOURCE"
189 if test "x${cross_compiling}" = "xyes"; then
190 samplemap="no";samplemap_reason="not supported for cross compiling"
191 binding_python="no";binding_python_reason="not supported for cross compiling"
192 postgresql="no";postgresql_reason="not supported for cross compiling"
193 AC_MSG_CHECKING([for a C compiler for build tools])
194 AC_CHECK_PROGS(CC_FOR_BUILD, gcc cc)
198 CCLD_FOR_BUILD="$CC_FOR_BUILD"
199 AC_SUBST(cross_compiling)
200 AM_CONDITIONAL(CROSS_COMPILING, test "x${cross_compiling}" = "xyes")
201 AC_SUBST(CC_FOR_BUILD)
202 AC_SUBST(CCLD_FOR_BUILD)
205 # defines WORDS_BIGENDIAN for big-endian systems
208 AC_ARG_ENABLE(variant, [ --enable-variant=something set variant], NAVIT_VARIANT=$enableval)
209 AC_SUBST(NAVIT_VARIANT)
211 AC_ARG_ENABLE(cache-size, [ --enable-cache-size=size in bytes set cache size], AC_DEFINE_UNQUOTED(CACHE_SIZE,[${enableval}], [Size of Cache in Bytes]))
213 AC_ARG_ENABLE(avoid-unaligned, [ --enable-avoid-unaligned avoid unaligned accesses], AVOID_UNALIGNED=$enableval, AVOID_UNALIGNED=no)
214 test x"${AVOID_UNALIGNED}" = xyes && AC_DEFINE(AVOID_UNALIGNED,[],Define to avoid unaligned access)
216 AC_ARG_ENABLE(avoid-float, [ --enable-avoid-float avoid floating point calculations], AVOID_FLOAT=$enableval, AVOID_FLOAT=no)
217 test x"${AVOID_FLOAT}" = xyes && AC_DEFINE(AVOID_FLOAT,[],Define to avoid floating point)
219 AC_ARG_ENABLE(transformation-roll, [ --enable-transformation-roll add support for specifying roll angle in transformation], ENABLE_ROLL=$enableval, ENABLE_ROLL=no)
220 test x"${ENABLE_ROLL}" = xyes && AC_DEFINE(ENABLE_ROLL,[],Define to add support for specifying roll angle in transformation)
222 AC_ARG_ENABLE(hildon, [ --disable-hildon build without maemo/hildon support], enable_hildon=$enableval, enable_hildon=yes)
223 if test "x${enable_hildon}" = "xyes" ; then
224 PKG_CHECK_MODULES(HILDON, hildon-1 >= 0.9.9, , [
228 PKG_CHECK_MODULES(GPSBT, gpsbt, [
229 AC_DEFINE(HAVE_GPSBT, 1, [Have the gpsbt library])
230 AC_SUBST(GPSBT_CFLAGS)
235 if test x"${enable_hildon}" = xyes ; then
236 AC_DEFINE(USE_HILDON, 1, [Build with maemo/hildon support])
237 AC_SUBST(HILDON_CFLAGS)
238 AC_SUBST(HILDON_LIBS)
241 AM_CONDITIONAL(USE_HILDON, test "${enable_hildon}" = "xyes")
243 AC_ARG_ENABLE(osso, [ --disable-osso build without maemo/osso support], enable_osso=$enableval, enable_osso=yes)
244 if test "x${enable_osso}" = "xyes" ; then
245 PKG_CHECK_MODULES(LIBOSSO, libosso, , [
249 if test x"${enable_osso}" = xyes ; then
250 AC_DEFINE(USE_OSSO, 1, [Build with maemo/osso support])
251 AC_SUBST(LIBOSSO_CFLAGS)
252 AC_SUBST(LIBOSSO_LIBS)
256 AM_CONDITIONAL(USE_OSSO, test "x${enable_osso}" = "xyes")
258 AC_ARG_ENABLE(garmin, [ --disable-garmin disable garmin support], USE_GARMIN=$enableval, USE_GARMIN=yes)
261 AC_PATH_PROG(_PATH_BZCAT,[bzcat])
262 if test "x${_PATH_BZCAT}" = "x" ; then
263 samplemap=no; samplemap_reason="bzcat missing"
265 AC_ARG_ENABLE(maptool, [ --disable-maptool don't build maptool], maptool=$enableval;maptool_reason="configure parameter")
266 AM_CONDITIONAL(MAPTOOL, [test "x$maptool" = "xyes"])
267 if test "x$maptool" != "xyes"; then
268 samplemap=no; samplemap_reason="maptool disabled"
270 AC_ARG_ENABLE(samplemap, [ --disable-samplemap don't build the samplemap], samplemap=$enableval;samplemap_reason="configure parameter")
271 AM_CONDITIONAL(BUILD_SAMPLEMAP, [test "x$samplemap" = "xyes"])
273 AC_ARG_ENABLE(fastmath, [ --disable-fastmath don't build with fastmath], fastmath=$enableval, fastmath=yes)
274 AM_CONDITIONAL(FASTMATH, [test "x$fastmath" = "xyes"])
276 if test x"$fastmath" = xyes; then
277 if eval "test x$GCC = xyes"; then
278 CFLAGS="$CFLAGS -ffast-math"
282 X_CFLAGS="-I$x_includes"
283 AS_IF([test -n "$ac_x_libraries"], [X_LIBS="-L$ac_x_libraries"])
286 AC_ARG_ENABLE(glib, [ --disable-glib don't build with external glib], glib=$enableval, glib=yes)
287 if test "x${glib}" = "xyes" -a "x${GLIB_CFLAGS}" = "x" -a "x${GLIB_LIBS}" = "x"; then
288 PKG_CHECK_MODULES(GLIB, [glib-2.0 gthread-2.0], [glib=yes],[glib=no])
290 if test "x${glib}" = "xyes"; then
291 AC_DEFINE(HAVE_GLIB, 1, [Define to 1 if you have (external) glib library])
293 GLIB_CFLAGS="-I\$(top_srcdir)/navit/support -I\$(top_srcdir)/navit/support/glib -I\$(top_srcdir)/navit/support/ezxml"
294 GLIB_LIBS="-L\$(top_builddir)/navit/support/glib -lsupport_glib -L\$(top_builddir)/navit/support/ezxml -lsupport_ezxml"
295 if test "x${win32}" != "xyes" -a "x${android}" != "xyes"; then
296 GLIB_LIBS="$GLIB_LIBS -lpthread"
301 AC_ARG_ENABLE(gmodule, [ --disable-gmodule don't build with gmodule], gmodule=$enableval, gmodule=yes)
302 if test x"${gmodule}" = "xyes"; then
303 PKG_CHECK_MODULES(GMODULE, [gmodule-2.0], [gmodule=yes], [gmodule=no])
305 if test "x${gmodule}" = "xyes"; then
306 AC_DEFINE(HAVE_GMODULE, 1, [Define to 1 if you have gmodule])
308 AC_CHECK_LIB(dl, dlopen,
309 [plugins_reason="default, via dlopen";GMODULE_LIBS="-ldl";AC_DEFINE(HAVE_DLOPEN, 1, [Define to 1 if you have dlopen])],
310 [plugins="no"; plugins_reason="package gmodule and dlopen missing"]
315 AC_CHECK_LIB(crypto, AES_encrypt, [CRYPTO_LIBS="-lcrypto";AC_DEFINE(HAVE_LIBCRYPTO, 1, [Define to 1 if you have libcrypto])])
316 AC_SUBST(CRYPTO_LIBS)
319 AC_ARG_ENABLE(plugins, [ --disable-plugins disable plugins], [ plugins=$enableval;plugin_reason="configure parameter" ])
320 AC_ARG_ENABLE(shared-libnavit, [ --enable-shared-libnavit], [ shared_libnavit=$enableval])
321 if test "x${plugins}" = "xyes"; then
327 Define to 1 if you have plugins.
329 if test "x${win32}" = "xyes"; then
331 NAVIT_MODULE_LDFLAGS="-no-undefined -L\$(top_builddir)/navit -l$LIBNAVIT -L\$(top_builddir)/intl -lintl"
334 if test "x${shared_libnavit}" = "xyes"; then
342 AM_CONDITIONAL(PLUGINS, [test "x$plugins" = "xyes"])
343 AM_CONDITIONAL(SHARED_LIBNAVIT, [test "x$shared_libnavit" = "xyes"])
344 AM_CONDITIONAL(BIN_NAVIT, [test "x$bin_navit" = "xyes"])
348 AM_CONDITIONAL(EVENT_GLIB, [test "x$glib" = "xyes"])
349 AM_CONDITIONAL(SUPPORT_GLIB, [test "x$glib" = "xno"])
350 AM_CONDITIONAL(SUPPORT_EZXML, [test "x$glib" = "xno"])
352 AC_CHECK_HEADER([sys/time.h],
356 [Define to 1 if you have the <sys/time.h> header file.])
359 if test "x${ZLIB_CFLAGS}" = "x" -a "x${ZLIB_LIBS}" = "x"; then
365 Define to 1 if you have the <zlib.h> header file.
369 ZLIB_CFLAGS="-I\$(top_srcdir)/navit/support/zlib"
370 ZLIB_LIBS="-L\$(top_builddir)/navit/support/zlib -lsupport_zlib"
376 AM_CONDITIONAL(SUPPORT_ZLIB, [test "x$zlib" = "xno"])
377 AC_SUBST(ZLIB_CFLAGS)
380 AC_CHECK_HEADER(sys/socket.h, AC_DEFINE([HAVE_SOCKET],[],Define to 1 if you have sockets))
381 AC_CHECK_HEADER(winsock2.h, AC_DEFINE([HAVE_WINSOCK],[],Define to 1 if you have Windows sockets))
384 PKG_CHECK_MODULES(GTK2, [gtk+-2.0], [gtk2_pkgconfig=yes], [gtk2_pkgconfig=no])
385 if test "x$gtk2_pkgconfig" = "xyes"; then
386 AC_DEFINE(HAVE_GTK2, 1, [Define to 1 if you have gtk2])
387 graphics_gtk_drawing_area=yes; graphics_gtk_drawing_area_reason="gtk+-2.0 present"
388 gui_gtk=yes; gui_gtk_reason="gtk+-2.0 present"
392 AC_MSG_CHECKING(for fsync)
393 AC_TRY_LINK([#include <unistd.h>], [fsync(0);],AC_MSG_RESULT(yes);AC_DEFINE(HAVE_FSYNC, 1, [Define to 1 if you have the `fsync' function.]),AC_MSG_RESULT(no))
396 AC_MSG_CHECKING(for system)
397 AC_TRY_LINK([#include <stdlib.h>], [system("/bin/true");],AC_MSG_RESULT(yes);AC_DEFINE(HAVE_SYSTEM, 1, [Define to 1 if you have the `system' function.]),speech_cmdline=no; speech_cmdline_reason="not supported without system()"; AC_MSG_RESULT(no))
399 AC_MSG_CHECKING(for CreateProcess)
400 AC_TRY_LINK([#include <windows.h>], [CreateProcess(NULL,NULL,NULL,NULL,0,0,NULL,NULL,NULL,NULL);],AC_MSG_RESULT(yes);AC_DEFINE(HAVE_CREATEPROCESS, 1, [Define to 1 if you have the `CreateProcess' function.]) speech_cmdline=yes; speech_cmdline_reason="CreateProcess exists", AC_MSG_RESULT(no))
403 AC_MSG_CHECKING(for sbrk)
404 AC_TRY_LINK([#include <unistd.h>], [sbrk(0);],AC_MSG_RESULT(yes);AC_DEFINE(HAVE_SBRK, 1, [Define to 1 if you have the `sbrk' function.]),AC_MSG_RESULT(no))
407 AC_ARG_ENABLE(graphics-sdl, [ --disable-graphics-sdl don't create graphics sdl], graphics_sdl=$enableval;graphics_sdl_reason="configure parameter")
409 if test "x${graphics_sdl}" = "xyes" ; then
410 PKG_CHECK_MODULES(SDL,
413 graphics_sdl_reason="sdl present"] ,
415 graphics_sdl_reason="sdl not available"]
420 if test "x${graphics_sdl}" = "xyes" ; then
421 save_CPPFLAGS=$CPPFLAGS
422 CPPFLAGS="$SDL_CFLAGS $CPPFLAGS"
423 AC_CHECK_HEADER(SDL_image.h,SDL_IMAGE_LIBS=-lSDL_image,graphics_sdl="no";graphics_sdl_reason="SDL_image.h missing")
424 AC_SUBST(SDL_IMAGE_LIBS)
425 CPPFLAGS=$save_CPPFLAGS
427 if test "x${graphics_sdl}" = "xyes" ; then
428 AC_DEFINE(GRAPHICS_SDL, 1, [Build with graphics sdl])
430 AM_CONDITIONAL(GRAPHICS_SDL, test "x${graphics_sdl}" = "xyes")
432 AC_ARG_ENABLE(postgresql, [ --disable-postgresql don't add postgresql support to maptool], postgresql=$enableval;postgresql_reason="configure parameter")
433 if test "x${postgresql}" = "xyes" ; then
434 if test -z "$PG_CONFIG"; then
435 AC_PATH_PROG([PG_CONFIG], [pg_config], [])
437 AC_MSG_CHECKING([for PostgreSQL libraries with $PG_CONFIG])
438 if test ! -x "$PG_CONFIG"; then
439 if test "x${PG_CONFIG}" = "x" ; then
440 postgresql_reason="$PG_CONFIG not executable"
442 postgresql_reason="pg_config missing"
447 POSTGRESQL_CFLAGS="-I`$PG_CONFIG --includedir`"
448 POSTGRESQL_LIBS="-L`$PG_CONFIG --libdir` -lpq"
449 AC_DEFINE(HAVE_POSTGRESQL, 1, [Postgresql libraries available])
450 AC_SUBST(POSTGRESQL_CFLAGS)
451 AC_SUBST(POSTGRESQL_LIBS)
455 AM_CONDITIONAL(HAVE_POSTGRESQL, test "x${postgresql}" = "xyes")
458 AC_ARG_ENABLE(font-freetype, [ --disable-font-freetype don't add freetype support], font_freetype=$enableval;font_freetype_reason="configure parameter")
459 if test "x${font_freetype}" = "xyes" -a "x${FREETYPE2_CFLAGS}" = "x" -a "x${FREETYPE2_LIBS}" = "x"; then
460 PKG_CHECK_MODULES(FREETYPE2, [freetype2], , [font_freetype=no;font_freetype_reason="Package freetype2 missing"])
464 AC_SUBST(FREETYPE2_CFLAGS)
465 AC_SUBST(FREETYPE2_LIBS)
466 AM_CONDITIONAL(FONT_FREETYPE, test "x${font_freetype}" = "xyes")
467 AC_ARG_WITH(freetype-fonts, [ --with-freetype-fonts specify what fonts to use], AC_DEFINE_UNQUOTED(FREETYPE_FONTS,[${withval}],[Freetype fonts to use]))
469 AC_ARG_ENABLE(fontconfig, [ --disable-fontconfig don't' add fontconfig support], fontconfig=$enableval;fontconfig_reason="configure parameter")
470 if test "x${fontconfig}" = "xyes"; then
471 PKG_CHECK_MODULES(FONTCONFIG, [fontconfig], [fontconfig=yes], [fontconfig=no])
473 if test "x$fontconfig" = "xyes"; then
474 AC_DEFINE(HAVE_FONTCONFIG, 1, [Define to 1 if you have fontconfig])
476 AC_SUBST(FONTCONFIG_CFLAGS)
477 AC_SUBST(FONTCONFIG_LIBS)
479 AM_CONDITIONAL(FONTS, test "x${font_freetype}" = "xyes" -a "x$fontconfig" != "xyes")
482 AC_ARG_ENABLE(fribidi, [ --disable-fribidi dont build with fribidi], fribidi=$enableval;fribidi_reason="configure parameter", fribidi=yes)
483 if test x"${fribidi}" = "xyes"; then
484 PKG_CHECK_MODULES(FRIBIDI2, [fribidi >= 0.19.0], [fribidi=yes;oldfribidi=no],
485 [ PKG_CHECK_MODULES([FRIBIDI], [fribidi],
486 [fribidi=yes;oldfribidi=yes;fribid_reason="using old version"], [fribidi=no;fribidi_reason="FriBidi library not found"])
489 if test x"${fribidi}" = "xyes"; then
490 AC_DEFINE(USE_FRIBIDI, 1, [Build with fribidi support])
492 if test x"${oldfribidi}" = "xyes"; then
493 AC_DEFINE(FRIBIDIOLD, 1, [Build with fribidi support for older versions of fribidi])
496 AC_SUBST(FRIBIDI2_CFLAGS)
497 AC_SUBST(FRIBIDI2_LIBS)
498 AC_SUBST(FRIBIDI_CFLAGS)
499 AC_SUBST(FRIBIDI_LIBS)
501 PKG_CHECK_MODULES(IMLIB2, [imlib2], [imlib2_pkgconfig=yes], [imlib2_pkgconfig=no])
502 if test "x$imlib2_pkgconfig" = "xyes"; then
503 AC_DEFINE(HAVE_IMLIB2, 1, [Define to 1 if you have imlib2])
505 AC_SUBST(IMLIB2_CFLAGS)
506 AC_SUBST(IMLIB2_LIBS)
508 AC_ARG_ENABLE(graphics-opengl, [ --disable-graphics-opengl disable graphics type OpenGL], graphics_opengl=$enableval;graphics_opengl_reason="configure parameter")
509 if test "x${graphics_opengl}" = "xyes" ; then
516 Define to 1 if you have the <GL/gl.h> header file.
518 OPENGL_LIBS="$X_LIBS -lGL -lglut -lfreeimage"
520 AC_MSG_WARN([*** no GL/gl.h -- opengl graphics support disabled];graphics_opengl=no;graphics_opengl_reason="GL/gl.h header missing")
528 Define to 1 if you have the <GL/glut.h> header file.
531 AC_MSG_WARN([*** no GL/glut.h -- opengl graphics support disabled]);graphics_opengl=no;graphics_opengl_reason="GL/glut.h header missing"
539 Define to 1 if you have the <GL/freeglut.h> header file.
542 AC_MSG_WARN([*** no GL/freeglut.h -- opengl support disabled]);graphics_opengl=no;graphics_opengl_reason="Headers missing"
545 AC_SUBST(OPENGL_CFLAGS)
546 AC_SUBST(OPENGL_LIBS)
553 Define to 1 if you have the <GL/glc.h> header file.
557 AC_MSG_WARN([*** no GL/glc.h -- opengl graphics support disabled]);graphics_opengl=no;graphics_opengl_reason="GL/glc.h header missing"
564 Define to 1 if you have the <FreeImage.h> header file.
566 FREEIMAGE_LIBS="-lfreeimage"
568 AC_MSG_WARN([*** no FreeImage.h -- opengl support disabled]);graphics_opengl=no;graphics_opengl_reason="Headers missing"
570 AC_SUBST(FREEIMAGE_LIBS)
575 AM_CONDITIONAL(GRAPHICS_OPENGL, [test "x$glut" = "xyes" -a "x$freeglut" = "xyes" -a "x$opengl" = "xyes" -a "x$freeimage" = "xyes" -a "x$glc" = "xyes" ])
579 if test x"${map_shapefile}" = xyes
582 [shapefil.h libshp/shapefil.h],
584 [HAVE_SYS_SHAPEFILELIB],
586 Define to 1 if you have the <shapefil.h> header file.
588 [SHAPEFILE_CFLAGS="-I\$(top_srcdir)/navit/support/shapefile"]
594 [SHAPEFILE_LIBS="-lshp"
595 system_shapefile=yes],
596 [SHAPEFILE_LIBS="-L\$(top_builddir)/navit/support/shapefile -lsupport_shapefile"
600 if test x"${system_shapefile}" = xno
602 AC_MSG_WARN([*** The shapefile library(libshp) from the system is to old or not found! -- using included copy])
606 AC_SUBST(SHAPEFILE_CFLAGS)
607 AC_SUBST(SHAPEFILE_LIBS)
608 AM_CONDITIONAL(HAVE_SYSTEM_SHAPEFILELIB, [test "x$system_shapefile" = "xyes" ])
610 if test x"${USE_GARMIN}" = xyes
612 # check for libgarmin
613 PKG_CHECK_MODULES(LIBGARMIN, libgarmin, use_libgarmin=yes, use_libgarmin=no)
614 AC_SUBST(LIBGARMIN_CFLAGS)
615 AC_SUBST(LIBGARMIN_LIBS)
617 AM_CONDITIONAL(HAVELIBGARMIN, [test "x$use_libgarmin" = "xyes"])
621 AC_ARG_ENABLE(binding-python, [ --disable-binding-python don't create binding python], binding_python=$enableval;binding_python_reason="configure parameter")
622 if test "x${binding_python}" = "xyes"; then
623 AC_PATH_PROG(_PATH_PYTHON,[python])
624 dnl Libraries and flags for embedded Python.
625 dnl FIXME: I wish there was a less icky way to get this.
626 if test "x${_PATH_PYTHON}" != "x" ; then
627 AC_MSG_CHECKING(for Python linkage)
628 AC_PATH_PROG([PYTHONCONFIG], [python-config], [])
629 if test "x${PYTHONCONFIG}" = "x" ; then
630 py_prefix=`$_PATH_PYTHON -c 'import sys; print sys.prefix'`
631 py_ver=`$_PATH_PYTHON -c 'import sys; print sys.version[[:3]]'`
632 py_lib=`$_PATH_PYTHON -c 'import sys; print sys.lib'`
633 py_libdir="${py_prefix}/${py_lib}/python${py_ver}"
634 PYTHON_CFLAGS="-I${py_prefix}/include/python${py_ver}"
635 if test -f $py_libdir/config/Makefile -a -f $py_prefix/include/python${py_ver}/Python.h; then
636 py_libs=`grep '^LIBS=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
637 py_libc=`grep '^LIBC=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
638 py_libm=`grep '^LIBM=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
639 py_liblocalmod=`grep '^LOCALMODLIBS=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
640 py_libbasemod=`grep '^BASEMODLIBS=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
641 PYTHON_LIBS="-L$py_libdir/config $py_libs $py_libc $py_libm -lpython$py_ver $py_liblocalmod $py_libbasemod"
642 PYTHON_LIBS=`echo $PYTHON_LIBS | sed -e 's/[ \\t]*/ /g'`
643 AC_MSG_RESULT($py_libdir)
646 binding_python_reason="$py_libdir/config/Makefile or $py_prefix/include/python${py_ver}/Python.h missing"
650 PYTHON_CFLAGS="`${PYTHONCONFIG} --cflags`"
651 PYTHON_LIBS="`${PYTHONCONFIG} --ldflags`"
655 binding_python_reason="python executable missing"
658 if test "x${binding_python}" = xyes ; then
659 AC_DEFINE(USE_BINDING_PYTHON, 1, [Build with binding python])
661 AC_SUBST(PYTHON_CFLAGS)
662 AC_SUBST(PYTHON_LIBS)
663 AM_CONDITIONAL(BINDING_PYTHON, test "x${binding_python}" = "xyes")
666 AC_ARG_ENABLE(binding-dbus, [ --disable-binding-dbus don't create binding dbus], binding_dbus=$enableval;binding_dbus_reason="configure parameter")
667 AC_ARG_ENABLE(binding-dbus-use-system-bus, [ --enable-binding-dbus-use-system-bus use system bus for dbus binding], binding_dbus_use_system_bus=$enableval)
668 if test "x${binding_dbus}" = "xyes" ; then
669 PKG_CHECK_MODULES(DBUS, [dbus-glib-1], ,binding_dbus=no)
671 if test "x${binding_dbus}" = "xyes" ; then
672 AC_DEFINE(USE_BINDING_DBUS, 1, [Build with binding dbus])
673 vehicle_gpsd_dbus="yes"
674 vehicle_gpsd_dbus_reason="dbus binding present"
676 speech_dbus_reason="dbus binding present"
678 if test "x${binding_dbus_use_system_bus}" = "xyes" ; then
679 AC_DEFINE(DBUS_USE_SYSTEM_BUS, 1, [Use system bus instead of session bus for binding dbus])
681 AC_SUBST(DBUS_CFLAGS)
683 AM_CONDITIONAL(BINDING_DBUS, test "x${binding_dbus}" = "xyes")
684 AM_CONDITIONAL(VEHICLE_GPSD_DBUS, test "x${vehicle_gpsd_dbus}" = "xyes")
685 AM_CONDITIONAL(SPEECH_DBUS, test "x${speech_dbus}" = "xyes")
686 AC_ARG_WITH(dbus-service-dir, [ --with-dbus-service-dir specify where the dbus service dir resides], DBUS_SERVICE_DIR=$withval, DBUS_SERVICE_DIR="$datarootdir/dbus-1/services")
687 AC_SUBST(DBUS_SERVICE_DIR)
690 AC_ARG_ENABLE(binding-win32, [ --disable-binding-win32 don't create binding win32], binding_win32=$enableval;binding_win32_reason="configure parameter")
691 if test "x${binding_win32}" = "xyes" ; then
692 AC_DEFINE(USE_BINDING_WIN32, 1, [Build with binding win32])
694 AM_CONDITIONAL(BINDING_WIN32, test "x${binding_win32}" = "xyes")
697 AC_ARG_ENABLE(svg, [ --disable-svg disable Scalable Vector Graphics], enable_svg=$enableval, enable_svg=yes)
698 AC_ARG_ENABLE(svg2png, [ --disable-svg2png disable conversion of svgs to pngs], enable_svg2png=$enableval, enable_svg2png=yes)
699 AC_ARG_ENABLE(svg2png-scaling, [ --enable-svg2png-scaling enable conversion of svgs to pngs with specified sizes], SVG2PNG_SCALES=$enableval, SVG2PNG_SCALES="8 16 32 48 96")
700 AC_ARG_ENABLE(svg2png-scaling-flag, [ --enable-svg2png-scaling-flag enable conversion of flag svgs to pngs with specified sizes], SVG2PNG_SCALES_FLAG=$enableval, SVG2PNG_SCALES_FLAG="8 16 32 48 96")
701 AC_ARG_ENABLE(svg2png-scaling-nav, [ --enable-svg2png-scaling-nav enable conversion of nav svgs to pngs with specified sizes], SVG2PNG_SCALES_NAV=$enableval, SVG2PNG_SCALES_NAV="8 16 32 48 96")
702 AC_ARG_WITH(svg2png-use-convert, [ --with-svg2png-use-convert use imagemagick's convert for png creation], SVG2PNG_CONVERTER="convert")
703 AC_ARG_WITH(svg2png-use-rsvg-convert, [ --with-svg2png-use-rsvg-convert use librsvg's rsvg-convert for png creation], SVG2PNG_CONVERTER="rsvg-convert")
704 AC_ARG_WITH(svg2png-use-inkscape, [ --with-svg2png-use-inkscape use inkscapes internal convert routines for png creation], SVG2PNG_CONVERTER="inkscape")
705 AC_ARG_WITH(svg2png-use-ksvgtopng4, [ --with-svg2png-use-ksvgtopng4 use kde4's ksvgtopng4 for png creation], SVG2PNG_CONVERTER="ksvgtopng4")
706 AC_ARG_WITH(svg2png-use-ksvgtopng, [ --with-svg2png-use-ksvgtopng use kde3's convert for png creation], SVG2PNG_CONVERTER="ksvgtopng")
707 if test "x${enable_svg2png}" = "xyes" ; then
708 if test "x${SVG2PNG_CONVERTER}" = "x"; then
709 SVG2PNG_CONVERTER="rsvg-convert ksvgtopng ksvgtopng4 inkscape convert"
711 AC_PATH_PROGS([SVG2PNG], ${SVG2PNG_CONVERTER}, [none])
712 if test "x${SVG2PNG}" = "xnone"; then
717 AC_SUBST(SVG2PNG_SCALES)
718 AC_SUBST(SVG2PNG_SCALES_FLAG)
719 AC_SUBST(SVG2PNG_SCALES_NAV)
720 AM_CONDITIONAL(USE_SVG2PNG_SCALES, test "x${SVG2PNG_SCALES}" != "xyes" -a "x${SVG2PNG_SCALES}" != "x")
721 AM_CONDITIONAL(USE_SVG2PNG_SCALES_FLAG, test "x${SVG2PNG_SCALES_FLAG}" != "xyes" -a "x${SVG2PNG_SCALES_FLAG}" != "x")
722 AM_CONDITIONAL(USE_SVG2PNG_SCALES_NAV, test "x${SVG2PNG_SCALES_NAV}" != "xyes" -a "x${SVG2PNG_SCALES_NAV}" != "x")
723 AM_CONDITIONAL(USE_SVG2PNG, test "x${enable_svg2png}" = "xyes")
724 AM_CONDITIONAL(USE_SVG, test "x${enable_svg}" = "xyes")
727 AC_ARG_WITH(xslts, [ --with-xslts enable processing of navit.xml with given xslt scripts], XSLTS=$withval, XSLTS="")
729 AC_ARG_WITH(saxon, [ --with-saxon specify the saxon xslt processor], SAXON=$withval, SAXON="saxon")
732 # Android Permissions
733 AC_ARG_WITH(android-permissions, [ --with-android-permissions Set additional android permissions], ANDROID_PERMISSIONS=$withval, ANDROID_PERMISSIONS="")
734 AC_SUBST(ANDROID_PERMISSIONS)
736 AC_ARG_WITH(android-project, [ --with-android-project Set android project], ANDROID_PROJECT=$withval, ANDROID_PROJECT="3")
737 AC_SUBST(ANDROID_PROJECT)
742 [ --disable-nls disable Native Language Support ( gettext/libintl )],
743 enable_nls=$enableval, enable_nls=yes)
753 if test "x$enable_nls" = "xyes"; then
755 AC_CHECK_FUNC(gettext, [HAVEGETTEXT="yes"],[INTLIBS="-lintl" HAVEGETTEXT="yes"])
756 AC_CHECK_PROG(XGETTEXT, xgettext, xgettext)
757 AC_CHECK_PROG(MSGMERGE, msgmerge, msgmerge)
758 AC_CHECK_PROG(MSGFMT, msgfmt, msgfmt)
760 if test "$XGETTEXT" != ""; then
761 if $XGETTEXT --help 2>&1 | grep illegal >/dev/null ; then
762 echo "xgettext isn't GNU version"
765 if echo '<test/>' | $XGETTEXT -L Glade - ; then
771 if test "$XGETTEXT" != "" ; then
773 if test "$LINGUAS" = ""; then
774 ling=` (cd $srcdir/po; /bin/ls *.po.in) `
776 lcode=`basename $l .po.in`
777 LINGUAS="$LINGUAS$lcode "
780 AC_DEFINE(ENABLE_NLS, [1], [NLS Please])
781 echo "xgettext and gettext() exist; will build i18n support for $LINGUAS"
785 echo "xgettext doesn't exist; will not build i18n support"
788 for lang in $LINGUAS; do
789 MOFILES="$MOFILES $lang.mo"
791 for lang in $LINGUAS; do
792 POFILES="$POFILES $lang.po"
794 for lang in $LINGUAS; do
795 POIFILES="$POIFILES $lang.po.in"
802 AM_GNU_GETTEXT_VERSION
803 AM_GNU_GETTEXT(no-libtool, need-ngettext, \$(top_builddir)/intl/)
804 if test "x${shared_libnavit}" = "xyes" -a "x${win32ce}" = "xyes"; then
805 INTLLIBS="\$(top_builddir)/intl/libintl.la"
811 if test x"$LIBINTL" != "x" ;then
812 CFLAGS="$CFLAGS -I\$(top_builddir)/intl/"
816 AM_CONDITIONAL(ENABLE_NLS, [test "x$enable_nls" = "xyes"])
817 AM_CONDITIONAL(XGETTEXT_GLADE, [test "x$xgettext_glade" = "xyes"])
823 [Define to 1 if you have byteswap.h],
828 AC_CHECK_HEADER(sys/endian.h,AC_DEFINE([USE_SYS_ENDIAN_H], [1], [Define to 1 if you have sys/endian.h],),)
831 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
832 AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
836 AC_CHECK_HEADER(wordexp.h,wordexp_h=yes,wordexp_h=no;NAVIT_CFLAGS="$NAVIT_CFLAGS -I\$(top_srcdir)/navit/support/wordexp";WORDEXP_LIBS="-L\$(top_builddir)/navit/support/wordexp -lsupport_wordexp")
837 AM_CONDITIONAL(SUPPORT_WORDEXP, [test "x$wordexp_h" = "xno"])
840 AC_ARG_ENABLE(support_libc, [ --enable-support-libc enable builtin mini libc ], support_libc=$enableval)
841 AM_CONDITIONAL(SUPPORT_LIBC, [test "x$support_libc" = "xyes"])
842 if test "x$support_libc" = "xyes"; then
843 CFLAGS="$CFLAGS -I\$(top_srcdir)/navit/support/libc"
844 LIBC_LIBS="-L\$(top_builddir)/navit/support/libc -lsupport_libc"
848 AC_ARG_ENABLE(graphics, [ --disable-graphics disable graphics], graphics=$enableval;graphics_reason="configure parameter")
849 AM_CONDITIONAL(GRAPHICS, test "x${graphics}" = "xyes")
850 if test "x$graphics" = "xyes"; then
851 AC_DEFINE([USE_GRAPHICS],[1],Define to 1 if you want to use graphics.)
857 AC_ARG_ENABLE(graphics-android, [ --disable-graphics-android disable graphics type android], graphics_android=$enableval;graphics_android_reason="configure parameter")
858 AM_CONDITIONAL(GRAPHICS_ANDROID, test "x${graphics_android}" = "xyes")
860 AC_ARG_ENABLE(graphics-gd, [ --enable-graphics-gd enable graphics type gd], graphics_gd=$enableval;graphics_gd_reason="configure parameter")
861 if test "x${graphics_gd}" = "xyes" ; then
862 if test -z "$GDLIB_CONFIG"; then
863 AC_PATH_PROG([GDLIB_CONFIG], [gdlib-config], [])
865 AC_MSG_CHECKING([for gdlib with $GDLIB_CONFIG])
866 if test ! -x "$GDLIB_CONFIG"; then
867 if test "x${GDLIB_CONFIG}" = "x" ; then
868 graphics_gd_reason="$GDLIB_CONFIG not executable"
870 graphics_gd_reason="gdlib-config missing"
875 if test "x${GD_CFLAGS}" = "x" ; then
876 GD_CFLAGS="-I`$GDLIB_CONFIG --includedir`"
878 if test "x${GD_LIBS}" = "x" ; then
879 GD_LIBS="-L`$GDLIB_CONFIG --libdir` -lgd `$GDLIB_CONFIG --libs`"
886 AM_CONDITIONAL(GRAPHICS_GD, test "x${graphics_gd}" = "xyes")
892 Define to 1 if you have shared memory
900 Define to 1 if you have xpm header
908 Define to 1 if you have the getopt header
911 if test "x${graphics_gd}" = "xyes" ; then
912 save_CPPFLAGS=$CPPFLAGS
914 LIBS="$GD_LIBS $LIBS"
915 CPPFLAGS="$GD_CFLAGS $CPPFLAGS"
916 AC_TRY_LINK([#include <gd.h>], [gdImageCreateFromPng(0);],AC_MSG_RESULT(yes);AC_DEFINE(HAVE_GRAPHICS_GD_PNG, 1, [Define to 1 if you have png support in gd.]),AC_MSG_RESULT(no))
917 CPPFLAGS=$save_CPPFLAGS
922 AC_ARG_ENABLE(graphics-gtk-drawing-area, [ --disable-graphics-gtk-drawing-area disable graphics type gtk_drawing_area], graphics_gtk_drawing_area=$enableval;graphics_gtk_drawing_area_reason="configure parameter")
923 AM_CONDITIONAL(GRAPHICS_GTK_DRAWING_AREA, [test "x${graphics_gtk_drawing_area}" = "xyes"])
925 AC_ARG_ENABLE(graphics-null, [ --disable-graphics-null disable graphics type null], graphics_null=$enableval;graphics_null_reason="configure parameter")
926 AM_CONDITIONAL(GRAPHICS_NULL, test "x${graphics_null}" = "xyes")
928 AC_ARG_ENABLE(graphics-win32, [ --disable-graphics-win32 disable graphics type win32], graphics_win32=$enableval;graphics_win32_reason="configure parameter")
929 AM_CONDITIONAL(GRAPHICS_WIN32, test "x${graphics_win32}" = "xyes")
931 AC_ARG_ENABLE(graphics-qt-qpainter, [ --disable-graphics-qt-qpainter disable graphics type qt-qpainter], graphics_qt_qpainter=$enableval;graphics_qt_qpainter_reason="configure parameter")
932 if test "x${graphics_qt_qpainter}" = "xyes" -a "x${QT_GUI_CFLAGS}" = "x" -a "x${QT_GUI_LIBS}" = "x"; then
933 PKG_CHECK_MODULES(QT_GUI, [QtGui QtCore],graphics_qt_qpainter=yes,graphics_qt_qpainter=no;graphics_qt_qpainter_reason="Packages QtGui and/or QtCore missing")
934 if test "x${graphics_qt_qpainter}" = "xno"; then
935 PKG_CHECK_MODULES(QT_GUI, [qt-mt],graphics_qt_qpainter=yes;graphics_qt_qpainter_reason="Package qt-mt present",graphics_qt_qpainter=no)
938 if test "x${graphics_qt_qpainter}" = "xyes" ; then
939 PKG_CHECK_MODULES(QT_SVG, [QtSvg], have_qt_svg=yes, have_qt_svg=no)
940 if test "x${have_qt_svg}" = "xyes"; then
941 AC_DEFINE([HAVE_QT_SVG],[],Define to 1 if qt supports svg)
944 if test "x${graphics_qt_qpainter}" = "xyes" ; then
945 AC_DEFINE(USE_GRAPICS_QT_QPAINTER, 1, [Build with graphics qt_qpainter])
947 AC_SUBST(QT_GUI_CFLAGS)
948 AC_SUBST(QT_GUI_LIBS)
949 AC_SUBST(QT_SVG_CFLAGS)
950 AC_SUBST(QT_SVG_LIBS)
951 AM_CONDITIONAL(GRAPHICS_QT_QPAINTER, test "x${graphics_qt_qpainter}" = "xyes")
952 MOC=`$PKG_CONFIG QtGui --variable=moc_location`
953 if test "x${MOC}" = "x"; then
954 AC_CHECK_PROG(MOC, moc, moc)
961 AC_ARG_ENABLE(map-binfile, [ --disable-map-binfile disable map binfile], map_binfile=$enableval;map_binfile_reason="configure parameter")
962 AM_CONDITIONAL(MAP_BINFILE, test "x${map_binfile}" = "xyes")
964 AC_ARG_ENABLE(map-filter, [ --disable-map-filter disable map filter], map_filter=$enableval;map_filter_reason="configure parameter")
965 AM_CONDITIONAL(MAP_FILTER, test "x${map_filter}" = "xyes")
967 AC_ARG_ENABLE(map-mg, [ --disable-map-mg disable map mg], map_mg=$enableval;map_mg_reason="configure parameter")
968 AM_CONDITIONAL(MAP_MG, test "x${map_mg}" = "xyes")
970 AC_ARG_ENABLE(map-shapefile, [ --disable-map-shapefile disable map shapefile], map_shapefile=$enableval;map_shapefile_reason="configure parameter")
971 AM_CONDITIONAL(MAP_SHAPEFILE, test "x${map_shapefile}" = "xyes")
973 AC_ARG_ENABLE(map-textfile, [ --disable-map-textfile disable map textfile], map_textfile=$enableval;map_textfile_reason="configure parameter")
974 AM_CONDITIONAL(MAP_TEXTFILE, test "x${map_textfile}" = "xyes")
976 AC_ARG_ENABLE(map-csv, [ --disable-map-csv disable map csv], map_csv=$enableval;map_csv_reason="configure parameter")
977 AM_CONDITIONAL(MAP_CSV, test "x${map_csv}" = "xyes")
981 AC_ARG_ENABLE(osd-core, [ --disable-osd-core disable osd core], osd_core=$enableval;osd_core_reason="configure parameter")
982 AM_CONDITIONAL(OSD_CORE, test "x${osd_core}" = "xyes")
986 AC_ARG_ENABLE(gui-gtk, [ --disable-gui-gtk disable gui type gtk ], gui_gtk=$enableval)
987 AM_CONDITIONAL(GUI_GTK, [test "x${gui_gtk}" = "xyes"])
989 AC_ARG_ENABLE(gui-internal, [ --disable-gui-internal disable gui type internal], gui_internal=$enableval;gui_internal_reason="configure parameter")
990 AM_CONDITIONAL(GUI_INTERNAL, test "x${gui_internal}" = "xyes")
992 AC_ARG_ENABLE(gui-win32, [ --disable-gui-win32 disable gui type win32], gui_win32=$enableval;gui_win32_reason="configure parameter")
993 AM_CONDITIONAL(GUI_WIN32, test "x${gui_win32}" = "xyes")
995 AC_ARG_ENABLE(gui-qml, [ --disable-gui-qml disable gui type QML], gui_qml=$enableval;gui_qml_reason="configure parameter")
996 if test "x${gui_qml}" = "xyes" -a "x${QT_GUI_CFLAGS}" = "x" -a "x${QT_GUI_LIBS}" = "x"; then
997 PKG_CHECK_MODULES(QT_GUI, [QtGui QtCore], ,gui_qml=no;gui_qml_reason="Packages QtGui and/or QtCore are missing")
999 if test "x${gui_qml}" = "xyes" -a "x${QT_XML_CFLAGS}" = "x" -a "x${QT_XML_LIBS}" = "x"; then
1000 PKG_CHECK_MODULES(QT_XML, [QtXml], ,gui_qml=no;gui_qml_reason="Package QtXml is missing")
1002 if test "x${gui_qml}" = "xyes" -a "x${QT_DECLARATIVE_CFLAGS}" = "x" -a "x${QT_DECLARATIVE_LIBS}" = "x"; then
1003 PKG_CHECK_MODULES(QT_DECLARATIVE, [QtDeclarative >= 4.6.0 ], ,gui_qml=no;gui_qml_reason="Packages QtDeclarative is missing")
1005 if test "x${gui_qml}" = "xyes" ; then
1006 AC_DEFINE(USE_GUI_QML, 1, [Build with gui qml])
1008 AC_SUBST(QT_GUI_CFLAGS)
1009 AC_SUBST(QT_GUI_LIBS)
1010 AC_SUBST(QT_DECLARATIVE_CFLAGS)
1011 AC_SUBST(QT_DECLARATIVE_LIBS)
1012 AC_SUBST(QT_XML_CFLAGS)
1013 AC_SUBST(QT_XML_LIBS)
1014 AM_CONDITIONAL(GUI_QML, test "x${gui_qml}" = "xyes")
1018 AC_ARG_ENABLE(plugin-pedestrian, [ --enable-plugin-pedestrian enable pedestrian plugin], plugin_pedestrian=$enableval;plugin_pedestrian_reason="configure parameter")
1019 AM_CONDITIONAL(PLUGIN_PEDESTRIAN, test "x${plugin_pedestrian}" = "xyes")
1022 AC_ARG_ENABLE(routing, [ --disable-routing disable routing], routing=$enableval;routing_reason="configure parameter")
1023 AM_CONDITIONAL(ROUTING, test "x${routing}" = "xyes")
1024 if test "x$routing" = "xyes"; then
1025 AC_DEFINE([USE_ROUTING],[1],Define to 1 if you want to have routing.)
1030 AC_ARG_ENABLE(speech-android, [ --disable-speech-android disable speech type android], speech_android=$enableval;speech_android_reason="configure parameter")
1031 AM_CONDITIONAL(SPEECH_ANDROID, test "x${speech_android}" = "xyes")
1033 AC_ARG_ENABLE(speech-cmdline, [ --disable-speech-cmdline disable speech type cmdline], speech_cmdline=$enableval;speech_cmdline_reason="configure parameter")
1034 AM_CONDITIONAL(SPEECH_CMDLINE, test "x${speech_cmdline}" = "xyes")
1036 AC_ARG_ENABLE(speech-espeak, [ --disable-speech-espeak disable speech type espeak], speech_espeak=$enableval;speech_espeak_reason="configure parameter")
1037 AM_CONDITIONAL(SPEECH_ESPEAK, test "x${speech_espeak}" = "xyes")
1039 AC_ARG_ENABLE(speech-speech-dispatcher, [ --disable-speech-speech-dispatcher disable speech type speech-dispatcher], speech_speech_dispatcher=$enableval;speech_speech_dispatcher_reason="configure parameter")
1040 if test "x$speech_speech_dispatcher" = "xyes"; then
1041 AC_CHECK_HEADER(libspeechd.h, AC_DEFINE([HAVE_LIBSPEECHD],[],Define to 1 if you have the <libspeechd.h> header file.) SPEECHD_LIBS="-lspeechd", speech_speech_dispatcher=no; speech_speech_dispatcher_reason="libspeechd.h missing")
1043 AC_SUBST(SPEECHD_CFLAGS)
1044 AC_SUBST(SPEECHD_LIBS)
1045 AM_CONDITIONAL(SPEECH_SPEECH_DISPATCHER, test "x${speech_speech_dispatcher}" = "xyes")
1046 AM_CONDITIONAL(SUPPORT_ESPEAK, test "x${support_espeak}" = "xyes")
1050 AC_ARG_ENABLE(vehicle-android, [ --disable-vehicle-android disable vehicle type android], vehicle_android=$enableval;vehicle_android_reason="configure parameter")
1051 AM_CONDITIONAL(VEHICLE_ANDROID, test "x${vehicle_android}" = "xyes")
1053 AC_ARG_ENABLE(vehicle-demo, [ --disable-vehicle-demo disable vehicle type demo], vehicle_demo=$enableval;vehicle_demo_reason="configure parameter")
1054 AM_CONDITIONAL(VEHICLE_DEMO, test "x${vehicle_demo}" = "xyes")
1056 AC_ARG_ENABLE(vehicle-file, [ --disable-vehicle-file disable vehicle type file], vehicle_file=$enableval;vehicle_file_reason="configure parameter")
1057 AM_CONDITIONAL(VEHICLE_FILE, test "x${vehicle_file}" = "xyes")
1059 AC_ARG_ENABLE(vehicle-gpsd, [ --disable-vehicle-gpsd disable vehicle type gpsd], vehicle_gpsd=$enableval;vehicle_gpsd_reason="configure parameter")
1060 if test "x${vehicle_gpsd}" = xyes
1062 PKG_CHECK_MODULES([GPSD], [libgps], have_libgps="yes", have_libgps="no")
1063 if test "x$have_libgps" = "xyes"; then
1064 AC_DEFINE([HAVE_LIBGPS],[],Define to 1 if you have libgps.)
1065 PKG_CHECK_MODULES([LIBGPS19], [libgps >= 2.90], have_libgps19="yes", have_libgps19="no")
1066 if test "x$have_libgps19" = "xyes"; then
1067 AC_DEFINE([HAVE_LIBGPS19],[],Define to 1 if you have libgps19.)
1070 AC_CHECK_HEADER(gps.h, AC_DEFINE([HAVE_LIBGPS],[],Define to 1 if you have the <gps.h> header file.) GPSD_LIBS="-lgps", vehicle_gpsd=no; vehicle_gpsd_reason="no gps.h and no gpsd pkgconfig" )
1073 AC_SUBST(GPSD_CFLAGS)
1075 AM_CONDITIONAL(VEHICLE_GPSD, [test "x${vehicle_gpsd}" = "xyes"])
1077 AC_ARG_ENABLE(vehicle-gypsy,[ --disable-vehicle-gypsy disable vehicle type gypsy], vehicle_gypsy=$enableval;vehicle_gypsy_reason="configure parameter")
1078 if test "x${vehicle_gypsy}" = "xyes"
1080 PKG_CHECK_MODULES(GYPSY, gypsy, ,vehicle_gypsy=no;vehicle_gypsy_reason="package gypsy missing")
1082 AC_SUBST(GYPSY_CFLAGS)
1083 AC_SUBST(GYPSY_LIBS)
1084 AM_CONDITIONAL(VEHICLE_GYPSY, test "x${vehicle_gypsy}" = "xyes")
1086 AC_ARG_ENABLE(vehicle-maemo, [ --disable-vehicle-maemo disable vehicle type maemo], vehicle_maemo=$enableval;vehicle_maemo_reason="configure parameter")
1087 if test "x${vehicle_maemo}" = "xyes" ; then
1088 PKG_CHECK_MODULES(LIBLOCATION, liblocation, [
1089 AC_SUBST(LIBLOCATION_CFLAGS)
1090 AC_SUBST(LIBLOCATION_LIBS)
1094 vehicle_maemo_reason="no maemo location library found"
1097 AM_CONDITIONAL(VEHICLE_MAEMO, test "x${vehicle_maemo}" = "xyes")
1099 AC_ARG_ENABLE(vehicle-null, [ --enable-vehicle-null enable vehicle type null], vehicle_null=$enableval;vehicle_null_reason="configure parameter")
1100 AM_CONDITIONAL(VEHICLE_NULL, test "x${vehicle_null}" = "xyes")
1102 AC_ARG_ENABLE(vehicle-wince, [ --disable-vehicle-wince disable vehicle type wince], vehicle_wince=$enableval;vehicle_wince_reason="configure parameter")
1103 AM_CONDITIONAL(VEHICLE_WINCE, test "x${vehicle_wince}" = "xyes")
1105 AC_ARG_ENABLE(vehicle-iphone, [ --disable-vehicle-iphone disable vehicle type iphone], vehicle_iphone=$enableval;vehicle_iphone_reason="configure parameter")
1106 AM_CONDITIONAL(VEHICLE_IPHONE, test "x${vehicle_iphone}" = "xyes")
1107 if test "x${vehicle_iphone}" = "xyes"
1109 IPHONE_LIBS=-Wl,-framework,CoreLocation
1111 AC_SUBST(IPHONE_CFLAGS)
1112 AC_SUBST(IPHONE_LIBS)
1114 AC_ARG_ENABLE(vehicle-webos, [ --enable-vehicle-webos enable vehicle type webos], vehicle_webos=$enableval;vehicle_webos_reason="configure parameter")
1115 AM_CONDITIONAL(VEHICLE_WEBOS, test "x${vehicle_webos}" = "xyes")
1116 if test "x${vehicle_webos}" = "xyes"
1118 AC_DEFINE(USE_WEBOS,[],Build with webOS support)
1119 LIBPDL_CFLAGS="$SDL_CFLAGS -I/usr/local/include"
1120 LIBPDL_LIBS="-L/usr/local/lib -lpdl"
1121 AC_SUBST(LIBPDL_CFLAGS)
1122 AC_SUBST(LIBPDL_LIBS)
1124 NAVIT_CFLAGS="$NAVIT_CFLAGS $GLIB_CFLAGS $GMODULE_CFLAGS"
1125 NAVIT_LIBS="$NAVIT_LIBS $GLIB_LIBS $GMODULE_LIBS $LIBINTL"
1126 AC_SUBST(NAVIT_CFLAGS)
1127 AC_SUBST(NAVIT_LIBS)
1128 AC_SUBST(WORDEXP_LIBS)
1135 navit/autoload/Makefile
1136 navit/autoload/osso/Makefile
1137 navit/binding/Makefile
1138 navit/binding/python/Makefile
1139 navit/binding/dbus/Makefile
1140 navit/binding/win32/Makefile
1142 navit/map/mg/Makefile
1143 navit/map/textfile/Makefile
1144 navit/map/csv/Makefile
1145 navit/map/shapefile/Makefile
1146 navit/map/filter/Makefile
1147 navit/map/binfile/Makefile
1148 navit/map/garmin/Makefile
1149 navit/maptool/Makefile
1150 navit/fib-1.1/Makefile
1152 navit/font/freetype/Makefile
1153 navit/fonts/Makefile
1154 navit/graphics/Makefile
1155 navit/graphics/android/Makefile
1156 navit/graphics/gd/Makefile
1157 navit/graphics/gtk_drawing_area/Makefile
1158 navit/graphics/opengl/Makefile
1159 navit/graphics/null/Makefile
1160 navit/graphics/sdl/Makefile
1161 navit/graphics/qt_qpainter/Makefile
1162 navit/graphics/win32/Makefile
1164 navit/gui/gtk/Makefile
1165 navit/gui/internal/Makefile
1166 navit/gui/win32/Makefile
1167 navit/gui/qml/Makefile
1168 navit/gui/qml/skins/Makefile
1169 navit/gui/qml/skins/navit/Makefile
1171 navit/osd/core/Makefile
1172 navit/plugin/Makefile
1173 navit/plugin/pedestrian/Makefile
1174 navit/speech/Makefile
1175 navit/speech/android/Makefile
1176 navit/speech/cmdline/Makefile
1177 navit/speech/dbus/Makefile
1178 navit/speech/espeak/Makefile
1179 navit/speech/speech_dispatcher/Makefile
1180 navit/support/Makefile
1181 navit/support/espeak/Makefile
1182 navit/support/ezxml/Makefile
1183 navit/support/glib/Makefile
1184 navit/support/libc/Makefile
1185 navit/support/libpng/Makefile
1186 navit/support/shapefile/Makefile
1187 navit/support/win32/Makefile
1188 navit/support/wordexp/Makefile
1189 navit/support/zlib/Makefile
1190 navit/vehicle/Makefile
1191 navit/vehicle/android/Makefile
1192 navit/vehicle/file/Makefile
1193 navit/vehicle/gpsd/Makefile
1194 navit/vehicle/gpsd_dbus/Makefile
1195 navit/vehicle/gypsy/Makefile
1196 navit/vehicle/maemo/Makefile
1197 navit/vehicle/null/Makefile
1198 navit/vehicle/demo/Makefile
1199 navit/vehicle/wince/Makefile
1200 navit/vehicle/iphone/Makefile
1201 navit/vehicle/webos/Makefile
1208 #src/data/garmin_img/Makefile
1215 echo "Summary of your installation :"
1216 # FIXME : maybe elaborate missing dependencies
1217 if test x"$graphics_sdl" != xyes
1219 sdl_failures="(libsdl maybe?) "
1221 if test x"$glut" != xyes
1223 sdl_failures=$sdl_failures"glut "
1225 if test x"$glc" != xyes
1227 sdl_failures=$sdl_failures"quesoglc "
1229 if test -z "$sdl_failures"
1231 echo "OpenGL gui : ENABLED, with $CEGUI_LIBS"
1233 echo "OpenGL gui : DISABLED : you are missing $sdl_failures"
1235 if test x"$enable_hildon" = xyes
1237 echo "Maemo/Hildon: ENABLED"
1239 echo "Maemo/Hildon: DISABLED"
1241 if test x"$enable_osso" = xyes
1243 echo "Maemo/OSSO: ENABLED"
1245 echo "Maemo/OSSO: DISABLED"
1247 if test x"${USE_GARMIN}" = xyes
1249 if test "x$use_libgarmin" = "xyes"
1251 echo "Garmin IMG : ENABLED"
1253 echo "Garmin IMG : DISABLED (you don't have libgarmin)"
1256 echo "Garmin IMG : DISABLED (you requested it)"
1259 if test x"$LIBINTL" = "x" ;then
1260 nls_libs="system gettext support"
1264 echo "Plugins: $plugins ($plugins_reason)"
1265 echo "Postgresql: $postgresql ($postgresql_reason)"
1266 echo "Samplemap: $samplemap ($samplemap_reason)"
1267 echo "NLS Support: $enable_nls ($nls_libs)"
1268 echo "Routing: $routing ($routing_reason)"
1269 echo "Font renderers:"
1270 echo " freetype: $font_freetype ($font_freetype_reason)"
1271 echo " FriBidi enabled: $fribidi ($fribidi_reason)"
1273 echo "Graphics types: $graphics ($graphics_reason)"
1274 echo " android: $graphics_android ($graphics_android_reason)"
1275 echo " gtk_drawing_area: $graphics_gtk_drawing_area ($graphics_gtk_drawing_area_reason)"
1276 echo " null: $graphics_null ($graphics_null_reason)"
1277 echo " qt_qpainter: $graphics_qt_qpainter ($graphics_qt_qpainter_reason)"
1278 echo " win32: $graphics_win32 ($graphics_win32_reason)"
1279 echo " OpenGL: $graphics_opengl ($graphics_opengl_reason)"
1280 echo " gd: $graphics_gd ($graphics_gd_reason)"
1281 echo " sdl: $graphics_sdl ($graphics_sdl_reason)"
1284 echo " gtk: $gui_gtk ($gui_gtk_reason)"
1285 echo " internal: $gui_internal ($gui_internal_reason)"
1286 echo " win32: $gui_win32 ($gui_win32_reason)"
1287 echo " qml: $gui_qml ($gui_qml_reason)"
1290 echo " binfile: $map_binfile ($map_binfile_reason)"
1291 echo " filter: $map_filter ($map_filter_reason)"
1292 echo " mg: $map_mg ($map_mg_reason)"
1293 echo " shapefile: $map_shapefile ($map_shapefile_reason)"
1294 echo " textfile: $map_textfile ($map_textfile_reason)"
1295 echo " csv: $map_csv ($map_csv_reason)"
1299 echo " dbus: $binding_dbus ($binding_dbus_reason)"
1300 echo " python: $binding_python ($binding_python_reason)"
1303 echo " core: $osd_core ($osd_core_reason)"
1306 echo " pedestrian: $plugin_pedestrian ($plugin_pedestrian_reason)"
1308 echo "Speech types:"
1309 echo " android: $speech_android ($speech_android_reason)"
1310 echo " cmdline: $speech_cmdline ($speech_cmdline_reason)"
1311 echo " dbus: $speech_dbus ($speech_dbus_reason)"
1312 echo " espeak: $speech_espeak ($speech_espeak_reason)"
1313 echo " speech_dispatcher: $speech_speech_dispatcher ($speech_speech_dispatcher_reason)"
1315 echo "Vehicle types:"
1316 echo " android: $vehicle_android ($vehicle_android_reason)"
1317 echo " demo: $vehicle_demo ($vehicle_demo_reason)"
1318 echo " file: $vehicle_file ($vehicle_file_reason)"
1319 echo " gpsd: $vehicle_gpsd ($vehicle_gpsd_reason)"
1320 echo " gpsd_dbus: $vehicle_gpsd_dbus ($vehicle_gpsd_dbus_reason)"
1321 echo " gypsy: $vehicle_gypsy ($vehicle_gypsy_reason)"
1322 echo " maemo: $vehicle_maemo ($vehicle_maemo_reason)"
1323 echo " null: $vehicle_null ($vehicle_null_reason)"
1324 echo " wince: $vehicle_wince ($vehicle_wince_reason)"
1325 echo " iphone: $vehicle_iphone ($vehicle_iphone_reason)"
1326 echo " webos: $vehicle_webos ($vehicle_webos_reason)"
1328 if test "x${gtk2_pkgconfig}" != "xyes" -a "x${gui_win32}" != "xyes" -a "x${gui_internal}" != "xyes" -a "x${gui_qml}" != "xyes"
1332 echo "*** WARNING! you have no gui that can be built! ***"
1333 echo "Please install the dependency for at least gtk or sdl gui"
1334 echo "For more details, see the wiki at http://wiki.navit-project.org/"
1338 echo "Support for autotools will be removed soon from navit, please use cmake instead"