dnl Process this file with autoconf to produce a configure script.

AC_INIT(configure.in)
AM_INIT_AUTOMAKE(evolution2_sync, 0.82)
AM_CONFIG_HEADER(config.h)

AC_ISC_POSIX
AC_PROG_CC
AM_PROG_CC_STDC
AC_HEADER_STDC
AC_PROG_LIBTOOL
AC_PROG_YACC

pkg_modules_generic="gtk+-2.0 libgnomeui-2.0 libbonoboui-2.0 glib-2.0 libbonobo-2.0"
pkg_modules_eds_1_0="evolution-data-server-1.0 libebook-1.0 libecal-1.0 libedata-book-1.0 libedata-cal-1.0 libedataserver-1.0"
pkg_modules_eds_1_2="evolution-data-server-1.2 libebook-1.2 libecal-1.2 libedata-book-1.2 libedata-cal-1.2 libedataserver-1.2"
PKG_CHECK_MODULES(PACKAGE, [$pkg_modules_generic $pkg_modules_eds_1_0], version="2.0",
        [PKG_CHECK_MODULES(PACKAGE, [$pkg_modules_generic $pkg_modules_eds_1_2], version="2.2")])
AC_SUBST(PACKAGE_CFLAGS)
AC_SUBST(PACKAGE_LIBS)

dnl Info for the RPM
MULTISYNC_TOP="../.."
AC_SUBST(MULTISYNC_TOP)
AC_SUBST(VERSION)
AC_SUBST(prefix)
MULTISYNC_VERSION=`grep "#define VERSION" ${MULTISYNC_TOP}/config.h | sed -e 's/#define VERSION //g' | sed -e 's/\"//g'`
AC_SUBST(MULTISYNC_VERSION)
AC_SUBST(EVO_RPM_VER)

AC_OUTPUT(
Makefile
src/Makefile
intl/Makefile
po/Makefile.in
../../specs/multisync-evolution2.spec
)

