aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Brunner <tobias@strongswan.org>2014-02-12 14:21:26 +0100
committerTobias Brunner <tobias@strongswan.org>2014-02-12 14:21:26 +0100
commit6e288ed19c15620c03f6cecbdf63cbf4152c4fe6 (patch)
treead77204733e78b48ba57f5cd828ddf356ab06c5c
parentb2cd0870a3379cc378cb460c6e66af788b62fed5 (diff)
downloadstrongswan-6e288ed19c15620c03f6cecbdf63cbf4152c4fe6.tar.bz2
strongswan-6e288ed19c15620c03f6cecbdf63cbf4152c4fe6.tar.xz
pool: Install SQL schemas from src/pool
This allows us to install the schemas if either the attr-sql or sql plugin is enabled, since both use the same schema (at least in parts).
-rw-r--r--src/Makefile.am4
-rw-r--r--src/libcharon/plugins/sql/Makefile.am3
-rw-r--r--src/pool/Makefile.am7
-rw-r--r--src/pool/mysql.sql (renamed from src/libcharon/plugins/sql/mysql.sql)0
-rw-r--r--src/pool/sqlite.sql (renamed from src/libcharon/plugins/sql/sqlite.sql)0
5 files changed, 11 insertions, 3 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 264a3cf37..f290d9c85 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -98,6 +98,10 @@ endif
if USE_ATTR_SQL
SUBDIRS += pool
+else
+if USE_SQL
+ SUBDIRS += pool
+endif
endif
if USE_TKM
diff --git a/src/libcharon/plugins/sql/Makefile.am b/src/libcharon/plugins/sql/Makefile.am
index 50b6dc393..fd5693123 100644
--- a/src/libcharon/plugins/sql/Makefile.am
+++ b/src/libcharon/plugins/sql/Makefile.am
@@ -17,6 +17,3 @@ libstrongswan_sql_la_SOURCES = \
sql_cred.h sql_cred.c sql_logger.h sql_logger.c
libstrongswan_sql_la_LDFLAGS = -module -avoid-version
-
-templatesdir = $(pkgdatadir)/templates/database/sql
-dist_templates_DATA = mysql.sql sqlite.sql
diff --git a/src/pool/Makefile.am b/src/pool/Makefile.am
index 8b429a4ba..2756f93a5 100644
--- a/src/pool/Makefile.am
+++ b/src/pool/Makefile.am
@@ -1,3 +1,5 @@
+if USE_ATTR_SQL
+
ipsec_PROGRAMS = pool
pool_SOURCES = \
@@ -14,3 +16,8 @@ AM_CPPFLAGS = \
pool_LDADD = \
$(top_builddir)/src/libstrongswan/libstrongswan.la \
$(top_builddir)/src/libhydra/libhydra.la
+
+endif !USE_ATTR_SQL
+
+templatesdir = $(pkgdatadir)/templates/database/sql
+dist_templates_DATA = mysql.sql sqlite.sql
diff --git a/src/libcharon/plugins/sql/mysql.sql b/src/pool/mysql.sql
index 1b437593d..1b437593d 100644
--- a/src/libcharon/plugins/sql/mysql.sql
+++ b/src/pool/mysql.sql
diff --git a/src/libcharon/plugins/sql/sqlite.sql b/src/pool/sqlite.sql
index 78012630b..78012630b 100644
--- a/src/libcharon/plugins/sql/sqlite.sql
+++ b/src/pool/sqlite.sql