X-Git-Url: http://git.maemo.org/git/?p=modest;a=blobdiff_plain;f=configure.ac;h=9a86a09c10c2b49c36c09091f6a4711e17ce7496;hp=ca2e6150e1e558ccd1d49924ba677350b3b291dd;hb=0c709695e5764821aeea6ea9c35821507b326ce7;hpb=de8ac9aa1f0d03dffda84e55ad31c094923ad70f diff --git a/configure.ac b/configure.ac index ca2e615..9a86a09 100644 --- a/configure.ac +++ b/configure.ac @@ -69,6 +69,12 @@ PKG_CHECK_MODULES(MODEST_GSTUFF,glib-2.0 >= 2.6 gobject-2.0 gtk+-2.0 >= 2.6 gcon AC_SUBST(MODEST_GSTUFF_CFLAGS) AC_SUBST(MODEST_GSTUFF_LIBS) +__COPY_LIBS="$LIBS" +LIBS="$LIBS $MODEST_GSTUFF_LIBS" +AC_CHECK_FUNCS(gtk_html_get_selection_area) +LIBS="$__COPY_LIBS" +AC_SUBST(HAVE_GTK_HTML_GET_SELECTION_AREA) + dnl dnl now, determine what to build AC_MSG_NOTICE([Determining what platform to build]) PKG_CHECK_MODULES(MODEST_MAEMO_LIBS,libosso,[with_platform=maemo],true) @@ -82,29 +88,28 @@ AC_ARG_WITH(platform, esac], [MODEST_PLATFORM=gnome with_platform=gnome]) - +have_easysetup=false if test "x$with_platform" == "xgnome"; then PKG_CHECK_MODULES(MODEST_PLATFORM,libtinymail-gnome-desktop-1.0 libnm_glib glib-2.0 >= 2.8 gtk+-2.0 >= 2.10 libnotify) AC_DEFINE_UNQUOTED(MODEST_PLATFORM_GNOME, 1, ["Whether modest is being built for the GNOME platform."]) + AC_MSG_ERROR([The GNOME Build is currently broken; please try the Maemo build instead]) else - PKG_CHECK_MODULES(MODEST_PLATFORM,libosso conic libtinymail-maemo-1.0 osso-addressbook-1.0 libebook-1.2 libalarm) + have_easysetup=true + PKG_CHECK_MODULES(MODEST_PLATFORM,libosso conic libtinymail-maemo-1.0 libebook-1.2 microb-engine-nss) AC_DEFINE_UNQUOTED(MODEST_PLATFORM_MAEMO, 1, ["Whether modest is being built for the MAEMO platform."]) + AC_DEFINE_UNQUOTED(MODEST_HAVE_EASYSETUP, 1, ["Whether we have the easysetup feature"]) fi - - +AM_CONDITIONAL(MODEST_HAVE_EASYSETUP,test "x$have_easysetup" == "xtrue") AC_SUBST(MODEST_PLATFORM) - - - - # -# check for wpeditor or libwpeditor-plus +# check for wpeditor or libwpeditor-plus (on maemo) # +if test "x$with_platform" == "xmaemo"; then PKG_CHECK_MODULES(MODEST_WPEDITOR,wpeditor,have_wpeditor=true,have_wpeditor=false) if test "x$have_wpeditor" == "xfalse"; then PKG_CHECK_MODULES(MODEST_WPEDITOR,libwpeditor-plus,have_libwpeditorplus=true,have_libwpeditorplus=false) @@ -118,12 +123,29 @@ else wpeditor="wpeditor" AC_DEFINE_UNQUOTED(MODEST_HAVE_WPEDITOR, 1, ["Whether wpeditor is used."]) fi +fi + +# +# check libalarm +# +if test "x$with_platform" == "xmaemo"; then +PKG_CHECK_MODULES(MODEST_LIBALARM,libalarm,have_libalarm=true,have_libalarm=false) +if test "x$have_libalarm" == "xtrue"; then + libalarm="libalarm" + AC_DEFINE_UNQUOTED(MODEST_HAVE_LIBALARM, 1, ["Whether libalarm is used."]) + AC_SUBST(MODEST_LIBALARM_CFLAGS) + AC_SUBST(MODEST_LIBALARM_LIBS) +else + libalarm="" +fi +fi # -# check the providers-data +# check the providers-data (on maemo) # +if test "x$with_platform" == "xmaemo"; then PKG_CHECK_MODULES(MODEST_PROVIDERS_DATA,modest-providers-data,have_modest_providers_data=true,have_modest_providers_data=false) if test "x$have_modest_providers_data" == "xfalse"; then PKG_CHECK_MODULES(MODEST_PROVIDERS_DATA,maemo-providers-data,have_maemo_providers_data=true,have_maemo_providers_data=false) @@ -140,7 +162,7 @@ else AC_DEFINE_UNQUOTED([MODEST_PROVIDERS_DATA_PATH],["`$PKG_CONFIG --variable=path modest-providers-data`"],[modest-providers-data file path]) providers_data="modest-providers-data" fi - +fi @@ -170,7 +192,7 @@ fi # if test "x$with_platform" == "xmaemo"; then PKG_CHECK_MODULES(MODEST_HILDON_NOTIFY,hildon-notify libnotify,have_hildon_notify=true,have_hildon_notify=false) - if test "x$have_hildon_notify"="xtrue"; then + if test "x$have_hildon_notify" == "xtrue"; then AC_DEFINE_UNQUOTED(MODEST_HAVE_HILDON_NOTIFY, 1, ["Whether hildon-notify is available"]) fi fi @@ -190,15 +212,36 @@ if test "x$with_platform" == "xmaemo"; then AC_MSG_ERROR([you need to have either osso-mime or hildon-mime installed]) fi else - helplib="hildon-mime" + mimelib="hildon-mime" AC_DEFINE_UNQUOTED(MODEST_HAVE_HILDON_MIME, 1, ["Whether hildon-mime is used."]) fi fi +PKG_CHECK_MODULES(MODEST_MOZEMBED, libtinymailui-mozembed-1.0, have_mozembed=true, have_mozembed=false) +AC_ARG_ENABLE(mozembed, +AC_HELP_STRING([--enable-mozembed], + [Build with GtkMozEmbed (yes, no)]), +[case "${enableval}" in + yes) + if test x$have_mozembed = xfalse; then + AC_MSG_ERROR([building of GtkMozEmbed support requested and gtkmozembed not found]) + fi + use_mozembed=true + ;; + *) + use_mozembed=false + ;; +esac],[use_mozembed=false]) + +AM_CONDITIONAL(BUILD_MOZEMBED, test x$use_mozembed = xtrue) +if test x$use_mozembed = xtrue; then + AC_DEFINE_UNQUOTED(MODEST_USE_MOZEMBED, 1, ["Whether we use GtkMozEmbed."]) +fi #dnl wether we can and should build the -#dnl search plugin +#dnl search plugin (on maemo) +if test "x$with_platform" == "xmaemo"; then PKG_CHECK_MODULES(MODEST_OGS, libosso >= 0.8.5 libogs-1.2, have_ogs=true, have_ogs=false) have_ogs_support=false AC_ARG_ENABLE(ogs_support, @@ -218,6 +261,7 @@ esac],[have_ogs_support=$have_ogs]) if test x$have_ogs_support = xtrue; then AC_DEFINE_UNQUOTED(MODEST_HAVE_OGS, 1, ["Whether ogs is available."]) fi +fi @@ -244,21 +288,29 @@ fi # check the version of the addressbook on maemo # if test "x$with_platform" == "xmaemo"; then - PKG_CHECK_MODULES(MODEST_ABOOK, osso-addressbook-1.0 < 2.0, have_old_abook=true,have_old_abook=false) - if test "x$have_old_abook" == "xtrue"; then - AC_DEFINE_UNQUOTED(MODEST_HAVE_OLD_ABOOK, 1, ["whether we have an old osso-addressbook"]) + PKG_CHECK_MODULES(MODEST_ABOOK,osso-addressbook-1.0,have_abook=true,have_abook=false) + AC_SUBST(MODEST_ABOOK_CFLAGS) + AC_SUBST(MODEST_ABOOK_LIBS) + + if test "x$have_abook" == "xtrue"; then + PKG_CHECK_MODULES(MODEST_ABOOK_OLD, osso-addressbook-1.0 < 2.0, have_old_abook=true,have_old_abook=false) + if test "x$have_old_abook" == "xtrue"; then + AC_DEFINE_UNQUOTED(MODEST_HAVE_OLD_ABOOK, 1, ["whether we have an old osso-addressbook"]) + fi + AC_DEFINE_UNQUOTED(MODEST_HAVE_ABOOK,1, ["whether we have osso-addressbook"]) + addressbook="osso-addressbook" fi fi +# +# if we don't have an addressbook, use the dummy one +# +AM_CONDITIONAL(MODEST_USE_DUMMY_ADDRESS_BOOK,test "x$have_abook" != "xtrue") + -#FIXME: hack to set the right gettext package.. -if test "x$have_hildon1" == "xtrue"; then - GETTEXT_PACKAGE=osso-email -else - GETTEXT_PACKAGE=modest -fi -# Check for gettext support +# gettext support +GETTEXT_PACKAGE=modest AC_SUBST(GETTEXT_PACKAGE) AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", ["gettext package"]) @@ -386,9 +438,12 @@ echo "Build docs : $build_docs" echo "Gettext Packages : $GETTEXT_PACKAGE" echo "Easysetup data : $providers_data" echo "Editor lib : $wpeditor" +echo "Addressbook : $addressbook" echo "Help lib : $helplib" +echo "Alarm : $libalarm" echo "Hildon-Notify : $have_hildon_notify" echo "LibOGS support : $have_ogs_support" +echo "MozEmbed support : $use_mozembed" echo "CFLAGS : $CFLAGS" echo "Gettext Packages : $GETTEXT_PACKAGE" echo "Debug version : $with_debug"