Commit 43320cb1 authored by Simon Morlat's avatar Simon Morlat

fix sqlite3 dependency (automake)

parent 44dbc61d
......@@ -31,14 +31,17 @@ if test "$bctoolbox_found" != "yes" ; then
AC_MSG_ERROR([bctoolbox not found, aborting. ])
fi
dnl check libxml2
PKG_CHECK_MODULES(LIBXML2, [libxml-2.0] ,[libxml2_found=yes] ,foo=bar)
if test "$libxml2_found" != "yes" ; then
AC_MSG_WARN([libxml2 not found. Disabling cache.])
dnl check for sqlite
PKG_CHECK_MODULES(SQLITE3,[sqlite3 >= 3.6.0],[found_sqlite=yes],[found_sqlite=no])
if test "$found_sqlite" != "yes" ; then
AC_MSG_WARN([sqlite3 not found. Disabling cache.])
else
AC_DEFINE(HAVE_LIBXML2,1,[defined when libxml2 is available])
AC_DEFINE(ZIDCACHE_ENABLED,1,[defined when libxml2 is available])
fi
AC_ARG_ENABLE(tests,
[AS_HELP_STRING([--disable-tests], [Disable compilation of tests])],
[case "${enableval}" in
......
lib_LTLIBRARIES = libbzrtp.la
libbzrtp_la_LIBADD= $(LIBXML2_LIBS) $(BCTOOLBOX_LIBS)
libbzrtp_la_LIBADD= $(LIBSQLITE3_LIBS) $(BCTOOLBOX_LIBS)
libbzrtp_la_SOURCES= bzrtp.c cryptoUtils.c packetParser.c zidCache.c stateMachine.c pgpwords.c
AM_CPPFLAGS= -I$(top_srcdir)/include
AM_CFLAGS= $(LIBXML2_CFLAGS) $(BCTOOLBOX_CFLAGS)
AM_CFLAGS= $(LIBSQLITE3_CFLAGS) $(BCTOOLBOX_CFLAGS)
libbzrtp_la_LDFLAGS=-fvisibility=hidden -no-undefined
......
......@@ -9,7 +9,7 @@ bzrtpTest_SOURCES=bzrtpTest.c \
bzrtpZidCacheTest.c
bzrtpTest_CFLAGS=$(BCTOOLBOXTESTER_CFLAGS) $(LIBXML2_CFLAGS)
bzrtpTest_LDADD=$(top_builddir)/src/libbzrtp.la $(BCTOOLBOX_LIBS) $(BCTOOLBOXTESTER_LIBS) $(LIBXML2_LIBS) -lm
bzrtpTest_LDADD=$(top_builddir)/src/libbzrtp.la $(BCTOOLBOX_LIBS) $(BCTOOLBOXTESTER_LIBS) $(SQLITE3_LIBS) -lm
AM_CPPFLAGS=-I$(top_srcdir)/include
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment