summaryrefslogtreecommitdiffstats
path: root/m4/sql.m4
blob: 3a8b67ec6e5cf6e12b44a2d29cb6676f2d131601 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
AC_DEFUN([DOVECOT_SQL], [
  SQL_CFLAGS="$MYSQL_CFLAGS $PGSQL_CFLAGS $SQLITE_CFLAGS $CASSANDRA_CFLAGS"
  if test "$want_sql" != "plugin"; then
          SQL_LIBS="$MYSQL_LIBS $PGSQL_LIBS $SQLITE_LIBS $CASSANDRA_LIBS"
  else
          AC_DEFINE(SQL_DRIVER_PLUGINS,, [Build SQL drivers as plugins])
  fi
  sql_drivers=
  not_sql_drivers=
  
  if test "$found_sql_drivers" != "" || test "$want_sql" != "no"; then
          sql_drivers="$found_sql_drivers"
  
          AC_DEFINE(PASSDB_SQL,, [Build with SQL support])
          AC_DEFINE(USERDB_SQL,, [Build with SQL support])
          AUTH_LIBS="$AUTH_LIBS $SQL_LIBS"
          passdb="$passdb sql"
          userdb="$userdb sql"
  else
          not_passdb="$not_passdb sql"
          not_userdb="$not_userdb sql"
  fi
])