]> granicus.if.org Git - postgis/commitdiff
Fix for missing include directory on Mingw (#1158). Thanks Bryce Nordgren.
authorSandro Santilli <strk@keybit.net>
Sun, 14 Aug 2011 19:47:04 +0000 (19:47 +0000)
committerSandro Santilli <strk@keybit.net>
Sun, 14 Aug 2011 19:47:04 +0000 (19:47 +0000)
git-svn-id: http://svn.osgeo.org/postgis/trunk@7748 b70326c6-7e19-0410-871a-916f4a2858ee

configure.ac

index 0ee32daac7bf990c46e3c802eaec8fff41ea8386..eaa932e028ecc43cc8699e8b86577e48292c302c 100644 (file)
@@ -358,7 +358,14 @@ AC_SUBST([PGSQL_FE_LDFLAGS])
 AC_SUBST([PGSQL_FE_CPPFLAGS])
 
 dnl Extract the include flags for the backend (libpgcommon)
-PGSQL_BE_CPPFLAGS=-I`$PGCONFIG --includedir-server`
+PGSRV_INC=`$PGCONFIG --includedir-server`
+PGSQL_BE_CPPFLAGS="-I${PGSRV_INC}"
+dnl Add $PGSRV_INC/port/win32 to MinGW build to pick up netdb.h
+case $host in
+       *mingw32*)
+               PGSQL_BE_CPPFLAGS="${PGSQL_BE_CPPFLAGS} -I${PGSRV_INC}/port/win32"
+               ;;
+esac
 
 AC_SUBST([PGSQL_BE_CPPFLAGS])