1 dnl Process this file with autoconf to produce a configure script.
4 AC_CONFIG_AUX_DIR(config)
18 if test \( $EXTRA_VERSION -eq 0 \) -o \( "x$EXTRA_RELEASE" != "x" \); then
19 VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}${EXTRA_RELEASE}${EXTRA_GTK2_VERSION}
21 VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}cvs${EXTRA_VERSION}${EXTRA_GTK2_VERSION}
28 AM_INIT_AUTOMAKE($PACKAGE, $VERSION, no-define)
29 dnl AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
30 dnl AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
33 AC_SUBST(MAJOR_VERSION)
34 AC_SUBST(MINOR_VERSION)
35 AC_SUBST(MICRO_VERSION)
36 AC_SUBST(EXTRA_VERSION)
39 AC_PATH_PROG(GNOME_CONFIG, gnome-config, no)
40 if test "$GNOME_CONFIG" != no; then
41 gnomedatadir="`gnome-config --datadir`"
42 gnomeprefix="`gnome-config --prefix`"
43 if test "${prefix}" = "NONE"; then
44 gnomedatadir="${ac_default_prefix}/${gnomedatadir#${gnomeprefix}}"
46 gnomedatadir="${prefix}/${gnomedatadir#${gnomeprefix}}"
48 AC_SUBST(gnomedatadir)
50 AM_CONDITIONAL(SYLPHEED_GNOME, test -n "$gnomedatadir")
52 dnl GNOME 2.x installed?
53 PKG_CHECK_MODULES(GNOME2, libgnome-2.0 >= 2.0, ac_enable_gnome2=yes, ac_enable_gnome2=no)
54 AM_CONDITIONAL(SYLPHEED_GNOME2, test x"$ac_enable_gnome2" = x"yes")
57 AC_DEFINE(CLAWS, 1, Compiling Claws branch of sylpheed)
59 dnl libtool versioning
60 LT_RELEASE=$MAJOR_VERSION.$MINOR_VERSION
61 LT_CURRENT=`expr $MICRO_VERSION - $INTERFACE_AGE`
62 LT_REVISION=$INTERFACE_AGE
63 LT_AGE=`expr $BINARY_AGE - $INTERFACE_AGE`
69 dnl Specify a header configuration file
70 AC_CONFIG_HEADERS(config.h)
74 dnl Checks for programs.
90 SYLPHEED_ACLOCAL_INCLUDE(m4)
92 dnl ******************************
94 dnl Not needed anymore because we
95 dnl do AC_CANONICAL_SYSTEM above
96 dnl ******************************
99 dnl Copied from the official gtk+-2 configure.in
100 AC_MSG_CHECKING([for some Win32 platform])
102 *-*-mingw*|*-*-cygwin*)
104 LDFLAGS="$LDFLAGS -mwindows"
110 AC_MSG_RESULT([$platform_win32])
111 AM_CONDITIONAL(PLATFORM_WIN32, test x"$platform_win32" = x"yes")
113 AC_MSG_CHECKING([for native Win32])
122 AC_MSG_RESULT([$os_win32])
123 AM_CONDITIONAL(OS_WIN32, test x"$os_win32" = x"yes")
125 AC_MSG_CHECKING([for Cygwin])
134 AC_MSG_RESULT([$env_cygwin])
135 AM_CONDITIONAL(CYGWIN, test x"$env_cygwin" = x"yes")
137 CFLAGS="$CFLAGS -Wall"
142 CFLAGS="$CFLAGS -no-cpp-precomp -fno-common"
145 # Note that we need to link to pthreadGC2 in all cases. This
146 # is because some locking is used even when pthread support is
148 pthread_name=pthreadGC2
149 CFLAGS="$CFLAGS -mms-bitfields"
150 LIBS="$LIBS -l${pthread_name} -lws2_32 -lregex"
158 dnl Check for bind_textdomain_codeset, including -lintl if GLib brings it in.
161 LIBS="$LIBS $GTK_LIBS"
162 AC_CHECK_FUNCS(bind_textdomain_codeset)
166 ALL_LINGUAS="bg ca cs de el en_GB es fi fr hr hu it ja ko nb nl pl pt_BR ru sk sr sv zh_CN zh_TW"
167 GETTEXT_PACKAGE=sylpheed-claws
168 AC_SUBST(GETTEXT_PACKAGE)
169 AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [Define text domain.])
171 AM_GNU_GETTEXT_VERSION([0.15])
172 AM_GNU_GETTEXT([external])
174 manualdir='${datarootdir}/${PACKAGE}/manual'
175 AC_ARG_WITH(manualdir,
176 [ --with-manualdir=DIR Manual directory],
177 [manualdir="$withval"])
180 AC_ARG_ENABLE(manual,
181 [ --disable-manual Disable manual support],
182 [ac_cv_enable_manual=$enableval], [ac_cv_enable_manual=yes])
184 AM_CONDITIONAL(BUILD_MANUAL, test x"$ac_cv_enable_manual" = xyes)
186 dnl Set PACKAGE_DATA_DIR in config.h.
187 if test "x${datarootdir}" = 'x${prefix}/share'; then
188 if test "x${prefix}" = "xNONE"; then
189 AC_DEFINE_UNQUOTED(PACKAGE_DATA_DIR, "${ac_default_prefix}/share/${PACKAGE}",[PACKAGE_DATA_DIR])
191 AC_DEFINE_UNQUOTED(PACKAGE_DATA_DIR, "${prefix}/share/${PACKAGE}",[PACKAGE_DATA_DIR])
194 AC_DEFINE_UNQUOTED(PACKAGE_DATA_DIR, "${datarootdir}/${PACKAGE}",[PACKAGE_DATA_DIR])
197 AC_CHECK_LIB(xpg4, setlocale)
202 [ --disable-libsm Do not use libSM for session management.],
203 [ac_cv_enable_libsm=$enableval], [ac_cv_enable_libsm=yes])
204 AC_MSG_CHECKING([whether to use LibSM])
205 if test x"$ac_cv_enable_libsm" = xyes; then
207 AC_CHECK_LIB(SM, SmcSaveYourselfDone,
208 [SM_LIBS="$X_LIBS -lSM -lICE"],ac_cv_enable_libsm=no,
210 AC_CHECK_HEADERS(X11/SM/SMlib.h,,SC_HAVE_SM=false)
211 if test x"$ac_cv_enable_libsm" = xyes; then
212 AC_DEFINE(HAVE_LIBSM, 1, [Define to 1 if you have libSM installed])
214 AC_MSG_RESULT(not found)
215 AC_MSG_WARN([*** LibSM will not be supported ***])
222 dnl for GThread support (currently disabled)
223 dnl AC_ARG_ENABLE(threads,
224 dnl [ --enable-threads Enable multithread support [default=no]],
225 dnl [use_threads=$enableval], [use_threads=no])
227 AC_MSG_CHECKING([whether to use threads])
228 if test x"$use_threads" = xyes ; then
230 if test ! -z `$GLIB_CONFIG --help 2>&1 |grep 'gthread'` ; then
231 CFLAGS="$CFLAGS `$GLIB_CONFIG --cflags gthread`"
232 LIBS="$LIBS `$GLIB_CONFIG --libs gthread`"
233 AC_DEFINE(USE_THREADS, 1, Whether to use multithread or not)
235 AC_MSG_ERROR([Sylpheed requires GThread from GLib to use threading.])
241 dnl Check for d_type member in struct dirent
242 AC_MSG_CHECKING([whether struct dirent has d_type member])
243 AC_CACHE_VAL(ac_cv_dirent_d_type,[
244 AC_TRY_COMPILE([#include <dirent.h>],
245 [struct dirent d; d.d_type = DT_REG;],
246 ac_cv_dirent_d_type=yes, ac_cv_dirent_d_type=no)
248 AC_MSG_RESULT($ac_cv_dirent_d_type)
249 if test $ac_cv_dirent_d_type = yes; then
250 AC_DEFINE(HAVE_DIRENT_D_TYPE, 1,
251 Define if `struct dirent' has `d_type' member.)
254 # Check whether mkdir does not take the permission argument.
255 GNUPG_FUNC_MKDIR_TAKES_ONE_ARG
257 dnl Checks for header files.
261 AC_CHECK_HEADERS(fcntl.h sys/file.h unistd.h paths.h \
262 sys/param.h sys/utsname.h sys/select.h \
263 wchar.h wctype.h locale.h netdb.h)
265 dnl alf - Check for apache installation f*ck up. apache may also install an
266 dnl fnmatch, which includes their own regex stuff if USE_HSREGEX is defined
267 AC_TRY_COMPILE([#include <stdlib.h>
268 #include <fnmatch.h>],
269 [int x = USE_HSREGEX;],
270 ac_cv_have_apache_fnmatch=yes, ac_cv_have_apache_fnmatch=no)
271 if test $ac_cv_have_apache_fnmatch = yes; then
272 AC_DEFINE(HAVE_APACHE_FNMATCH, 1, Define if you need to work around apache regex/fnmatch !KLUDGE!)
274 AC_MSG_CHECKING([whether to use Apache regex header kludge])
275 AC_MSG_RESULT($ac_cv_have_apache_fnmatch)
277 dnl Checks for typedefs, structures, and compiler characteristics.
284 dnl AC_CHECK_TYPE(wint_t, unsigned int) does not work because wint_t
285 dnl may be defined only in wchar.h (this happens with gcc-2.96).
286 dnl So we need to use this extended macro.
287 SYLPHEED_CHECK_TYPE(wint_t, unsigned int,
292 ], Define to `unsigned int' if <stddef.h> or <wchar.h> doesn't define.)
294 GNUPG_CHECK_TYPEDEF(u32, HAVE_U32_TYPEDEF, Used to test for a u32 typedef)
295 AC_CHECK_SIZEOF(unsigned short, 2)
296 AC_CHECK_SIZEOF(unsigned int, 4)
297 AC_CHECK_SIZEOF(unsigned long, 4)
299 dnl Checks for library functions.
301 AC_CHECK_FUNCS(gethostname mkdir mktime socket strstr strchr \
302 uname flock lockf inet_aton inet_addr \
303 fchmod mkstemp truncate getuid regcomp)
305 dnl *****************
306 dnl ** common code **
307 dnl *****************
310 AM_PATH_GLIB_2_0(2.6.0,,
311 AC_MSG_ERROR(Test for GLIB failed. See the file 'INSTALL' for help.),
312 gmodule gobject gthread)
314 dnl Check for bind_textdomain_codeset, including -lintl if GLib brings it in.
316 LIBS="$LIBS $GTK_LIBS"
317 AC_CHECK_FUNCS(bind_textdomain_codeset)
320 dnl check for IPv6 option
322 [ --disable-ipv6 Disable IPv6 support],
323 [ac_cv_enable_ipv6=$enableval], [ac_cv_enable_ipv6=yes])
325 dnl automated checks for IPv6 support.
326 AC_MSG_CHECKING([whether to use IPv6])
327 if test x"$ac_cv_enable_ipv6" = xyes; then
329 AC_MSG_CHECKING([for IPv6 support])
330 AC_CACHE_VAL(ac_cv_ipv6,[
331 AC_TRY_COMPILE([#define INET6
332 #include <sys/types.h>
333 #include <netinet/in.h>],
334 [int x = IPPROTO_IPV6; struct in6_addr a;],
335 ac_cv_ipv6=yes, ac_cv_ipv6=no)
337 AC_MSG_RESULT($ac_cv_ipv6)
338 if test $ac_cv_ipv6 = yes; then
339 AC_DEFINE(INET6, 1, Define if you want IPv6 support.)
341 AC_MSG_WARN(*** IPv6 will not be supported ***)
348 dnl Check for OpenSSL
349 AC_ARG_ENABLE(openssl,
350 [ --disable-openssl Do not use OpenSSL for SSL support.],
351 [ac_cv_enable_openssl=$enableval], [ac_cv_enable_openssl=yes])
352 AC_MSG_CHECKING([whether to use OpenSSL])
353 if test x"$ac_cv_enable_openssl" = xyes; then
355 PKG_CHECK_MODULES(OPENSSL, openssl >= 0.9.7, :, ac_cv_enable_openssl=no)
356 if test x$ac_cv_enable_openssl = xyes; then
357 AC_DEFINE(USE_OPENSSL, 1, Define if you want OpenSSL support)
359 AC_MSG_RESULT(not found)
360 AC_MSG_WARN([*** OpenSSL will not be supported ***])
365 AC_SUBST(OPENSSL_CFLAGS)
366 AC_SUBST(OPENSSL_LIBS)
368 dnl password encryption
373 AC_SEARCH_LIBS(encrypt, cipher, [], AC_MSG_ERROR(['encrypt'-function not found.]))
376 AC_SEARCH_LIBS(encrypt, crypt, [], AC_MSG_ERROR(['encrypt'-function not found.]))
383 AC_ARG_WITH(passcrypt-key, [ --with-passcrypt-key=KEY Key used to encode passwords (8 byte string)],
384 with_passcrypt_key="$withval", with_passcrypt_key="passkey0")
385 AC_SUBST(PASSCRYPT_KEY, $with_passcrypt_key)
387 dnl RC dir (will be default at a certain point in time)
388 AC_ARG_WITH(config-dir, [ --with-config-dir=RCDIR Local configuration dir (default: .sylpheed-claws)],
389 ac_cv_with_config_dir="$withval", ac_cv_with_config_dir=".sylpheed-claws")
390 if test x"$ac_cv_with_config_dir" = x""; then
391 ac_cv_with_config_dir=".sylpheed-claws"
393 AC_DEFINE_UNQUOTED(CFG_RC_DIR, "$ac_cv_with_config_dir", Configuration directory)
395 dnl ************************
396 dnl ** GTK user interface **
397 dnl ************************
400 AM_PATH_GTK_2_0(2.6.0,,
401 AC_MSG_ERROR(Test for GTK failed. See the file 'INSTALL' for help.))
403 dnl --disable-deprecated switch for GTK2 purification
404 AC_ARG_ENABLE(deprecated, [ --disable-deprecated Disable deprecated GTK functions. ],
405 [GTK_CFLAGS="$GTK_CFLAGS -DG_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"], [])
410 dnl GNU/Aspell is used for spell checking
411 AC_ARG_ENABLE(aspell,
412 [ --disable-aspell Disable GNU/aspell support [default=yes]],
413 [ac_cv_enable_aspell=$enableval], [ac_cv_enable_aspell=yes])
414 AC_MSG_CHECKING([whether to use GNU/aspell])
415 if test $ac_cv_enable_aspell = yes; then
417 AM_PATH_ASPELL(0.50, AC_DEFINE(USE_ASPELL, 1, Define if you use ASPELL to support spell checking),
418 [use_aspell=no ac_cv_enable_aspell=no])
423 dnl want crash dialog
424 AC_ARG_ENABLE(crash-dialog,
425 [ --enable-crash-dialog Enable crash dialog [default=no]],
426 [ac_cv_enable_crash_dialog=$enableval], [ac_cv_enable_crash_dialog=no])
427 if test $ac_cv_enable_crash_dialog = yes; then
428 dnl check if GDB is somewhere
429 AC_CHECK_PROG(ac_cv_enable_crash_dialog, gdb, yes, no)
430 AC_MSG_CHECKING([whether to use crash dialog])
431 if test $ac_cv_enable_crash_dialog = yes; then
432 AC_DEFINE(CRASH_DIALOG, 1, Pop up crash dialog)
434 AC_MSG_RESULT($ac_cv_enable_crash_dialog)
437 dnl Check for X-Face support
438 AC_ARG_ENABLE(compface,
439 [ --disable-compface Do not use compface (X-Face)],
440 [ac_cv_enable_compface=$enableval], [ac_cv_enable_compface=yes])
441 AC_MSG_CHECKING([whether to use compface])
442 if test x"$ac_cv_enable_compface" = xyes; then
444 AC_CHECK_LIB(compface, uncompface,
445 [AC_DEFINE(HAVE_LIBCOMPFACE, 1, Define if you want compface support.)],
446 [ac_cv_enable_compface=no])
447 if test x"$ac_cv_enable_compface" = xyes; then
448 COMPFACE_LIBS="-lcompface"
452 AC_SUBST(COMPFACE_LIBS)
457 dnl check for pthread support
458 AC_ARG_ENABLE(pthread,
459 [ --disable-pthread Disable pthread support],
460 [ac_cv_enable_pthread=$enableval], [ac_cv_enable_pthread=yes])
461 AC_MSG_CHECKING([whether to use pthread])
462 if test x$ac_cv_enable_pthread = xno; then
467 # For W32 we need to use a special ptrhead lib. In this case we can't
468 # use AC_CHECK_LIB because it has no means of checking for a
469 # library installed under a different name. Checking for the
471 if test -n "${pthread_name}" ; then
472 ac_cv_enable_pthread=yes
474 AC_CHECK_LIB(pthread, pthread_create, :, ac_cv_enable_pthread=no)
476 AC_CHECK_HEADERS(pthread.h, :, ac_cv_enable_pthread=no)
478 if test x$ac_cv_enable_pthread = xyes; then
479 AC_DEFINE(USE_PTHREAD, 1, Define if you have pthread)
480 if test -z "${pthread_name}" ; then
481 PTHREAD_LIBS="-lpthread"
486 AC_SUBST(PTHREAD_LIBS)
489 dnl Check whether we need to pass -lresolv
490 dnl We know that we don't need it for W32.
492 if test x$os_win32 = xno; then
495 ac_cv_var__res_options=no
496 AC_TRY_LINK([#include <sys/types.h>
497 #include <sys/socket.h>
498 #include <netinet/in.h>
499 #include <arpa/nameser.h>
500 #include <resolv.h>],
501 [_res.options = RES_INIT;],
502 ac_cv_var__res_options=yes);
503 if test "$ac_cv_var__res_options" != "yes"; then
508 if test "x$LIBRESOLV" = "x"; then
509 AC_CHECK_LIB(resolv, res_query, [LIBRESOLV=-lresolv])
515 LIBS="$LIBS $LIBRESOLV"
517 dnl for LDAP support in addressbook
518 dnl no check for libraries; dynamically loaded
520 [ --disable-ldap Do not build LDAP support [default=yes]],
521 [ac_cv_enable_ldap=$enableval], [ac_cv_enable_ldap=yes])
522 AC_MSG_CHECKING([whether to use LDAP])
523 if test x"$ac_cv_enable_ldap" = xno; then
525 elif test x"$ac_cv_enable_ldap" = xyes -a x"$ac_cv_enable_pthread" = xno; then
526 AC_MSG_RESULT(no - LDAP support needs pthread support)
532 dnl check for available libraries, and pull them in
533 AC_CHECK_LIB(resolv, res_query, LDAP_LIBS="$LDAP_LIBS -lresolv")
534 AC_CHECK_LIB(socket, bind, LDAP_LIBS="$LDAP_LIBS -lsocket")
535 AC_CHECK_LIB(nsl, gethostbyaddr, LDAP_LIBS="$LDAP_LIBS -lnsl")
536 AC_CHECK_LIB(lber, ber_get_tag, LDAP_LIBS="$LDAP_LIBS -llber",,
539 AC_CHECK_HEADERS(ldap.h lber.h,
540 [ ac_cv_enable_ldap=yes ],
541 [ ac_cv_enable_ldap=no ])
543 if test "$ac_cv_enable_ldap" = yes; then
544 AC_CHECK_LIB(ldap, ldap_open,
545 [ ac_cv_enable_ldap=yes ],
546 [ ac_cv_enable_ldap=no ],
549 AC_CHECK_LIB(ldap, ldap_start_tls_s,
550 [ ac_cv_have_tls=yes ],
551 [ ac_cv_have_tls=no ])
555 AC_MSG_CHECKING([whether ldap library is available])
556 AC_MSG_RESULT($ac_cv_enable_ldap)
558 AC_MSG_CHECKING([whether TLS library is available])
559 AC_MSG_RESULT($ac_cv_have_tls)
561 if test "$ac_cv_enable_ldap" = yes; then
562 AC_DEFINE(USE_LDAP, 1, Define if you want LDAP support in addressbook.)
563 LDAP_LIBS="$LDAP_LIBS -lldap"
565 if test "$ac_cv_have_tls" = yes; then
566 AC_DEFINE(USE_LDAP_TLS, 1, Define if you want LDAP TLS support in addressbook.)
571 dnl for JPilot support in addressbook
572 dnl no check for libraries; these are dynamically loaded
573 AC_ARG_ENABLE(jpilot,
574 [ --disable-jpilot Enable JPilot support [default=yes]],
575 [ac_cv_enable_jpilot=$enableval], [ac_cv_enable_jpilot=yes])
576 AC_MSG_CHECKING([whether to use JPilot])
577 if test "$ac_cv_enable_jpilot" = yes; then
579 AC_CHECK_HEADERS(pi-args.h pi-appinfo.h pi-address.h,
580 [ AC_DEFINE(USE_JPILOT, 1, Define if you want JPilot support in addressbook.) ],
581 [ ac_cv_enable_jpilot=no ])
582 if test "$ac_cv_enable_jpilot" = no; then
583 AC_CHECK_HEADERS(libpisock/pi-args.h libpisock/pi-appinfo.h libpisock/pi-address.h,
584 [ ac_cv_enable_jpilot=yes
585 AC_DEFINE(USE_JPILOT, 1, Define if you want JPilot support in addressbook.) ])
588 AC_CHECK_LIB(pisock, unpack_Address, [JPILOT_LIBS="-lpisock"], [JPILOT_LIBS="" ac_cv_enable_jpilot="no"])
589 if test x"$ac_cv_enable_jpilot" = xyes; then
590 AC_DEFINE(USE_JPILOT, 1, Define if you want JPilot support in addressbook.)
592 AC_MSG_NOTICE([JPilot support not available])
594 AC_SUBST(JPILOT_LIBS)
599 dnl #######################################################################
600 dnl # Check for startup notification
601 dnl #######################################################################
602 AC_ARG_ENABLE(startup-notification, [ --disable-startup-notification compile without startup notification support],,enable_startup_notification=yes)
604 if test "x$enable_startup_notification" = "xyes"; then
605 PKG_CHECK_MODULES(STARTUP_NOTIFICATION, libstartup-notification-1.0 >= 0.5,
607 AC_DEFINE(HAVE_STARTUP_NOTIFICATION, 1, [Define if we're using libstartup-notification.])
608 echo "Building with libstartup-notification"
609 enable_startup_notification=yes
612 echo "Building without libstartup-notification"
613 enable_startup_notification=no
616 AC_SUBST(STARTUP_NOTIFICATION_CFLAGS)
617 AC_SUBST(STARTUP_NOTIFICATION_LIBS)
620 dnl *************************
621 dnl ** section for plugins **
622 dnl *************************
627 AC_MSG_CHECKING([whether to build Trayicon plugin])
628 AC_ARG_ENABLE(trayicon-plugin,
629 [ --disable-trayicon-plugin Do not build System Tray Icon plugin],
630 [ac_cv_enable_trayicon_plugin=$enableval], [ac_cv_enable_trayicon_plugin=yes])
631 if test x"$ac_cv_enable_trayicon_plugin" = xyes; then
633 PLUGINS="trayicon $PLUGINS"
637 AM_CONDITIONAL(BUILD_TRAYICON_PLUGIN, test x"$ac_cv_enable_trayicon_plugin" = xyes)
639 dnl --- SpamAssassin ---
640 AC_MSG_CHECKING([whether to build SpamAssassin plugin])
641 AC_ARG_ENABLE(spamassassin-plugin,
642 [ --disable-spamassassin-plugin Build SpamAssassin plugin [default=yes]],
643 [ac_cv_enable_spamassassin_plugin=$enableval], [ac_cv_enable_spamassassin_plugin=yes])
644 if test x"$ac_cv_enable_spamassassin_plugin" = xyes; then
647 PLUGINS="spamassassin $PLUGINS"
648 AC_DEFINE(USE_SPAMASSASSIN_PLUGIN, 1, Define if spamassassin plugin is being build.)
652 AM_CONDITIONAL(BUILD_SPAMASSASSIN_PLUGIN, test x"$ac_cv_enable_spamassassin_plugin" = xyes)
654 dnl --- Bogofilter ---
655 AC_MSG_CHECKING([whether to build Bogofilter plugin])
656 AC_ARG_ENABLE(bogofilter-plugin,
657 [ --disable-bogofilter-plugin Build bogofilter plugin [default=yes]],
658 [ac_cv_enable_bogofilter_plugin=$enableval], [ac_cv_enable_bogofilter_plugin=yes])
659 if test x"$ac_cv_enable_bogofilter_plugin" = xyes; then
661 PLUGINS="bogofilter $PLUGINS"
662 AC_DEFINE(USE_BOGOFILTER_PLUGIN, 1, Define if bogofilter plugin is being build.)
666 AM_CONDITIONAL(BUILD_BOGOFILTER_PLUGIN, test x"$ac_cv_enable_bogofilter_plugin" = xyes)
669 AC_MSG_CHECKING([whether to build PGP/CORE plugin])
670 AC_ARG_ENABLE(pgpcore-plugin,
671 [ --disable-pgpcore-plugin Do not build PGP/Core plugin],
672 [ac_cv_enable_pgpcore_plugin=$enableval], [ac_cv_enable_pgpcore_plugin=yes])
673 if test x"$ac_cv_enable_pgpcore_plugin" = xyes; then
675 AM_PATH_GPGME(1.0.0, AC_DEFINE(USE_GPGME, 1, Define if you use GPGME to support OpenPGP.),
676 [ac_cv_enable_pgpcore_plugin=no])
677 if test x"$ac_cv_enable_pgpcore_plugin" = xyes; then
678 PLUGINS="pgpcore $PLUGINS"
680 AC_DEFINE(HAVE_GPGME_PKA_TRUST, 1,
681 [Define if GPGME supports PKA.]))
682 #needed to get GPGME_LIBS and al correctly
683 AM_PATH_GPGME(1.0.0, AC_DEFINE(USE_GPGME, 1, Define if you use GPGME to support OpenPGP.),
684 [ac_cv_enable_pgpcore_plugin=no])
686 AC_MSG_WARN([*** PGP/CORE plugin will not be built ***])
691 AM_CONDITIONAL(BUILD_PGPCORE_PLUGIN, test x"$ac_cv_enable_pgpcore_plugin" = xyes)
693 AC_MSG_CHECKING([whether to build PGP/MIME plugin])
694 AC_ARG_ENABLE(pgpmime-plugin,
695 [ --disable-pgpmime-plugin Do not build PGP/MIME plugin],
696 [ac_cv_enable_pgpmime_plugin=$enableval], [ac_cv_enable_pgpmime_plugin=yes])
697 if test x"$ac_cv_enable_pgpmime_plugin" = xyes; then
699 if test x"$ac_cv_enable_pgpcore_plugin" = xyes; then
700 PLUGINS="pgpmime $PLUGINS"
702 AC_MSG_WARN([*** PGP/MIME plugin cannot be built ***])
703 AC_MSG_WARN([*** without the PGP/CORE plugin ***])
708 AM_CONDITIONAL(BUILD_PGPMIME_PLUGIN, test x"$ac_cv_enable_pgpmime_plugin" = xyes)
710 AC_MSG_CHECKING([whether to build PGP/Inline plugin])
711 AC_ARG_ENABLE(pgpinline-plugin,
712 [ --disable-pgpinline-plugin Do not build PGP/Inline plugin],
713 [ac_cv_enable_pgpinline_plugin=$enableval], [ac_cv_enable_pgpinline_plugin=yes])
714 if test x"$ac_cv_enable_pgpinline_plugin" = xyes; then
716 if test x"$ac_cv_enable_pgpcore_plugin" = xyes; then
717 PLUGINS="pgpinline $PLUGINS"
719 AC_MSG_WARN([*** PGP/Inline plugin cannot be built ***])
720 AC_MSG_WARN([*** without the PGP/CORE plugin ***])
725 AM_CONDITIONAL(BUILD_PGPINLINE_PLUGIN, test x"$ac_cv_enable_pgpinline_plugin" = xyes)
727 dnl --- Dillo Viewer ---
728 AC_MSG_CHECKING([whether to build Dillo plugin])
729 AC_ARG_ENABLE(dillo-viewer-plugin,
730 [ --disable-dillo-viewer-plugin Do not build Dillo plugin for html mail rendering],
731 [ac_cv_enable_dillo_viewer_plugin=$enableval], [ac_cv_enable_dillo_viewer_plugin=yes])
732 if test x"$ac_cv_enable_dillo_viewer_plugin" = xyes; then
734 PLUGINS="dillo-viewer $PLUGINS"
738 AM_CONDITIONAL(BUILD_DILLO_VIEWER_PLUGIN, test x"$ac_cv_enable_dillo_viewer_plugin" = xyes)
741 AC_ARG_ENABLE(demo-plugin,
742 [ --enable-demo-plugin Build demo plugin [default=no]],
743 [ac_cv_enable_demo_plugin=$enableval], [ac_cv_enable_demo_plugin=no])
744 if test x"$ac_cv_enable_demo_plugin" = xyes; then
745 PLUGINS="demo $PLUGINS"
747 AM_CONDITIONAL(BUILD_DEMO_PLUGIN, test x"$ac_cv_enable_demo_plugin" = xyes)
750 AC_MSG_CHECKING([whether to build ClamAV plugin])
751 AC_ARG_ENABLE(clamav-plugin,
752 [ --disable-clamav-plugin Do not build Clam AntiVirus plugin],
753 [ac_cv_enable_clamav_plugin=$enableval], [ac_cv_enable_clamav_plugin=yes])
754 if test x"$ac_cv_enable_clamav_plugin" = xyes; then
756 PKG_CHECK_MODULES(CLAMAV, libclamav, ac_cv_enable_clamav_plugin=yes,
757 ac_cv_enable_clamav_plugin=no)
758 if test x"$ac_cv_enable_clamav_plugin" = xyes; then
759 PLUGINS="clamav $PLUGINS"
761 AC_MSG_RESULT(not found)
762 AC_MSG_WARN([*** ClamAV plugin will not be built ***])
767 AC_SUBST(CLAMAV_LIBS)
768 AM_CONDITIONAL(BUILD_CLAMAV_PLUGIN, test x"$ac_cv_enable_clamav_plugin" = xyes)
771 AC_MSG_CHECKING([whether to use libetpan])
772 AC_ARG_ENABLE(libetpan,
773 [ --disable-libetpan Do not compile IMAP4 support with libetpan],
774 [ac_cv_enable_libetpan=$enableval], [ac_cv_enable_libetpan=yes])
775 if test x"$ac_cv_enable_libetpan" = xyes; then
778 AC_PATH_PROG(libetpanconfig, [libetpan-config])
779 if test "x$libetpanconfig" != "x"; then
780 CPPFLAGS="$CPPFLAGS `$libetpanconfig --cflags 2>/dev/null`"
781 AC_CHECK_HEADER(libetpan/libetpan.h, [libetpan_result=yes])
782 if test "x$libetpan_result" = "xyes"; then
783 AC_MSG_CHECKING([whether libetpan-config hints compiles and links fine])
784 LIBS="$LIBS `$libetpanconfig --libs 2>/dev/null`"
785 AC_TRY_LINK([#include <libetpan/dbstorage.h>], [db_mailstorage_init(NULL, NULL);], [libetpan_result=yes], [libetpan_result=no])
786 AC_MSG_RESULT([$libetpan_result])
789 if test "x$libetpan_result" = "xyes"; then
790 LIBETPAN_CPPFLAGS="`$libetpanconfig --cflags`"
791 LIBETPAN_LIBS="`$libetpanconfig --libs`"
792 LIBETPAN_VERSION=`$libetpanconfig --version | sed "s/\.//g" | sed "s/-.*$//"`
793 if test "$LIBETPAN_VERSION" -lt "046"; then
794 AC_MSG_RESULT([*** Sylpheed requires libetpan 0.46 or newer. See http://www.etpan.org/])
795 AC_MSG_RESULT([*** You can use --disable-libetpan if you don't need IMAP4 support.])
796 AC_MSG_ERROR([libetpan 0.46 not found])
798 AC_SUBST(LIBETPAN_FLAGS)
799 AC_SUBST(LIBETPAN_LIBS)
800 AC_DEFINE(HAVE_LIBETPAN, 1, Define if you want IMAP support.)
802 AC_MSG_RESULT([*** Sylpheed requires libetpan 0.46 or newer. See http://www.etpan.org/ ])
803 AC_MSG_RESULT([*** You can use --disable-libetpan if you don't need IMAP4 support.])
804 AC_MSG_ERROR([libetpan 0.46 not found])
809 AM_CONDITIONAL(SYLPHEED_LIBETPAN, test "x$libetpan_result" = "xyes")
813 AC_MSG_CHECKING([whether to use libgnomeprint])
814 AC_ARG_ENABLE(gnomeprint,
815 [ --disable-gnomeprint Do not use libgnomeprint for printing],
816 [ac_cv_enable_gnomeprint=$enableval], [ac_cv_enable_gnomeprint=yes])
817 if test x$ac_cv_enable_gnomeprint = xyes; then
819 PKG_CHECK_MODULES(GNOMEPRINT, libgnomeprint-2.2 libgnomeprintui-2.2,
820 ac_cv_enable_gnomeprint=yes, ac_cv_enable_gnomeprint=no)
821 if test x"$ac_cv_enable_gnomeprint" = xyes; then
822 AC_DEFINE(USE_GNOMEPRINT, 1, Define if you want libgnomeprint support)
824 AC_MSG_RESULT(not found)
825 AC_MSG_WARN([*** libgnomeprintui wasn't found ***])
826 AC_MSG_WARN([*** using built-in printing support ***])
831 AM_CONDITIONAL(SYLPHEED_GNOMEPRINT, test x"$ac_cv_enable_gnomeprint" = x"yes")
833 dnl ****************************
834 dnl ** Final configure output **
835 dnl ****************************
844 src/common/passcrypt.h
848 src/plugins/demo/Makefile
849 src/plugins/bogofilter/Makefile
850 src/plugins/spamassassin/Makefile
851 src/plugins/dillo_viewer/Makefile
852 src/plugins/trayicon/Makefile
853 src/plugins/trayicon/libeggtrayicon/Makefile
854 src/plugins/clamav/Makefile
855 src/plugins/pgpcore/Makefile
856 src/plugins/pgpmime/Makefile
857 src/plugins/pgpinline/Makefile
865 manual/dist/pdf/Makefile
866 manual/dist/ps/Makefile
867 manual/dist/html/Makefile
868 manual/dist/txt/Makefile
870 manual/fr/dist/Makefile
871 manual/fr/dist/pdf/Makefile
872 manual/fr/dist/ps/Makefile
873 manual/fr/dist/html/Makefile
874 manual/fr/dist/txt/Makefile
876 manual/pl/dist/Makefile
877 manual/pl/dist/pdf/Makefile
878 manual/pl/dist/ps/Makefile
879 manual/pl/dist/html/Makefile
880 manual/pl/dist/txt/Makefile
882 manual/es/dist/Makefile
883 manual/es/dist/pdf/Makefile
884 manual/es/dist/ps/Makefile
885 manual/es/dist/html/Makefile
886 manual/es/dist/txt/Makefile
890 dnl Output the configuration summary
892 echo "$PACKAGE $VERSION"
894 echo "JPilot : $ac_cv_enable_jpilot"
895 echo "LDAP : $ac_cv_enable_ldap"
896 echo "OpenSSL : $ac_cv_enable_openssl"
897 echo "iconv : $am_cv_func_iconv"
898 echo "compface : $ac_cv_enable_compface"
899 echo "IPv6 : $ac_cv_enable_ipv6"
900 echo "GNU/aspell : $ac_cv_enable_aspell"
901 echo "IMAP4 : $ac_cv_enable_libetpan"
902 echo "Crash dialog : $ac_cv_enable_crash_dialog"
903 echo "Libgnomeprint : $ac_cv_enable_gnomeprint"
904 echo "LibSM : $ac_cv_enable_libsm"
905 echo "Manual : $ac_cv_enable_manual"
906 echo "Plugins : $PLUGINS"
907 echo "Config dir : $ac_cv_with_config_dir"
909 echo "The binary will be installed in $prefix/bin"
911 echo "Configure finished, type 'make' to build."