dnl dnl dnl ProLinga-Repository dnl dnl Copyright (C) 2002-2009 ProLinga Software. dnl All rights reserved. dnl dnl This file is part of ProLinga-Repository. dnl dnl ProLinga-Repository is free software: you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by dnl the Free Software Foundation, either version 3 of the License, or dnl (at your option) any later version. dnl dnl ProLinga-Repository is distributed in the hope that it will be useful, dnl but WITHOUT ANY WARRANTY; without even the implied warranty of dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the dnl GNU General Public License for more details. dnl dnl You should have received a copy of the GNU General Public License dnl along with ProLinga-Repository. If not, see . dnl dnl More information is available at the following addresses: dnl dnl Website : http://www.prolinga.org dnl dnl Email : prolinga-list@prolinga.org dnl dnl dnl Process this file with autoconf to produce a configure script. AC_PREREQ(2.57) AC_INIT(ProLinga-Repository,0.0.2,prolinga-list@prolinga.org,prolinga-repository) AC_CONFIG_SRCDIR(src/RepositoryMain.cpp) AC_CONFIG_AUX_DIR(config) AC_CONFIG_MACRO_DIR([m4]) AC_LANG(C++) AM_CONFIG_HEADER(src/config.h:src/config-h.in) AM_INIT_AUTOMAKE dnl set host/node name HOST_NODE_NAME=`(hostname || uname -n) 2>/dev/null | sed 1q` AC_SUBST(HOST_NODE_NAME) dnl set home dir HOME_DIR=`echo $HOME` AC_SUBST(HOME_DIR) dnl set required 3rd party versions PKG_CONFIG_REQUIRED_VERSION=0.7.0 PROLINGASOAP_PACKAGE="prolinga-soap" PROLINGASOAP_REQUIRED_VERSION=0.0.1 DB_REQUIRED_VERSION=4.6.21 DBXML_REQUIRED_VERSION=2.4.13 XQILLA_REQUIRED_VERSION=2.1.3 XERCES_REQUIRED_VERSION=2.7.0 LIBXML_REQUIRED_VERSION=2.6.5 dnl Set default pkg search path PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/lib64/pkgconfig:/usr/lib/pkgconfig:/usr/local/lib/pkgconfig:/usr/local/lib64/pkgconfig" dnl Enable debugging mode AC_ARG_ENABLE(debug, [ --enable-debug Enable debug messages], CFLAGS="$CFLAGS -DDEBUG -O0 -g" CXXFLAGS="$CFLAGS -DDEBUG -O0 -g") AC_ARG_ENABLE(gprof, [ --enable-gprof Enable profiling with gprof], CFLAGS="$CFLAGS -pg" CXXFLAGS="$CFLAGS -pg" LDFLAGS="$LDFLAGS -pg" ) dnl Enable stripped and optimized release builds AC_ARG_ENABLE(final, [ --enable-final Build release executables (GCC only)], if test "x$GCC" != xyes; then CFLAGS="$CFLAGS -DNDEBUG -Os -s -DG_DISABLE_CHECKS -DG_DISABLE_CAST_CHECKS" CXXFLAGS="$CXXFLAGS -DNDEBUG -Os -s -fexceptions -fno-check-new -DG_DISABLE_CHECKS -DG_DISABLE_CAST_CHECKS" fi) dnl Enable compiler warnings AC_ARG_ENABLE(warnings, [ --enable-warnings Enable compiler warnings (GCC only)], if test "x$GCC" != xyes; then CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wmissing-declarations -Wparentheses -Wpointer-arith" CXXFLAGS="$CXXFLAGS -Wall -Wparentheses -Wpointer-arith" fi) dnl By default build static and no shared libs AC_ENABLE_SHARED(yes) AC_ENABLE_STATIC(yes) dnl Checks for programs. AC_PROG_CC AC_PROG_CPP AC_PROG_CXX AC_PROG_CXXCPP AC_PROG_INSTALL dnl AC_PROG_RANLIB AC_PROG_LIBTOOL dnl Checks for libraries. dnl Checks for header files. AC_HEADER_STDC AC_CHECK_HEADERS(ctype.h fcntl.h signal.h stddef.h time.h) dnl Checks for typedefs, structures and compiler characteristics. AC_C_CONST AC_CHECK_TYPES(bool) AC_HEADER_STDBOOL AC_TYPE_PID_T AC_TYPE_SIGNAL #AC_TYPE_SIZE_T dnl Checks for library functions. AC_FUNC_FORK #AC_FUNC_MALLOC #AC_FUNC_REALLOC #AC_CHECK_FUNCS(strdup) dnl Check 3rd party products dnl dnl If pkg-config available use it, otherwise ignore dnl Not sure how widely accepted/available pkg-config is dnl AC_PATH_PROG(PKG_CONFIG, pkg-config, no) dnl test if pkg-config is available and if so if correct version if test "x$PKG_CONFIG" = "xno" then AC_MSG_NOTICE([Could not find pkg-config anywhere (optional). It is recommended to have pkg-config available for library compile/link flag detections during configure. Check http://www.freedesktop.org/software/pkgconfig/ for details.]) else AC_MSG_CHECKING(for pkg-config >= $PKG_CONFIG_REQUIRED_VERSION) if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_REQUIRED_VERSION then AC_MSG_RESULT(yes) else PKG_CONFIG_VERS=`$PKG_CONFIG --version` AC_MSG_RESULT(Version $PKG_CONFIG_VERS found. You need at least pkg-config $PKG_CONFIG_REQUIRED_VERSION for this version of ProLinga-Repository) PKG_CONFIG="no" fi fi dnl dnl specify location of Berkeley DB dnl DB_PREFIX="" DB_CXXFLAGS="" DB_LIBS="" DB_INCLUDE_DIR="" DB_LIB_DIR="" AC_ARG_WITH(berkeleydb-prefix, [ --with-berkeleydb-prefix=[PFX] Specify location of Berkeley DB], DB_PREFIX=$withval ) AC_ARG_WITH(berkeleydb-include-prefix, [ --with-berkeleydb-include-prefix=[PFX] Specify location of Berkeley DB headers], DB_CXXFLAGS="-I$withval" ) AC_ARG_WITH(berkeleydb-libs-prefix, [ --with-berkeleydb-libs-prefix=[PFX] Specify location of Berkeley DB libs], DB_LIBS="-L$withval" ) dnl dnl Berkeley provides no mechanism to check library version dnl AC_MSG_CHECKING(for Berkeley DB CXX 4.6 libraries ) if test -f `echo $DB_LIBS | sed -e 's/-L//'`/libdb_cxx.so then dnl Check for header files. if test -f `echo $DB_CXXFLAGS | sed -e 's/-I//'`/db4/db.h then DB_INCLUDE_DIR="" DB_LIB_DIR="" AC_MSG_RESULT(found) else AC_MSG_ERROR([Could not find Berkeley DB 4.6 headers/libraries anywhere, check http://www.oracle.com/technology/products/berkeley-db/index.html]) fi else if test -f $DB_PREFIX/lib64/libdb_cxx.so then DB_INCLUDE_DIR="-I$DB_PREFIX/include" DB_LIB_DIR="-L$DB_PREFIX/lib64" AC_MSG_RESULT(found) else if test -f /usr/lib64/libdb_cxx.so then DB_INCLUDE_DIR="-I/usr/include" DB_LIB_DIR="-L/usr/lib64" AC_MSG_RESULT(found) else if test -f /usr/local/BerkeleyDB.4.6/lib64/libdb_cxx.so then DB_INCLUDE_DIR="-I/usr/local/BerkeleyDB.4.6/include" DB_LIB_DIR="-L/usr/local/BerkeleyDB.4.6/lib64" AC_MSG_RESULT(found) else if test -f $DB_PREFIX/lib/libdb_cxx.so then DB_INCLUDE_DIR="-I$DB_PREFIX/include" DB_LIB_DIR="-L$DB_PREFIX/lib" AC_MSG_RESULT(found) else if test -f /usr/lib/libdb_cxx.so then DB_INCLUDE_DIR="-I/usr/include" DB_LIB_DIR="-L/usr/lib" AC_MSG_RESULT(found) else if test -f /usr/local/BerkeleyDB.4.6/lib/libdb_cxx.so then DB_INCLUDE_DIR="-I/usr/local/BerkeleyDB.4.6/include" DB_LIB_DIR="-L/usr/local/BerkeleyDB.4.6/lib" AC_MSG_RESULT(found) else AC_MSG_ERROR([Could not find Berkeley DB 4.6 libraries anywhere, check http://www.oracle.com/technology/products/berkeley-db/index.html]) fi fi fi fi fi fi fi DB_CXXFLAGS="$DB_CXXFLAGS $DB_INCLUDE_DIR" DB_LIBS="$DB_LIBS $DB_LIB_DIR -ldb_cxx -lpthread" AC_SUBST(DB_LIBS) AC_SUBST(DB_CXXFLAGS) dnl dnl specify location of Berkeley DB XML dnl DBXML_PREFIX="" DBXML_CXXFLAGS="" DBXML_LIBS="" DBXML_INCLUDE_DIR="" DBXML_LIB_DIR="" AC_ARG_WITH(dbxml-prefix, [ --with-dbxml-prefix=[PFX] Specify location of Berkeley DB XML], DBXML_PREFIX=$withval ) AC_ARG_WITH(dbxml-include-prefix, [ --with-dbxml-include-prefix=[PFX] Specify location of Berkeley DB XML headers], DBXML_CXXFLAGS="-I$withval" ) AC_ARG_WITH(dbxml-libs-prefix, [ --with-dbxml-libs-prefix=[PFX] Specify location of Berkeley DB XML libs], DBXML_LIBS="-L$withval" ) dnl dnl Berkeley provides no mechanism to check library version dnl AC_MSG_CHECKING(for Berkeley DB XML 2.4 libraries ) if test -f `echo $DBXML_LIBS | sed -e 's/-L//'`/libdbxml-2.4.so then dnl DBXML_LIB_DIR=`echo $DBXML_LIBS | sed -e 's/-L//'` dnl Check for header files. if test -f `echo $DBXML_CXXFLAGS | sed -e 's/-I//'`/dbxml/DbXml.hpp then DBXML_INCLUDE_DIR="" DBXML_LIB_DIR="" AC_MSG_RESULT(found) else AC_MSG_ERROR([Could not find Berkeley DB XML 2.4 headers/libraries anywhere, check http://www.oracle.com/technology/products/berkeley-db/index.html]) fi else if test -f $DBXML_PREFIX/lib/libdbxml-2.4.so then DBXML_INCLUDE_DIR="-I$DBXML_PREFIX/include" DBXML_LIB_DIR="-L$DBXML_PREFIX/lib" AC_MSG_RESULT(found) else if test -f /usr/lib/libdbxml-2.4.so then DBXML_INCLUDE_DIR="-I/usr/include" DBXML_LIB_DIR="-L/usr/lib" AC_MSG_RESULT(found) else if test -f /usr/local/BerkeleyDBXML.2.4/lib/libdbxml-2.4.so then DBXML_INCLUDE_DIR="-I/usr/local/BerkeleyDBXML.2.4/include" DBXML_LIB_DIR="-L/usr/local/BerkeleyDBXML.2.4/lib" AC_MSG_RESULT(found) else if test -f $DBXML_PREFIX/lib64/libdbxml-2.4.so then DBXML_INCLUDE_DIR="-I$DBXML_PREFIX/include" DBXML_LIB_DIR="-L$DBXML_PREFIX/lib64" AC_MSG_RESULT(found) else if test -f /usr/lib64/libdbxml-2.4.so then DBXML_INCLUDE_DIR="-I/usr/include" DBXML_LIB_DIR="-L/usr/lib64" AC_MSG_RESULT(found) else if test -f /usr/local/BerkeleyDBXML.2.4/lib/libdbxml-2.4.so then DBXML_INCLUDE_DIR="-I/usr/local/BerkeleyDBXML.2.4/include" DBXML_LIB_DIR="-L/usr/local/BerkeleyDBXML.2.4/lib64" AC_MSG_RESULT(found) else AC_MSG_ERROR([Could not find Berkeley DB XML 2.4 libraries anywhere, check http://www.oracle.com/technology/products/berkeley-db/index.html]) fi fi fi fi fi fi fi DBXML_CXXFLAGS="$DBXML_CXXFLAGS $DBXML_INCLUDE_DIR" DBXML_LIBS="$DBXML_LIBS $DBXML_LIB_DIR -ldbxml-2.4" AC_SUBST(DBXML_LIBS) AC_SUBST(DBXML_CXXFLAGS) dnl dnl specify location of XQilla dnl XQILLA_PREFIX="" XQILLA_CXXFLAGS="" XQILLA_LIBS="" XQILLA_INCLUDE_DIR="" XQILLA_LIB_DIR="" AC_ARG_WITH(xqilla-prefix, [ --with-xqilla-prefix=[PFX] Specify location of XQilla], XQILLA_PREFIX=$withval ) AC_ARG_WITH(xqilla-include-prefix, [ --with-xqilla-include-prefix=[PFX] Specify location of XQilla headers], XQILLA_CXXFLAGS="-I$withval" ) AC_ARG_WITH(xqilla-libs-prefix, [ --with-xqilla-libs-prefix=[PFX] Specify location of XQilla libs], XQILLA_LIBS="-L$withval" ) dnl dnl Check for libs/headers dnl AC_MSG_CHECKING(for XQilla libraries ) if test -f `echo $XQILLA_LIBS | sed -e 's/-L//'`/libxqill*.so then dnl Check for header files. if test -f `echo $XQILLA_CXXFLAGS | sed -e 's/-I//'`/xqilla/xqilla-simple.hpp then XQILLA_INCLUDE_DIR="" XQILLA_LIB_DIR="" AC_MSG_RESULT(found) else AC_MSG_ERROR([Could not find XQilla headers/libraries anywhere, check http://www.oracle.com/technology/products/berkeley-db/index.html]) fi else # Test for obvious places if test -f $XQILLA_PREFIX/lib/libxqill*.so then XQILLA_INCLUDE_DIR="-I$XQILLA_PREFIX/include" XQILLA_LIB_DIR="-L$XQILLA_PREFIX/lib" AC_MSG_RESULT(found) else if test -f /usr/lib/libxqill*.so then XQILLA_INCLUDE_DIR="-I/usr/include" XQILLA_LIB_DIR="-L/usr/lib" AC_MSG_RESULT(found) else if test -f /usr/local/lib/libxqill*.so then XQILLA_INCLUDE_DIR="-I/usr/local/include" XQILLA_LIB_DIR="-L/usr/local/lib" AC_MSG_RESULT(found) else if test -f $XQILLA_PREFIX/lib64/libxqill*.so then XQILLA_INCLUDE_DIR="-I$XQILLA_PREFIX/lib64" XQILLA_LIB_DIR="-L$XQILLA_PREFIX/lib64" AC_MSG_RESULT(found) else if test -f /usr/lib64/libxqill*.so then XQILLA_INCLUDE_DIR="-I/usr/include" XQILLA_LIB_DIR="-L/usr/lib64" AC_MSG_RESULT(found) else if test -f /usr/local/lib64/libxqill*.so then XQILLA_INCLUDE_DIR="-I/usr/local/include" XQILLA_LIB_DIR="-L/usr/local/lib64" AC_MSG_RESULT(found) else AC_MSG_ERROR([Could not find XQilla libraries anywhere, check http://www.oracle.com/technology/products/berkeley-db/index.html]) fi fi fi fi fi fi fi XQILLA_CXXFLAGS="$XQILLA_CXXFLAGS $XQILLA_INCLUDE_DIR" XQILLA_LIBS="$XQILLA_LIBS $XQILLA_LIB_DIR -lxqilla" AC_SUBST(XQILLA_LIBS) AC_SUBST(XQILLA_CXXFLAGS) dnl dnl specify location of Xerces dnl XERCES_PREFIX="" XERCES_CXXFLAGS="" XERCES_LIBS="" XERCES_SHARED_LIBS="" XERCES_VERSION="" AC_ARG_WITH(xerces-prefix, [ --with-xerces-prefix=[PFX] Specify location of Xerces], XERCES_PREFIX=$withval ) AC_ARG_WITH(xerces-include-prefix, [ --with-xerces-include-prefix=[PFX] Specify location of Xerces headers], XERCES_CXXFLAGS="-I$withval" ) AC_ARG_WITH(xerces-libs-prefix, [ --with-xerces-libs-prefix=[PFX] Specify location of Xerces libs], XERCES_LIBS="-L$withval" ) dnl dnl Xerces-c provides no support for pkg-config for version checking dnl AC_MSG_CHECKING(for Xerces libraries ) if test -f `echo $XERCES_LIBS | sed -e 's/-L//'`/libxerces-c.?? then XERCES_SHARED_LIB_DIR=`echo $XERCES_LIBS | sed -e 's/-L//'` AC_MSG_RESULT(found) else if test -f $XERCES_PREFIX/lib/libxerces-c.?? then XERCES_SHARED_LIB_DIR=$XERCES_PREFIX/lib XERCES_VERSION=`ls "$XERCES_SHARED_LIB_DIR"/libxerces-c.*.[[0-9]][[0-9]] | tail -1 | sed 's/.*xerces-c.*\([[0-9]]\)\([[0-9]]\)/\1.\2.x/'` AC_MSG_RESULT($XERCES_VERSION found) else if test -f /usr/lib/libxerces-c.?? then XERCES_SHARED_LIB_DIR=/usr/lib XERCES_VERSION=`ls "$XERCES_SHARED_LIB_DIR"/libxerces-c.*.[[0-9]][[0-9]] | tail -1 | sed 's/.*xerces-c.*\([[0-9]]\)\([[0-9]]\)/\1.\2.x/'` AC_MSG_RESULT($XERCES_VERSION found) else if test -f /usr/local/lib/libxerces-c.?? then XERCES_SHARED_LIB_DIR=/usr/local/lib XERCES_VERSION=`ls "$XERCES_SHARED_LIB_DIR"/libxerces-c.*.[[0-9]][[0-9]] | tail -1 | sed 's/.*xerces-c.*\([[0-9]]\)\([[0-9]]\)/\1.\2.x/'` AC_MSG_RESULT($XERCES_VERSION found) else if test -f $XERCES_PREFIX/lib64/libxerces-c.?? then XERCES_SHARED_LIB_DIR=$XERCES_PREFIX/lib64 XERCES_VERSION=`ls "$XERCES_SHARED_LIB_DIR"/libxerces-c.*.[[0-9]][[0-9]] | tail -1 | sed 's/.*xerces-c.*\([[0-9]]\)\([[0-9]]\)/\1.\2.x/'` AC_MSG_RESULT($XERCES_VERSION found) else if test -f /usr/lib64/libxerces-c.?? then XERCES_SHARED_LIB_DIR=/usr/lib64 XERCES_VERSION=`ls "$XERCES_SHARED_LIB_DIR"/libxerces-c.*.[[0-9]][[0-9]] | tail -1 | sed 's/.*xerces-c.*\([[0-9]]\)\([[0-9]]\)/\1.\2.x/'` AC_MSG_RESULT($XERCES_VERSION found) else if test -f /usr/local/lib64/libxerces-c.?? then XERCES_SHARED_LIB_DIR=/usr/local/lib64 XERCES_VERSION=`ls "$XERCES_SHARED_LIB_DIR"/libxerces-c.*.[[0-9]][[0-9]] | tail -1 | sed 's/.*xerces-c.*\([[0-9]]\)\([[0-9]]\)/\1.\2.x/'` AC_MSG_RESULT($XERCES_VERSION found) else AC_MSG_ERROR([Could not find Xerces-c libraries anywhere, check http://xml.apache.org/xerces-c/index.html/.]) fi fi fi fi fi fi fi if test $XERCES_PREFIX then XERCES_CXXFLAGS="$XERCES_CXXFLAGS -I$XERCES_PREFIX/include" XERCES_LIBS="$XERCES_LIBS -L$XERCES_SHARED_LIB_DIR -lxerces-c" else XERCES_CXXFLAGS="$XERCES_CXXFLAGS -I/usr/local/include" XERCES_LIBS="$XERCES_LIBS -L$XERCES_SHARED_LIB_DIR -lxerces-c" fi AC_SUBST(XERCES_LIBS) AC_SUBST(XERCES_CXXFLAGS) AC_SUBST(XERCES_SHARED_LIB_DIR) dnl dnl specify location of libxml2 dnl LIBXML_CONFIG_PREFIX="" LIBXML_CXXFLAGS="" LIBXML_LIBS="" AC_ARG_WITH(libxml-prefix, [ --with-libxml-prefix=[PFX] Specify location of libxml config], LIBXML_CONFIG_PREFIX=$withval ) AC_ARG_WITH(libxml-include-prefix, [ --with-libxml-include-prefix=[PFX] Specify location of libxml headers], LIBXML_CXXFLAGS="-I$withval" ) AC_ARG_WITH(libxml-libs-prefix, [ --with-libxml-libs-prefix=[PFX] Specify location of libxml libs], LIBXML_LIBS="-L$withval" ) dnl where is xml2-config AC_SUBST(LIBXML_REQUIRED_VERSION) AC_MSG_CHECKING(for libxml libraries >= $LIBXML_REQUIRED_VERSION) if test "x$LIBXML_CONFIG_PREFIX" != "x" then XML_CONFIG=${LIBXML_CONFIG_PREFIX}/bin/xml2-config else XML_CONFIG=xml2-config fi dnl check version number AC_DEFUN([VERSION_TO_NUMBER], [`$1 | sed -e 's/libxml //' | awk 'BEGIN { FS = "."; } { printf "%d", ([$]1 * 1000 + [$]2) * 1000 + [$]3;}'`]) if ${XML_CONFIG} --libs print > /dev/null 2>&1 then XMLVERS=`$XML_CONFIG --version` if test VERSION_TO_NUMBER(echo $XMLVERS) -ge VERSION_TO_NUMBER(echo $LIBXML_REQUIRED_VERSION) then LIBXML_LIBS="$LIBXML_LIBS `$XML_CONFIG --libs`" LIBXML_CXXFLAGS="$LIBXML_CXXFLAGS `$XML_CONFIG --cflags`" AC_MSG_RESULT($XMLVERS found) else AC_MSG_ERROR(Version $XMLVERS found. You need at least libxml2 $LIBXML_REQUIRED_VERSION for this version of ProLinga-Repository) fi else AC_MSG_ERROR([Could not find libxml2 anywhere, check http://xmlsoft.org/.]) fi AC_SUBST(XML_CONFIG) AC_SUBST(LIBXML_LIBS) AC_SUBST(LIBXML_CXXFLAGS) dnl dnl specify location of ProLinga-Soap dnl PROLINGASOAP_PREFIX="" PROLINGASOAP_CXXFLAGS="" PROLINGASOAP_LIBS="" AC_ARG_WITH(prolingasoap-prefix, [ --with-prolingasoap-prefix=[PFX] Specify location of ProLinga-Soap], PROLINGASOAP_PREFIX=$withval ) AC_ARG_WITH(prolingasoap-include-prefix, [ --with-prolingasoap-include-prefix=[PFX] Specify location of ProLinga-Soap headers], PROLINGASOAP_CXXFLAGS="-I$withval" ) AC_ARG_WITH(prolingasoap-libs-prefix, [ --with-prolingasoap-libs-prefix=[PFX] Specify location of ProLinga-Soap libs], PROLINGASOAP_LIBS="-L$withval" ) dnl dnl use pkg-config if available dnl if test "x$PKG_CONFIG" != "xno" then dnl use pkg-config for version check and compile/link flag detection. AC_MSG_CHECKING(for ProLinga-Soap libraries >= $PROLINGASOAP_REQUIRED_VERSION) dnl create pkg-config search path PKG_CONFIG_SEARCH="/usr/lib64/pkgconfig:/usr/local/lib64/pkgconfig:/usr/lib/pkgconfig:/usr/local/lib/pkgconfig" if test $PROLINGASOAP_PREFIX then PKG_CONFIG_SEARCH="$PROLINGASOAP_PREFIX/lib64/pkgconfig:$PROLINGASOAP_PREFIX/lib/pkgconfig:$PKG_CONFIG_SEARCH" fi if test $PROLINGASOAP_LIBS then SEARCH_LIB=`echo $PROLINGASOAP_LIBS | sed -e 's/-L//'` PKG_CONFIG_SEARCH="$PKG_CONFIG_SEARCH:$SEARCH_LIB/pkgconfig" fi dnl check version PKG_CONFIG_PATH="$PKG_CONFIG_SEARCH:$PKG_CONFIG_PATH" if `export PKG_CONFIG_PATH; $PKG_CONFIG --modversion $PROLINGASOAP_PACKAGE >/dev/null 2>&1` then SOAPVERS=`export PKG_CONFIG_PATH; $PKG_CONFIG --modversion $PROLINGASOAP_PACKAGE` if `export PKG_CONFIG_PATH; $PKG_CONFIG --atleast-version=$PROLINGASOAP_REQUIRED_VERSION $PROLINGASOAP_PACKAGE` then PROLINGASOAP_CXXFLAGS="$PROLINGASOAP_CXXFLAGS `export PKG_CONFIG_PATH; $PKG_CONFIG --cflags $PROLINGASOAP_PACKAGE`" PROLINGASOAP_LIBS="$PROLINGASOAP_LIBS `export PKG_CONFIG_PATH; $PKG_CONFIG --libs-only-L $PROLINGASOAP_PACKAGE`" AC_MSG_RESULT($SOAPVERS found) else AC_MSG_ERROR(Version $SOAPVERS found. You need at least ProLinga-Soap $PROLINGASOAP_REQUIRED_VERSION for this version of ProLinga-Repository) fi else AC_MSG_ERROR([Could not find ProLinga-Soap anywhere, check http://www.prolinga.org/.]) fi else dnl check if libraries are there AC_MSG_CHECKING(for ProLinga-Soap libraries ) if test -f `echo $PROLINGASOAP_LIBS | sed -e 's/-L//'`/libprolingasoapclient.la || test -f $PROLINGASOAP_PREFIX/lib/libprolingasoapclient.la \ || test -f /usr/lib/libprolingasoapclient.la || test -f /usr/local/lib/libprolingasoapclient.la \ || test -f $PROLINGASOAP_PREFIX/lib64/libprolingasoapclient.la \ || test -f /usr/lib64/libprolingasoapclient.la || test -f /usr/local/lib64/libprolingasoapclient.la then AC_MSG_RESULT(found) else AC_MSG_ERROR([Could not find ProLinga-Soap anywhere, check http://www.prolinga.org/.]) fi if test $PROLINGASOAP_PREFIX then PROLINGASOAP_CXXFLAGS="$PROLINGASOAP_CXXFLAGS -I$PROLINGASOAP_PREFIX/include" PROLINGASOAP_LIBS="$PROLINGASOAP_LIBS -L$PROLINGASOAP_PREFIX/lib64 -L$PROLINGASOAP_PREFIX/lib" fi fi dnl export values AC_SUBST(PROLINGASOAP_LIBS) AC_SUBST(PROLINGASOAP_CXXFLAGS) dnl create output files AC_OUTPUT(Makefile prolinga-repository.pc src/Makefile prolinga/Makefile doc/Makefile doc/version.txt)