3 AM_CONFIG_HEADER(config.h)
7 m4_ifndef([AC_USE_SYSTEM_EXTENSIONS],
8 [AC_DEFUN([AC_USE_SYSTEM_EXTENSIONS], [AC_GNU_SOURCE])])
10 AC_USE_SYSTEM_EXTENSIONS
13 if eval "test x$GCC = xyes"; then
14 CFLAGS="$CFLAGS -Wall -Wcast-align -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wreturn-type -D_GNU_SOURCE"
19 if eval "test x$GXX = xyes"; then
20 CXXFLAGS="$CXXFLAGS -Wall -Wcast-align -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wreturn-type -D_GNU_SOURCE"
25 AC_ARG_ENABLE(plugins, [ --disable-plugins disable plugins],
37 Define to 1 if you have plugins.
44 AC_ARG_ENABLE(avoid-unaligned, [ --enable-avoid-unaligned avoid unaligned accesses], AVOID_UNALIGNED=$enableval, AVOID_UNALIGNED=no)
45 test x"${AVOID_UNALIGNED}" = xyes && AC_DEFINE(AVOID_UNALIGNED,[],Define to avoid unaligned access)
47 AC_ARG_ENABLE(avoid-float, [ --enable-avoid-float avoid floating point calculations], AVOID_FLOAT=$enableval, AVOID_FLOAT=no)
48 test x"${AVOID_FLOAT}" = xyes && AC_DEFINE(AVOID_FLOAT,[],Define to avoid floating point)
50 AC_ARG_ENABLE(hildon, [ --enable-hildon build with maemo/hildon support], enable_hildon=$enableval, enable_hildon=no)
51 if test "x${enable_hildon}" = "xyes" ; then
52 PKG_CHECK_MODULES(enable_hildon, hildon-libs >= 0.12.24, , [
56 if test x"${enable_hildon}" = xyes ; then
57 AC_DEFINE(USE_HILDON, 1, [Build with maemo/hildon support])
58 AC_SUBST(HILDON_CFLAGS)
62 AM_CONDITIONAL(USE_HILDON, test "${enable_hildon}" = "xyes")
64 AC_ARG_ENABLE(libgps, [ --disable-libgps don't use libgps], USE_LIBGPS=$enableval, USE_LIBGPS=yes)
65 AC_ARG_ENABLE(gypsy, [ --disable-gypsy don't use gypsy], USE_GYPSY=$enableval, USE_GYPSY=yes)
66 AC_ARG_ENABLE(garmin, [ --disable-garmin disable garmin support], USE_GARMIN=$enableval, USE_GARMIN=yes)
68 AC_ARG_ENABLE(samplemap, [ --disable-samplemap don't build the samplemap], samplemap=$enableval, samplemap=yes)
69 AM_CONDITIONAL(BUILD_SAMPLEMAP, [test "x$samplemap" = "xyes"])
71 AC_ARG_ENABLE(fastmath, [ --disable-fastmath don't build with fastmath], fastmath=$enableval, fastmath=yes)
72 AM_CONDITIONAL(FASTMATH, [test "x$fastmath" = "xyes"])
74 if test x"$fastmath" = xyes; then
75 if eval "test x$GCC = xyes"; then
76 CFLAGS="$CFLAGS -ffast-math"
80 X_CFLAGS="-I$x_includes"
81 AS_IF([test -n "$ac_x_libraries"], [X_LIBS="-L$ac_x_libraries"])
83 PKG_CHECK_MODULES(NAVIT, [glib-2.0 gmodule-2.0 gthread-2.0],
88 AC_MSG_WARN([glib-2.0 or gmodule-2.0 not found. Usually you need to install a package named glib2-devel or libglib2.0-dev])
90 NAVIT_CFLAGS="-I\$(top_srcdir)/navit/support -I\$(top_srcdir)/navit/support/glib -I\$(top_srcdir)/navit/support/ezxml"
91 NAVIT_LIBS="-L\$(top_builddir)/navit/support/glib -lsupport_glib -L\$(top_builddir)/navit/support/ezxml -lsupport_ezxml"
94 if test "x$glib" = "xyes"; then
95 AC_DEFINE(HAVE_GLIB, 1, [Define to 1 if you have (external) glib library])
97 AM_CONDITIONAL(EVENT_GLIB, [test "x$glib" = "xyes"])
98 AM_CONDITIONAL(SUPPORT_GLIB, [test "x$glib" = "xno"])
99 AM_CONDITIONAL(SUPPORT_EZXML, [test "x$glib" = "xno"])
100 AM_CONDITIONAL(DATA_POI_GEODOWNLOAD, [test "x$glib" = "xyes"])
107 Define to 1 if you have the <zlib.h> header file.
111 ZLIB_CFLAGS="-I\$(top_srcdir)/navit/support/zlib"
112 ZLIB_LIBS="-L\$(top_builddir)/navit/support/zlib -lsupport_zlib"
115 AM_CONDITIONAL(SUPPORT_ZLIB, [test "x$zlib" = "xno"])
116 AC_SUBST(ZLIB_CFLAGS)
119 AC_ARG_ENABLE(gui-gtk, [ --disable-gui-gtk don't create gui gtk ], MODULE_GUI_GTK=$enableval, MODULE_GUI_GTK=yes)
120 if test "x$MODULE_GUI_GTK" = "xyes"; then
121 PKG_CHECK_MODULES(GTK2, [gtk+-2.0], [gtk2_pkgconfig=yes], [gtk2_pkgconfig=no])
122 if test "x$gtk2_pkgconfig" = "xyes"; then
123 AC_DEFINE(HAVE_GTK2, 1, [Define to 1 if you have gtk2])
127 GTK2_CFLAGS="$GTK2_CFLAGS -DG_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"
129 AC_SUBST(GTK2_CFLAGS)
131 AM_CONDITIONAL(GUI_GTK, [test "x$gtk2_pkgconfig" = "xyes"])
132 AM_CONDITIONAL(GRAPHICS_GTK_DRAWING_AREA, [test "x$gtk2_pkgconfig" = "xyes"])
133 AM_CONDITIONAL(PLUGINS, [test "x$plugins" = "xyes"])
135 AC_ARG_ENABLE(directfb, [ --enable-directfb enable directfb gui and graphics], MODULE_DIRECTFB=$enableval, MODULE_DIRECTFB=no)
137 if test "x$MODULE_DIRECTFB" = "xyes"; then
138 PKG_CHECK_MODULES(DIRECTFB, [directfb], [directfb_pkgconfig=yes], [directfb_pkgconfig=no])
139 if test "x$directfb_pkgconfig" = "xyes"; then
140 AC_DEFINE(HAVE_DIRECTFB, 1, [Define to 1 if you have directfb])
144 DIRECTFB_CFLAGS="$DIRECTFB_CFLAGS"
146 #DIRECTFB_CFLAGS="-D_REENTRANT -I/data/oe/tmp/staging/arm-angstrom-linux-gnueabi/usr/include/directfb/"
147 #DIRECTFB_LIBS="-L/data/oe/tmp/staging/arm-angstrom-linux-gnueabi/usr/lib/ -ldirectfb -lfusion -ldirect -lpthread"
149 AC_SUBST(DIRECTFB_CFLAGS)
150 AC_SUBST(DIRECTFB_LIBS)
151 AM_CONDITIONAL(DIRECTFB, [test "x$directfb_pkgconfig" = "xyes"])
153 AC_ARG_ENABLE(graphics-qt-qpainter, [ --disable-graphics-qt-qpainter don't create graphics qt-qpainter], enable_graphics_qt_qpainter=$enableval, enable_graphics_qt_qpainter=yes)
154 if test "x${enable_graphics_qt_qpainter}" = "xyes" ; then
155 PKG_CHECK_MODULES(QT_GUI, [QtGui QtCore], ,enable_graphics_qt_qpainter=no)
157 if test "x${enable_graphics_qt_qpainter}" = "xyes" ; then
158 AC_DEFINE(USE_GRAPICS_QT_QPAINTER, 1, [Build with graphics qt_qpainter])
159 AC_SUBST(QT_GUI_CFLAGS)
160 AC_SUBST(QT_GUI_LIBS)
162 AM_CONDITIONAL(USE_GRAPHICS_QT_QPAINTER, test "x${enable_graphics_qt_qpainter}" = "xyes")
164 AC_ARG_ENABLE(graphics-sdl, [ --disable-graphics-sdl don't create graphics sdl], enable_graphics_sdl=$enableval, enable_graphics_sdl=yes)
165 if test "x${enable_graphics_sdl}" = "xyes" ; then
166 if test -z "$SDL_CONFIG"; then
167 AC_PATH_PROG([SDL_CONFIG], [sdl-config], [])
170 if test "x${enable_graphics_sdl}" = "xyes" ; then
171 AC_MSG_CHECKING([for SDL libraries with $SDL_CONFIG])
172 if test ! -x "$SDL_CONFIG"; then
173 enable_graphics_sdl = "no"
176 SDL_CFLAGS="`$SDL_CONFIG --cflags`"
177 SDL_LIBS="`$SDL_CONFIG --libs`"
183 if test "x${enable_graphics_sdl}" = "xyes" ; then
184 save_CPPFLAGS=$CPPFLAGS
185 CPPFLAGS="$($SDL_CONFIG --cflags) $CPPFLAGS"
186 AC_CHECK_HEADER(SDL_image.h,SDL_IMAGE_LIBS=-lSDL_image,enable_graphics_sdl=no)
187 AC_SUBST(SDL_IMAGE_LIBS)
188 CPPFLAGS=$save_CPPFLAGS
190 if test "x${enable_graphics_sdl}" = "xyes" ; then
191 AC_DEFINE(USE_GRAPICS_SDL, 1, [Build with graphics sdl])
193 AM_CONDITIONAL(USE_GRAPHICS_SDL, test "x${enable_graphics_sdl}" = "xyes")
195 AC_ARG_ENABLE(postgresql, [ --disable-postgresql don't add postgresql support to osm2navit], enable_postgresql=$enableval, enable_postgresql=yes)
196 if test "x${enable_postgresql}" = "xyes" ; then
197 if test -z "$PG_CONFIG"; then
198 AC_PATH_PROG([PG_CONFIG], [pg_config], [])
200 AC_MSG_CHECKING([for PostgreSQL libraries with $PG_CONFIG])
201 if test ! -x "$PG_CONFIG"; then
202 enable_postgresql = "no"
205 POSTGRESQL_CFLAGS="-I`$PG_CONFIG --includedir`"
206 POSTGRESQL_LIBS="-L`$PG_CONFIG --libdir` -lpq"
207 AC_DEFINE(HAVE_POSTGRESQL, 1, [Postgresql libraries available])
208 AC_SUBST(POSTGRESQL_CFLAGS)
209 AC_SUBST(POSTGRESQL_LIBS)
213 AM_CONDITIONAL(HAVE_POSTGRESQL, test "x${enable_postgresql}" = "xyes")
215 PKG_CHECK_MODULES(FREETYPE2, [freetype2], [freetype2_pkgconfig=yes], [freetype2_pkgconfig=no])
216 if test "x$freetype2_pkgconfig" = "xyes"; then
217 AC_DEFINE(HAVE_FREETYPE2, 1, [Define to 1 if you have freetype2])
219 AC_SUBST(FREETYPE2_CFLAGS)
220 AC_SUBST(FREETYPE2_LIBS)
222 PKG_CHECK_MODULES(FONTCONFIG, [fontconfig], [fontconfig_pkgconfig=yes], [fontconfig_pkgconfig=no])
223 if test "x$fontconfig_pkgconfig" = "xyes"; then
224 AC_DEFINE(HAVE_FONTCONFIG, 1, [Define to 1 if you have fontconfig])
226 AC_SUBST(FONTCONFIG_CFLAGS)
227 AC_SUBST(FONTCONFIG_LIBS)
229 PKG_CHECK_MODULES(IMLIB2, [imlib2], [imlib2_pkgconfig=yes], [imlib2_pkgconfig=no])
230 if test "x$imlib2_pkgconfig" = "xyes"; then
231 AC_DEFINE(HAVE_IMLIB2, 1, [Define to 1 if you have imlib2])
233 AC_SUBST(IMLIB2_CFLAGS)
234 AC_SUBST(IMLIB2_LIBS)
238 AC_ARG_ENABLE(gui-sdl, [ --disable-gui-sdl don't create gui sdl ], MODULE_GUI_SDL=$enableval, MODULE_GUI_SDL=yes)
239 if test "x$MODULE_GUI_SDL" = "xyes"; then
245 Define to 1 if you have the <SDL/SDL.h> header file.
249 AC_MSG_WARN([*** no SDL/SDL.h -- SDL support disabled])
255 [CEGUI-OPENGL >= 0.5.0],
260 [Define to 1 if you have the @<:@CEGUI/CEGUI.h@:>@ header file.])
263 [AC_MSG_WARN([*** CEGUI not found -- SDL support disabled])]
271 Define to 1 if you have the <X11/Xmu/Xmu.h> header file.
274 AC_MSG_WARN([*** no X11/Xmu/Xmu.h -- opengl and SDL support disabled])
282 Define to 1 if you have the <GL/gl.h> header file.
284 OPENGL_LIBS="$X_LIBS -lGL -lGLU"
286 AC_MSG_WARN([*** no GL/gl.h -- opengl and SDL support disabled])
294 Define to 1 if you have the <GL/glut.h> header file.
297 AC_MSG_WARN([*** no GL/glut.h -- opengl and SDL support disabled])
300 AC_SUBST(OPENGL_CFLAGS)
301 AC_SUBST(OPENGL_LIBS)
308 Define to 1 if you have the <GL/glc.h> header file.
312 AC_MSG_WARN([*** no GL/glc.h -- opengl and SDL support disabled])
317 if test x"$cegui" = xyes
319 # Save the LIBS into a temp var since AC_CHECK_LIB adds the lib into LIBS
320 # and we want just to check and use CEGUI_LIBS
322 # For CEGUI, we have to check the presence of some libraries.
323 # The following are mandatory (used by navit)
324 # If the user installed NavIt without, issue a warning and disable CEGUI
325 AC_CHECK_LIB(CEGUIBase, main,
328 echo "Error! Something is wrong with CEGUIBase. Do you have at least cegui-0.5?"
330 AC_CHECK_LIB(CEGUIOpenGLRenderer, main,
333 echo "Error! Something is wrong with CEGUIOpenGLRenderer. Do you have at least cegui-0.5? "
335 AC_CHECK_LIB(CEGUIFalagardWRBase, main,
338 echo "Error! Something is wrong with CEGUIFalagardWRBase. Do you have at least cegui-0.5?"
340 CEGUI_LIBS="-lCEGUIBase -lCEGUIOpenGLRenderer -lCEGUIFalagardWRBase"
342 # The following are optional, but we need to link against them if cegui was built with them
343 AC_CHECK_LIB(CEGUIXercesParser, main,
344 [CEGUI_LIBS="$CEGUI_LIBS -lCEGUIXercesParser"],
345 [echo "CEGUIXercesParser not found/not working, disabled."],
349 AC_CHECK_LIB(CEGUIExpatParser, main,
350 [CEGUI_LIBS="$CEGUI_LIBS -lCEGUIExpatParser"],
351 [echo "CEGUIExpatParser not found/not working, disabled."],
355 AC_CHECK_LIB(CEGUILibxmlParser, main,
356 [CEGUI_LIBS="$CEGUI_LIBS -lCEGUILibxmlParser"],
357 [echo "CEGUILibxmlParser not found/not working, disabled."],
361 AC_CHECK_LIB(CEGUITinyXMLParser, main,
362 [CEGUI_LIBS="$CEGUI_LIBS -lCEGUITinyXMLParser"],
363 [echo "CEGUITinyXMLParser not found/not working, disabled."],
367 AC_CHECK_LIB(CEGUIDevILImageCodec, main,
369 CEGUI_LIBS="$CEGUI_LIBS -lCEGUIDevILImageCodec"
370 AC_DEFINE([HAVE_LIBCEGUIDEVILIMAGECODEC],[1],Define to 1 to use DevIL codec)
372 [echo "CEGUIDevILImageCodec not found/not working, disabled."],
376 AC_CHECK_LIB(CEGUITGAImageCodec, createImageCodec,
378 CEGUI_LIBS="$CEGUI_LIBS -lCEGUITGAImageCodec"
379 AC_DEFINE(HAVE_LIBCEGUITGAIMAGECODEC,[1],Define to 1 to use the TGA codec)
381 [echo "GUITGAImageCodec not found/not working, disabled."],
385 libssilly="$OPENGL_LIBS -lpng"
386 AC_CHECK_LIB(CEGUISILLYImageCodec, createImageCodec,
388 CEGUI_LIBS="$CEGUI_LIBS -lCEGUISILLYImageCodec"
389 AC_DEFINE([HAVE_LIBCEGUISILLYIMAGECODEC],[1],Define to 1 to use SILLY codec)
391 [echo "CEGUISILLYImageCodec not found/not working, disabled."],
396 echo "CEGUI_LIBS : $CEGUI_LIBS"
399 AC_SUBST(CEGUI_CFLAGS)
402 AM_CONDITIONAL(GUI_SDL, [test "x$sdl" = "xyes" -a "x$cegui" = "xyes" -a "x$opengl" = "xyes" -a "x$glc" = "xyes" -a "x$xmu" = "xyes" ])
403 AM_CONDITIONAL(GRAPHICS_OPENGL, [test "x$opengl" = "xyes" -a "x$glc" = "xyes" ])
405 AC_ARG_ENABLE(gui-clutter, [ --disable-gui-clutter don't create gui clutter ], MODULE_GUI_CLUTTER=$enableval, MODULE_GUI_CLUTTER=yes)
406 if test "x$MODULE_GUI_CLUTTER" = "xyes"; then
407 PKG_CHECK_MODULES(CLUTTER, [clutter-0.8], [clutter_pkgconfig=yes], [clutter_pkgconfig=no])
408 if test "x$clutter_pkgconfig" = "xyes"; then
409 AC_DEFINE(HAVE_CLUTTER, 1, [Define to 1 if you have clutter])
413 AC_SUBST(CLUTTER_CFLAGS)
414 AC_SUBST(CLUTTER_LIBS)
415 AM_CONDITIONAL(GUI_CLUTTER, [test "x$clutter_pkgconfig" = "xyes" -a "x$glc" = "xyes" ])
418 if test x"${USE_GYPSY}" = xyes
420 PKG_CHECK_MODULES(GYPSY, gypsy, use_gypsy=yes, use_gypsy=no)
421 AC_SUBST(GYPSY_CFLAGS)
424 AM_CONDITIONAL(VEHICLE_GYPSY, [test "x$use_gypsy" = "xyes"])
426 if test x"${USE_LIBGPS}" = xyes
428 AC_CHECK_HEADER(gps.h, AC_DEFINE([HAVE_LIBGPS],[],Define to 1 if you have the <gps.h> header file.) GPSD_LIBS="-lgps" gpsd=yes, AC_MSG_WARN([*** no gps.h -- gpsd support disabled]))
430 AC_SUBST(GPSD_CFLAGS)
432 AM_CONDITIONAL(VEHICLE_GPSD, [test "x$gpsd" = "xyes"])
434 if test x"${USE_GARMIN}" = xyes
436 # check for libgarmin
437 PKG_CHECK_MODULES(LIBGARMIN, libgarmin, use_libgarmin=yes, use_libgarmin=no)
438 AC_SUBST(LIBGARMIN_CFLAGS)
439 AC_SUBST(LIBGARMIN_LIBS)
441 AM_CONDITIONAL(HAVELIBGARMIN, [test "x$use_libgarmin" = "xyes"])
445 AC_ARG_ENABLE(binding-python, [ --disable-binding-python don't create binding python], enable_binding_python=$enableval, enable_binding_python=yes)
446 if test "x${enable_binding_python}" = "xyes" ; then
447 if test "x${cross_compiling}" = "xyes" ; then
448 AC_MSG_WARN([*** cross compiling, support for python disabled])
449 enable_binding_python="no"
452 if test "x${enable_binding_python}" = "xyes"; then
453 AC_PATH_PROG(_PATH_PYTHON,[python])
454 dnl Libraries and flags for embedded Python.
455 dnl FIXME: I wish there was a less icky way to get this.
456 if test "x${_PATH_PYTHON}" != "x" ; then
457 AC_MSG_CHECKING(for Python linkage)
458 py_prefix=`$_PATH_PYTHON -c 'import sys; print sys.prefix'`
459 py_ver=`$_PATH_PYTHON -c 'import sys; print sys.version[[:3]]'`
460 py_libdir="${py_prefix}/lib/python${py_ver}"
461 PYTHON_CFLAGS="-I${py_prefix}/include/python${py_ver}"
462 if test -f $py_libdir/config/Makefile -a -f $py_prefix/include/python${py_ver}/Python.h; then
463 py_libs=`grep '^LIBS=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
464 py_libc=`grep '^LIBC=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
465 py_libm=`grep '^LIBM=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
466 py_liblocalmod=`grep '^LOCALMODLIBS=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
467 py_libbasemod=`grep '^BASEMODLIBS=' $py_libdir/config/Makefile | sed -e 's/^.*=//'`
468 PYTHON_LIBS="-L$py_libdir/config $py_libs $py_libc $py_libm -lpython$py_ver $py_liblocalmod $py_libbasemod"
469 PYTHON_LIBS=`echo $PYTHON_LIBS | sed -e 's/[ \\t]*/ /g'`
470 AC_MSG_RESULT($py_libdir)
472 AC_MSG_WARN([$py_libdir/config/Makefile or $py_prefix/include/python${py_ver}/Python.h missing, support for python disabled])
473 enable_binding_python="no"
476 AC_MSG_WARN([no python found, support for python disabled])
477 enable_binding_python="no"
480 if test "x${enable_binding_python}" = xyes ; then
481 AC_DEFINE(USE_BINDING_PYTHON, 1, [Build with binding python])
482 AC_SUBST(PYTHON_CFLAGS)
483 AC_SUBST(PYTHON_LIBS)
485 AM_CONDITIONAL(USE_BINDING_PYTHON, test "x${enable_binding_python}" = "xyes")
488 AC_ARG_ENABLE(binding-dbus, [ --disable-binding-dbus don't create binding dbus], enable_binding_dbus=$enableval, enable_binding_dbus=yes)
489 if test "x${enable_binding_dbus}" = "xyes" ; then
490 PKG_CHECK_MODULES(DBUS, [dbus-glib-1], ,enable_binding_dbus=no)
492 if test "x${enable_binding_dbus}" = "xyes" ; then
493 AC_DEFINE(USE_BINDING_DBUS, 1, [Build with binding dbus])
494 AC_SUBST(DBUS_CFLAGS)
497 AM_CONDITIONAL(USE_BINDING_DBUS, test "x${enable_binding_dbus}" = "xyes")
500 AC_ARG_ENABLE(svg, [ --disable-svg disable Scalable Vector Graphics], enable_svg=$enableval, enable_svg=yes)
501 AC_ARG_ENABLE(svg2png, [ --disable-svg2png disable conversion of svgs to pngs], enable_svg2png=$enableval, enable_svg2png=yes)
502 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")
503 if test "x${enable_svg2png}" = "xyes" ; then
504 AC_PATH_PROG([KSVGTOPNG], [ksvgtopng], [])
505 if test ! -x "$KSVGTOPNG"; then
509 AC_SUBST(SVG2PNG_SCALES)
510 AM_CONDITIONAL(USE_SVG2PNG_SCALES, test "x${SVG2PNG_SCALES}" != "xyes" -a "x${SVG2PNG_SCALES}" != "x")
511 AM_CONDITIONAL(USE_SVG2PNG, test "x${enable_svg2png}" = "xyes")
512 AM_CONDITIONAL(USE_SVG, test "x${enable_svg}" = "xyes")
517 [ --disable-nls disable Native Language Support ( gettext/libintl )],
518 enable_nls=$enableval, enable_nls=yes)
526 if test x$enable_nls = xyes; then
528 AC_CHECK_FUNC(gettext, [HAVEGETTEXT="yes"],
529 AC_CHECK_LIB(intl, gettext, [INTLIBS="-lintl" HAVEGETTEXT="yes"],
532 AC_CHECK_PROG(XGETTEXT, xgettext, xgettext)
533 AC_CHECK_PROG(MSGMERGE, msgmerge, msgmerge)
534 AC_CHECK_PROG(MSGFMT, msgfmt, msgfmt)
536 if test "$XGETTEXT" != ""; then
537 if $XGETTEXT --help 2>&1 | grep illegal >/dev/null ; then
538 echo "xgettext isn't GNU version"
543 if test "$XGETTEXT" != "" -a "$HAVEGETTEXT" != ""; then
545 if test "$LINGUAS" = ""; then
546 ling=` (cd $srcdir/po; /bin/ls *.po) `
548 lcode=`basename $l .po`
549 LINGUAS="$LINGUAS$lcode "
552 AC_DEFINE(ENABLE_NLS, [1], [NLS Please])
553 echo "xgettext and gettext() exist; will build i18n support for $LINGUAS"
557 echo "xgettext and libintl.a don't both exist; will not build i18n support"
559 for lang in $LINGUAS; do
560 MOFILES="$MOFILES $lang.mo"
562 for lang in $LINGUAS; do
563 POFILES="$POFILES $lang.po"
572 [Define to 1 if you have byteswap.h],
580 AM_GNU_GETTEXT_VERSION
583 LIBS="$LIBS -lm -rdynamic"
586 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
587 AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
591 if test "x${cross_compiling}" = "xyes"; then
592 AC_MSG_CHECKING([for a C compiler for build tools])
593 AC_CHECK_PROGS(CC_FOR_BUILD, gcc cc)
597 CCLD_FOR_BUILD="$CC_FOR_BUILD"
599 AC_SUBST(cross_compiling)
600 AC_SUBST(CC_FOR_BUILD)
601 AC_SUBST(CCLD_FOR_BUILD)
603 AC_CHECK_HEADER(wordexp.h,wordexp_h=yes,wordexp_h=no;NAVIT_CFLAGS="$NAVIT_CFLAGS -I\$(top_srcdir)/navit/support/wordexp";NAVIT_LIBS="$NAVIT_LIBS -L\$(top_builddir)/navit/support/wordexp -lsupport_wordexp")
604 AM_CONDITIONAL(SUPPORT_WORDEXP, [test "x$wordexp_h" = "xno"])
611 AC_DEFINE(HAS_WIN32_CE, 1, [Has Windows CE API])
614 if test "x$win32" = "xyes"
616 NAVIT_CFLAGS="$NAVIT_CFLAGS -I\$(top_srcdir)/navit/support/win32"
617 NAVIT_LIBS="$NAVIT_LIBS -L\$(top_builddir)/navit/support/win32 -lsupport_win32"
619 AM_CONDITIONAL(SUPPORT_WIN32, [test "x$win32" = "xyes"])
622 AC_ARG_ENABLE(gui-internal, [ --disable-gui-internal disable gui type internal], gui_internal=$enableval;gui_internal_reason="configure parameter", gui_internal=yes; gui_internal_reason="default")
623 AM_CONDITIONAL(GUI_INTERNAL, test "x${gui_internal}" = "xyes")
626 AC_ARG_ENABLE(speech-cmdline, [ --disable-speech-cmdline disable speech type cmdline], speech_cmdline=$enableval;speech_cmdline_reason="configure parameter", speech_cmdline=yes; speech_cmdline_reason=default)
627 AM_CONDITIONAL(SPEECH_CMDLINE, test "x${speech_cmdline}" = "xyes")
628 AC_ARG_ENABLE(speech-speechd, [ --disable-speech-speech-dispatcher disable speech type speech-dispatcher], speech_speech_dispatcher=$enableval;speech_speech_dispatcher_reason="configure parameter", speech_speech_dispatcher=yes; speech_speech_dispatcher_reason=default)
629 if test "x$speech_speech_dispatcher" = "xyes"; then
630 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")
632 AC_SUBST(SPEECHD_CFLAGS)
633 AC_SUBST(SPEECHD_LIBS)
634 AM_CONDITIONAL(SPEECH_SPEECH_DISPATCHER, test "x${speech_speech_dispatcher}" = "xyes")
637 AC_ARG_ENABLE(vehicle-demo, [ --disable-vehicle-demo disable vehicle type demo], vehicle_demo=$enableval;vehicle_demo_reason="configure parameter", vehicle_demo=yes; vehicle_demo_reason="default")
638 AM_CONDITIONAL(VEHICLE_DEMO, test "x${vehicle_demo}" = "xyes")
639 AC_ARG_ENABLE(vehicle-file, [ --disable-vehicle-file disable vehicle type file], vehicle_file=$enableval;vehicle_file_reason="configure parameter", vehicle_file=yes; vehicle_file_reason="default")
640 AM_CONDITIONAL(VEHICLE_FILE, test "x${vehicle_file}" = "xyes")
642 NAVIT_CFLAGS="$NAVIT_CFLAGS -I\$(top_builddir)/intl"
643 NAVIT_LIBS="$NAVIT_LIBS -L\$(top_builddir)/intl"
644 AC_SUBST(NAVIT_CFLAGS)
650 navit/binding/Makefile
651 navit/binding/python/Makefile
652 navit/binding/dbus/Makefile
654 navit/data/mg/Makefile
655 navit/data/textfile/Makefile
656 navit/data/binfile/Makefile
657 navit/data/garmin/Makefile
658 navit/data/poi_geodownload/Makefile
659 navit/data/poi_geodownload/libmdb/Makefile
660 navit/data/poi_geodownload/libmdb/include/Makefile
661 navit/fib-1.1/Makefile
662 navit/graphics/Makefile
663 navit/graphics/gtk_drawing_area/Makefile
664 navit/graphics/directfb/Makefile
665 navit/graphics/cogl/Makefile
666 navit/graphics/opengl/Makefile
667 navit/graphics/null/Makefile
668 navit/graphics/sdl/Makefile
669 navit/graphics/qt_qpainter/Makefile
671 navit/gui/gtk/Makefile
672 navit/gui/internal/Makefile
673 navit/gui/clutter/Makefile
674 navit/gui/cegui/Makefile
675 navit/gui/cegui/datafiles/Makefile
676 navit/gui/directfb/Makefile
678 navit/osd/core/Makefile
679 navit/speech/Makefile
680 navit/speech/cmdline/Makefile
681 navit/speech/speech_dispatcher/Makefile
682 navit/support/Makefile
683 navit/support/ezxml/Makefile
684 navit/support/glib/Makefile
685 navit/support/win32/Makefile
686 navit/support/wordexp/Makefile
687 navit/support/zlib/Makefile
688 navit/vehicle/Makefile
689 navit/vehicle/file/Makefile
690 navit/vehicle/gpsd/Makefile
691 navit/vehicle/gypsy/Makefile
692 navit/vehicle/demo/Makefile
698 #src/data/garmin_img/Makefile
705 echo "Summary of your installation :"
706 if test x"$gtk2_pkgconfig" = xyes
708 echo "GTK gui : ENABLED"
710 echo "GTK gui : DISABLED : you are missing a dependency. To fix this install a package named gtk2-devel or libgtk2.0-dev"
712 # FIXME : maybe elaborate missing dependencies
713 if test x"$sdl" != xyes
715 sdl_failures="(libsdl maybe?) "
717 if test x"$xmu" != xyes
719 sdl_failures=$sdl_failures"libxmu "
721 if test x"$glut" != xyes
723 sdl_failures=$sdl_failures"glut "
725 if test x"$glc" != xyes
727 sdl_failures=$sdl_failures"quesoglc "
729 if test x"$cegui" != xyes
731 sdl_failures=$sdl_failures"cegui-devel >= 0.5 "
733 if test -z "$sdl_failures"
735 echo "OpenGL gui : ENABLED, with $CEGUI_LIBS"
737 echo "OpenGL gui : DISABLED : you are missing $sdl_failures"
739 if test x"$directfb_pkgconfig" = xyes
741 echo "DIRECTFB : ENABLED"
743 echo "DIRECTFB : DISABLED"
745 if test x"$clutter_pkgconfig" = xyes
747 echo "Clutter gui : ENABLED"
749 echo "Clutter gui : DISABLED"
751 if test x"$enable_hildon" = xyes
753 echo "Maemo/Hildon: ENABLED"
755 echo "Maemo/Hildon: DISABLED"
758 if test x"$use_gypsy" = xyes
760 echo "Gypsy support: ENABLED"
762 echo "Gypsy support: DISABLED"
764 if test x"$gpsd" = xyes
766 echo "GPSD support: ENABLED"
768 echo "GPSD support: DISABLED"
770 if test x"${USE_GARMIN}" = xyes
772 if test "x$use_libgarmin" = "xyes"
774 echo "Garmin IMG : ENABLED"
776 echo "Garmin IMG : DISABLED (you don't have libgarmin)"
779 echo "Garmin IMG : DISABLED (you requested it)"
781 if test "x$samplemap" = "xyes"
783 echo "Samplemap : ENABLED"
785 echo "Samplemap : DISABLED"
790 echo " internal: $gui_internal ($gui_internal_reason)"
793 echo " cmdline: $speech_cmdline ($speech_cmdline_reason)"
794 echo " speech_dispatcher: $speech_speech_dispatcher ($speech_speech_dispatcher_reason)"
796 echo "Vehicle types:"
797 echo " demo: $vehicle_demo ($vehicle_demo_reason)"
798 echo " file: $vehicle_file ($vehicle_file_reason)"
800 if [ test x"$gtk2_pkgconfig" != xyes ] && [ test x"$sdl" != xyes ] && [ test x"$directfb_pkgconfig" != xyes ]
804 echo "*** WARNING! you have no gui that can be built! ***"
805 echo "Please install the dependency for at least gtk or sdl gui"
806 echo "For more details, see the wiki at http://wiki.navit-project.org/"