updated libi2ncommon and libt2n checks to make 'em optional.
authorReinhard Pfau <Reinhard.Pfau@gmx.de>
Tue, 24 Mar 2009 19:53:21 +0000 (20:53 +0100)
committerReinhard Pfau <Reinhard.Pfau@gmx.de>
Tue, 24 Mar 2009 19:53:21 +0000 (20:53 +0100)
Makefile.am
configure.in

index 268086a..6b3a235 100644 (file)
@@ -1,6 +1,12 @@
 AUTOMAKE_OPTIONS = foreign 1.6
 ACLOCAL_AMFLAGS = -I m4macros
 
-SUBDIRS = utils asyncio glue_t2n unittest doc
+if HAVE_LIBT2N
+T2NDIRS = glue_t2n
+else
+T2NDIRS =
+endif
+
+SUBDIRS = utils asyncio $(T2NDIRS) unittest doc
 
 EXTRA_DIST = LICENSE
index e5593db..1f581f4 100644 (file)
@@ -31,9 +31,13 @@ AM_CONDITIONAL(HAVE_DOXYGEN, test -n $DOXYGEN)
 dnl check for libraries:
 
 PKG_CHECK_MODULES(LIBI2NCOMMON, libi2ncommon,
-[have_i2ncommon=yes],
-[have_i2ncommon=no])
-AM_CONDITIONAL([HAVE_I2NCOMMON],[test x$have_i2ncommon = xyes])
+[have_i2ncommon=yes
+  AC_DEFINE([HAVE_LIBI2NCOMMON],,[define if libt2n is available])
+],
+[have_i2ncommon=no
+  AC_MSG_NOTICE([building without libi2ncommon support])
+])
+AM_CONDITIONAL([HAVE_LIBI2NCOMMON],[test x$have_i2ncommon = xyes])
 
 AM_PATH_CPPUNIT(1.8.0)
 
@@ -43,7 +47,14 @@ if test "x$BOOST_SIGNALS_LIB" = "x"; then
     AC_MSG_ERROR([Sorry, we need the Signals-Lib from Boost.])
 fi
 
-LIBT2N_CHECK(libt2n)
+LIBT2N_CHECK(libt2n,[
+  have_libt2n=yes
+  AC_DEFINE([HAVE_LIBT2N],,[define if libt2n is available])
+],[
+  have_libt2n=no
+  AC_MSG_NOTICE([Building without libt2n support])
+])
+AM_CONDITIONAL([HAVE_LIBT2N],[test x$have_libt2n = xyes])
 
 
 dnl