1 # Process this file with autoconf to produce a configure script.
2 AC_INIT(fGIS, 0.0.1, dron@remotesensing.org)
4 AM_CONFIG_HEADER(include/config.h)
6 dnl Checks for programs.
13 # Checks for libraries.
14 # FIXME: Replace `main' with a function in `-lX11':
15 # AC_CHECK_LIB([X11], [main])
16 # FIXME: Replace `main' with a function in `-ldl':
17 # AC_CHECK_LIB([dl], [main])
18 # FIXME: Replace `main' with a function in `-lefence':
19 # AC_CHECK_LIB([efence], [main])
20 # FIXME: Replace `main' with a function in `-lm':
21 # AC_CHECK_LIB([m], [main])
22 # FIXME: Replace `main' with a function in `-lproj':
23 # AC_CHECK_LIB([proj], [main])
25 # Checks for header files.
29 AC_CHECK_HEADERS([limits.h malloc.h stddef.h stdlib.h string.h strings.h unistd.h])
31 # Checks for typedefs, structures, and compiler characteristics.
36 # Checks for library functions.
44 AC_CHECK_FUNCS([bzero floor ftruncate memmove memset munmap re_comp regcomp sqrt strchr strdup strrchr strtol])
46 dnl ---------------------------------------------------------------------------
47 dnl Handle global configuration file placement
48 dnl ---------------------------------------------------------------------------
50 dnl FIXME: won't works
51 dnl AC_DEFINE_DIR(FGIS_CONFIG, "$sysconfdir", [Define this to the location of the global config file])
52 AC_SUBST_DIR(FGIS_CONFIG,"$sysconfdir")
53 AC_DEFINE_UNQUOTED(FGIS_CONFIG,"$FGIS_CONFIG",[Define this to the location of the global config file])
54 AC_SUBST(FGIS_CONFIG,$FGIS_CONFIG)
56 dnl ---------------------------------------------------------------------------
57 dnl Handle placement of the engine module (fgis.so)
58 dnl ---------------------------------------------------------------------------
60 AC_SUBST_DIR(FGIS_LIBDIR,"$libdir")
61 AC_SUBST(FGIS_LIBDIR,$FGIS_LIBDIR)
63 dnl ---------------------------------------------------------------------------
64 dnl Handle placement of the fGIS Tcl/Tk modules
65 dnl ---------------------------------------------------------------------------
67 AC_SUBST_DIR(FGIS_SCRIPTS,"$libdir/fgis/tcl")
68 AC_SUBST(FGIS_SCRIPTS,$FGIS_SCRIPTS)
70 dnl ---------------------------------------------------------------------------
71 dnl Define path for EPPL7 library sources. Temporary hack, the whole this
72 dnl library will be removed soon
73 dnl ---------------------------------------------------------------------------
75 AC_SUBST(LIBEPP,../lib/libepp.la)
77 dnl ---------------------------------------------------------------------------
78 dnl Check for Tcl/Tk installation
79 dnl ---------------------------------------------------------------------------
82 if test x"$no_tcl" = x"true" ; then
83 echo " ERROR: Can't find Tcl headers or library."
84 echo " See README for information on how to obtain Tcl."
85 echo " If Tcl is installed, see INSTALL on how to tell"
86 echo " configure where Tcl is installed."
91 AC_SUBST(TCL_INC_DIR,$TCL_INC_DIR)
92 AC_SUBST(TCL_PACKAGE_PATH,$TCL_PACKAGE_PATH)
97 AC_SUBST(TK_INC_DIR,$TK_INC_DIR)
98 if [[[ $TK_VERSION < "8.4" ]]]; then
99 AC_DEFINE([TK_84PREV], , [Define this variable if your Tk version less then 8.4])
102 AC_CONFIG_FILES([Makefile