2 ## Process this file with autoconf to produce a configure script.
5 AC_INIT(yp2, 0.0.1, marc@indexdata.dk)
6 AM_CONFIG_HEADER(src/config.hpp)
9 AC_CONFIG_SRCDIR(configure.ac)
10 AC_CONFIG_AUX_DIR(config)
12 ##AC_PREFIX_DEFAULT(`pwd`/install)
17 # Checks for programs.
25 # Use C++ compilers only for tests
28 # Checks for libraries.
29 ##AC_CHECK_LIB(ibrary, main)
30 AC_CHECK_LIB(boost_thread, main, [],[
31 AC_MSG_ERROR([boost thread library not found. Install libboost-thread-dev (or similar)])
34 ## AC_CHECK_LIB(boost_unit_test_framework, [], [],[
35 ## AC_MSG_ERROR([boost unit test library not found. Install libboost-test-dev (or similar)])
39 YAZPP_INIT(threads,1.0)
40 if test -z "$YAZPPLIB"; then
41 AC_MSG_ERROR([YAZ++ development libraries missing])
49 AC_ARG_WITH(xslt,[[ --with-xslt[=PREFIX] use libxslt in PREFIX]],xsltdir=$withval)
50 if test "$xsltdir" = "yes" -o "$xsltdir" = "default"; then
51 for d in /usr /usr/local; do
52 if test -x $d/bin/xslt-config; then
57 if test "$xsltdir" != "no"; then
58 AC_MSG_CHECKING(for libXSLT)
59 if test -x $xsltdir/bin/xslt-config; then
60 XSLT_LIBS=`$xsltdir/bin/xslt-config --libs`
61 XSLT_CFLAGS=`$xsltdir/bin/xslt-config --cflags`
62 XSLT_VER=`$xsltdir/bin/xslt-config --version`
63 AC_MSG_RESULT($XSLT_VER)
64 AC_DEFINE([HAVE_XSLT],[1],
65 [Define to 1 if you have libxslt installed])
67 AC_MSG_RESULT(Not found)
68 if test "$xsltdir" = "default"; then
69 AC_MSG_WARN([Libxslt development libraries not found.])
71 AC_MSG_ERROR([libxslt development libraries not found.]) fi
76 # Checks for header files.
81 AC_CHECK_HEADERS(boost/thread/mutex.hpp)
85 # Checks for typedefs, structures, and compiler characteristics.
87 ##AC_CHECK_SIZEOF(int)
88 ##AC_CHECK_SIZEOF(long int)
91 # Checks for library functions.
105 "------------------------------------------------------------------------
108 Source code location: ${srcdir}
109 CPP Preprocessor flags: ${CPPFLAGS}
111 CXX Compiler flags: ${CXXFLAGS}
112 Linker flags: ${LDFLAGS}
114 Host System Type: ${host}
115 Install path: ${prefix}
117 ------------------------------------------------------------------------"