summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorwoglinde <woglinde@ffa7fe5e-494d-0410-b361-a75ebd5db220>2011-07-20 21:44:43 +0000
committerwoglinde <woglinde@ffa7fe5e-494d-0410-b361-a75ebd5db220>2011-07-20 21:44:43 +0000
commit6d1601a75cd05045c717d03b1e4e285978440c52 (patch)
tree2224d2410e5ad19a94e29bb20dabb945f2b880c0 /configure.in
parent430f11705fc0bc4646a619a296d90ec9ed9be4c8 (diff)
downloadnavit-6d1601a75cd05045c717d03b1e4e285978440c52.tar.gz
Fix:map_shapefile:Rework the autotools support a bit, don't include shapefile in builtin.c fixes buildprocess with no plugin support
git-svn-id: http://svn.code.sf.net/p/navit/code/trunk/navit@4654 ffa7fe5e-494d-0410-b361-a75ebd5db220
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in34
1 files changed, 21 insertions, 13 deletions
diff --git a/configure.in b/configure.in
index 12ac158bc..95ec21f31 100644
--- a/configure.in
+++ b/configure.in
@@ -366,7 +366,7 @@ AM_CONDITIONAL(SUPPORT_ZLIB, [test "x$zlib" = "xno"])
AC_SUBST(ZLIB_CFLAGS)
AC_SUBST(ZLIB_LIBS)
-AC_CHECK_HEADER(sys/socket.h, AC_DEFINE([HAVE_SOCKET],[],Define to 1 if you have sockets))
+AC_CHECK_HEADER(sys/socket.h, AC_DEFINE([HAVE_SOCKET],[],Define to 2 if you have sockets))
AC_CHECK_HEADER(winsock2.h, AC_DEFINE([HAVE_WINSOCK],[],Define to 1 if you have Windows sockets))
# gtk
@@ -558,30 +558,38 @@ fi
AM_CONDITIONAL(GRAPHICS_OPENGL, [test "x$glut" = "xyes" -a "x$freeglut" = "xyes" -a "x$opengl" = "xyes" -a "x$freeimage" = "xyes" -a "x$glc" = "xyes" ])
+
system_shapefile=no
+if test x"${map_shapefile}" = xyes
+then
AC_CHECK_HEADERS(
[shapefil.h libshp/shapefil.h],
- AC_DEFINE(
+ [AC_DEFINE(
[HAVE_SYS_SHAPEFILELIB],
[1],
- Define to 1 if you have the <libshp/shapefil.h> header file.
- )
- system_shapefile_header=yes
+ Define to 1 if you have the <shapefil.h> header file.
+ )],
+ [SHAPEFILE_CFLAGS="-I\$(top_srcdir)/navit/support/shapefile"]
)
-if test x"${system_shapefile_header}" = xyes
+
+AC_CHECK_LIB(
+ [shp],
+ [DBFDeleteField],
+ [SHAPEFILE_LIBS="-lshp"
+ system_shapefile=yes],
+ [SHAPEFILE_LIBS="-L\$(top_builddir)/navit/support/shapefile -lsupport_shapefile"
+ system_shapefile=no]
+ )
+
+if test x"${system_shapefile}" = xno
then
- AC_CHECK_LIB([shp], [DBFDeleteField], [SHAPEFILE_LIBS="-lshp";HAVE_SYS_SHAPEFILELIB=0;system_shapefile=yes])
-else
- AC_MSG_WARN([*** No libshp/shapefil.h -- using included copy])
+ AC_MSG_WARN([*** The shapefile library(libshp) from the system is to old or not found! -- using included copy])
fi
+fi
AC_SUBST(SHAPEFILE_CFLAGS)
AC_SUBST(SHAPEFILE_LIBS)
AM_CONDITIONAL(HAVE_SYSTEM_SHAPEFILELIB, [test "x$system_shapefile" = "xyes" ])
-if test x"${system_shapefile}" = xno
-then
- AC_MSG_WARN([*** The shape library(libshp) from the system is to old! -- using included copy])
-fi
if test x"${USE_GARMIN}" = xyes
then