2005-04-02 [colin] 1.9.6cvs22
[claws.git] / configure.ac
index 0187579a6212fb498890531c0ee791a814e80518..308dbe438311bca58013a1c7c844a8a264f20b40 100644 (file)
@@ -7,13 +7,13 @@ PACKAGE=sylpheed-claws
 
 dnl version number
 MAJOR_VERSION=1
-MINOR_VERSION=0
-MICRO_VERSION=0
+MINOR_VERSION=9
+MICRO_VERSION=6
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=24
+EXTRA_VERSION=22
 EXTRA_RELEASE=
-EXTRA_GTK2_VERSION=.3
+EXTRA_GTK2_VERSION=
 
 if test \( $EXTRA_VERSION -eq 0 \) -o \( "x$EXTRA_RELEASE" != "x" \); then
     VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}${EXTRA_RELEASE}${EXTRA_GTK2_VERSION}
@@ -49,6 +49,10 @@ if test "$GNOME_CONFIG" != no; then
 fi
 AM_CONDITIONAL(SYLPHEED_GNOME, test -n "$gnomedatadir")
 
+dnl GNOME 2.x installed?
+PKG_CHECK_MODULES(GNOME2, libgnome-2.0 >= 2.0, ac_enable_gnome2=yes, ac_enable_gnome2=no)
+AM_CONDITIONAL(SYLPHEED_GNOME2, test x"$ac_enable_gnome2" = x"yes")
+
 dnl Claws version
 AC_DEFINE(CLAWS, 1, Compiling Claws branch of sylpheed)
 
@@ -127,10 +131,22 @@ esac
 dnl Checks for iconv
 AM_ICONV
 
+dnl
+dnl Check for bind_textdomain_codeset, including -lintl if GLib brings it in.
+dnl
+syl_save_LIBS=$LIBS
+LIBS="$LIBS $GTK_LIBS"
+AC_CHECK_FUNCS(bind_textdomain_codeset)
+LIBS=$syl_save_LIBS
+
 dnl for gettext
 ALL_LINGUAS="bg cs de el en_GB es fr hr hu it ja ko nl pl pt_BR ru sk sr sv zh_CN zh_TW.Big5"
-AM_GNU_GETTEXT([use-libtool])
-AM_GNU_GETTEXT_VERSION(0.12.1)
+GETTEXT_PACKAGE=sylpheed-claws
+AC_SUBST(GETTEXT_PACKAGE)
+AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [Define text domain.])
+
+AM_GLIB_GNU_GETTEXT
+dnl AM_GNU_GETTEXT
 dnl AC_CHECK_FUNC(gettext, AC_CHECK_LIB(intl, gettext))
 localedir='${prefix}/${DATADIRNAME}/locale'
 AC_SUBST(localedir)
@@ -304,10 +320,10 @@ AC_ARG_WITH(passcrypt-key, [  --with-passcrypt-key=KEY     Key used to encode pa
 AC_SUBST(PASSCRYPT_KEY, $with_passcrypt_key)
 
 dnl RC dir (will be default at a certain point in time)
-AC_ARG_WITH(config-dir,    [  --with-config-dir=RCDIR      Local configuration dir (default: .sylpheed)],
-             ac_cv_with_config_dir="$withval", ac_cv_with_config_dir=".sylpheed")
+AC_ARG_WITH(config-dir,    [  --with-config-dir=RCDIR      Local configuration dir (default: .sylpheed-gtk2)],
+             ac_cv_with_config_dir="$withval", ac_cv_with_config_dir=".sylpheed-gtk2")
 if test x"$ac_cv_with_config_dir" = x""; then
-       ac_cv_with_config_dir=".sylpheed"
+       ac_cv_with_config_dir=".sylpheed-gtk2"
 fi 
 AC_DEFINE_UNQUOTED(CFG_RC_DIR, "$ac_cv_with_config_dir", Configuration directory)
 
@@ -319,6 +335,13 @@ dnl Checks for GTK
 AM_PATH_GTK_2_0(2.4.0,,
        AC_MSG_ERROR(Test for GTK failed. See the file 'INSTALL' for help.))
 
+dnl --disable-deprecated switch for GTK2 purification
+AC_ARG_ENABLE(deprecated, [  --disable-deprecated  Disable deprecated GTK functions. ],
+                         [GTK_CFLAGS="$GTK_CFLAGS -DG_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"], [])
+
+AC_SUBST(GTK_CFLAGS)
+AC_SUBST(GTK_LIBS)
+
 dnl GNU/Aspell is used for spell checking
 AC_ARG_ENABLE(aspell,
        [  --enable-aspell         Enable GNU/aspell support [default=no]],
@@ -545,33 +568,6 @@ AC_SUBST(GTK_MATH_VIEW_CFLAGS)
 AC_SUBST(GTK_MATH_VIEW_LIBS)
 AM_CONDITIONAL(BUILD_MATHML_VIEWER_PLUGIN, test x"$ac_cv_enable_mathml_viewer_plugin" = xyes)
 
-dnl --- Image Viewer ---
-AC_ARG_ENABLE(image-viewer-plugin,
-       [  --disable-image-viewer-plugin     Do not build image viewer plugin],
-       [ac_cv_enable_image_viewer_plugin=$enableval], [ac_cv_enable_image_viewer_plugin=yes])
-if test x"$ac_cv_enable_image_viewer_plugin" = xyes; then
-       AC_ARG_ENABLE(gdk-pixbuf,
-               [  --disable-gdk-pixbuf              Do not use gdk-pixbuf],
-               [ac_cv_enable_gdk_pixbuf=$enableval], [ac_cv_enable_gdk_pixbuf=yes])
-       AC_ARG_ENABLE(imlib,
-               [  --disable-imlib                   Do not use imlib],
-               [ac_cv_enable_imlib=$enableval], [ac_cv_enable_imlib=yes])
-
-       if test "$ac_cv_enable_gdk_pixbuf" = yes; then
-               PKG_CHECK_MODULES(GDK_PIXBUF, \
-                       [ gdk-pixbuf-2.0 ],
-                       [ AC_DEFINE(HAVE_GDK_PIXBUF, 1, Define if you use gdk-pixbuf to support image viewer) ],
-                       [ ac_cv_enable_gdk_pixbuf=no ])
-       fi
-
-       if test "$ac_cv_enable_gdk_pixbuf" = yes; then
-               PLUGINS="image-viewer(gdk-pixbuf) $PLUGINS"
-       else
-               ac_cv_enable_image_viewer_plugin=no
-       fi
-fi
-AM_CONDITIONAL(BUILD_IMAGE_VIEWER_PLUGIN, test x"$ac_cv_enable_image_viewer_plugin" = xyes)
-
 dnl --- Dillo Viewer ---
 AC_ARG_ENABLE(dillo-viewer-plugin,
        [  --disable-dillo-viewer-plugin     Do not build Dillo plugin for html mail rendering],
@@ -615,7 +611,6 @@ dnl ****************************
 AC_OUTPUT([
 Makefile
 sylpheed.spec
-intl/Makefile
 m4/Makefile
 po/Makefile.in
 src/common/version.h
@@ -628,7 +623,6 @@ src/plugins/demo/Makefile
 src/plugins/spamassassin/Makefile
 src/plugins/mathml_viewer/Makefile
 src/plugins/dillo_viewer/Makefile
-src/plugins/image_viewer/Makefile
 src/plugins/trayicon/Makefile
 src/plugins/trayicon/libeggtrayicon/Makefile
 src/plugins/clamav/Makefile