summaryrefslogtreecommitdiff
path: root/m4/ax_lib_postgresql.m4
diff options
context:
space:
mode:
authorSree Harsha Totakura <sreeharsha@totakura.in>2014-10-15 11:12:25 +0200
committerPeter Simons <simons@cryp.to>2014-10-15 11:12:25 +0200
commitf6c5e7ac8c50fe2ad35aae176f518eb95f66c588 (patch)
tree366bce4cf4eaa4122c7850e9ebb55ca909ec1e8a /m4/ax_lib_postgresql.m4
parent3f13fe9cd7d45d3b0ab151320220842c54d26c6a (diff)
downloadautoconf-archive-f6c5e7ac8c50fe2ad35aae176f518eb95f66c588.tar.gz
AX_LIB_POSTGRESQL: substitute CPPFLAGS rather than CFLAGS
Diffstat (limited to 'm4/ax_lib_postgresql.m4')
-rw-r--r--m4/ax_lib_postgresql.m413
1 files changed, 7 insertions, 6 deletions
diff --git a/m4/ax_lib_postgresql.m4 b/m4/ax_lib_postgresql.m4
index 0bc5fb7..5e26071 100644
--- a/m4/ax_lib_postgresql.m4
+++ b/m4/ax_lib_postgresql.m4
@@ -27,7 +27,7 @@
#
# This macro calls:
#
-# AC_SUBST(POSTGRESQL_CFLAGS)
+# AC_SUBST(POSTGRESQL_CPPFLAGS)
# AC_SUBST(POSTGRESQL_LDFLAGS)
# AC_SUBST(POSTGRESQL_VERSION)
#
@@ -38,13 +38,14 @@
# LICENSE
#
# Copyright (c) 2008 Mateusz Loskot <mateusz@loskot.net>
+# Copyright (c) 2014 Sree Harsha Totakura <sreeharsha@totakura.in>
#
# Copying and distribution of this file, with or without modification, are
# permitted in any medium without royalty provided the copyright notice
# and this notice are preserved. This file is offered as-is, without any
# warranty.
-#serial 9
+#serial 10
AC_DEFUN([AX_LIB_POSTGRESQL],
[
@@ -65,7 +66,7 @@ AC_DEFUN([AX_LIB_POSTGRESQL],
[want_postgresql="yes"]
)
- POSTGRESQL_CFLAGS=""
+ POSTGRESQL_CPPFLAGS=""
POSTGRESQL_LDFLAGS=""
POSTGRESQL_VERSION=""
@@ -88,8 +89,8 @@ AC_DEFUN([AX_LIB_POSTGRESQL],
if test "$PG_CONFIG" != "no"; then
AC_MSG_CHECKING([for PostgreSQL libraries])
- POSTGRESQL_CFLAGS="-I`$PG_CONFIG --includedir`"
- POSTGRESQL_LDFLAGS="-L`$PG_CONFIG --libdir` -lpq"
+ POSTGRESQL_CPPFLAGS="-I`$PG_CONFIG --includedir`"
+ POSTGRESQL_LDFLAGS="-L`$PG_CONFIG --libdir`"
POSTGRESQL_VERSION=`$PG_CONFIG --version | sed -e 's#PostgreSQL ##'`
@@ -150,6 +151,6 @@ AC_DEFUN([AX_LIB_POSTGRESQL],
fi
AC_SUBST([POSTGRESQL_VERSION])
- AC_SUBST([POSTGRESQL_CFLAGS])
+ AC_SUBST([POSTGRESQL_CPPFLAGS])
AC_SUBST([POSTGRESQL_LDFLAGS])
])