1
1
openmpi/opal/mca/db/postgres/configure.m4
Ralph Castain 12e4f8a71d Add support for postgres database
This commit was SVN r30337.
2014-01-20 19:56:26 +00:00

44 строки
1.6 KiB
Bash

dnl -*- shell-script -*-
dnl
dnl Copyright (c) 2012-2013 Los Alamos National Security, Inc. All rights reserved.
dnl Copyright (c) 2013 Intel, Inc. All rights reserved.
dnl $COPYRIGHT$
dnl
dnl Additional copyrights may follow
dnl
dnl $HEADER$
dnl
# MCA_db_postgres_CONFIG([action-if-found], [action-if-not-found])
# -----------------------------------------------------------
AC_DEFUN([MCA_opal_db_postgres_CONFIG], [
AC_CONFIG_FILES([opal/mca/db/postgres/Makefile])
AC_ARG_WITH([postgres],
[AC_HELP_STRING([--with-postgres],
[Build postgres support (default: no)])],
[], with_postgres=no)
# do not build if support not requested
AS_IF([test "$with_postgres" != "no"],
[AS_IF([test ! -z "$with_postgres" -a "$with_postgres" != "yes"],
[opal_check_postgres_dir="$with_postgres"])
OMPI_CHECK_PACKAGE([db_postgres],
[libpq-fe.h],
[pq],
[PQconnectdb],
[],
[$opal_check_postgres_dir],
[],
[$1],
[AC_MSG_WARN([POSTGRES DATABASE SUPPORT REQUESTED])
AC_MSG_WARN([BUT REQUIRED LIBRARY OR HEADER NOT FOUND])
AC_MSG_ERROR([CANNOT CONTINUE])
$2])],
[$2])
AC_SUBST(db_postgres_CPPFLAGS)
AC_SUBST(db_postgres_LDFLAGS)
AC_SUBST(db_postgres_LIBS)
])dnl