<<< Date Index >>>     <<< Thread Index >>>

[PATCH] compiling Mutt under Fedora



I ran into an issue compiling Mutt with GPGME support under Fedora 13, and just wanted to give a heads up. Fedora's gpgme-config --libs excludes -lgpg-error, which is different from the upstream sources. I filed a bug [1], but the maintainer claims it is intentional.

As a workaround, you can either apply the attached patch, or you can manually edit /usr/bin/gpgme-config (it's a shell script) and uncomment the line:

        #gpg_error_libs="-lgpg-error"

If upstream gpgme changes the default behavior, I will commit the patch. For now I am reluctant to apply it, although at least under Ubuntu 8.04.04 it harmlessly adds -lgpg-error twice.

me

[1] https://bugzilla.redhat.com/show_bug.cgi?id=621626
# HG changeset patch
# User Michael Elkins <me@xxxxxxxx>
# Date 1281038117 25200
# Branch HEAD
# Node ID d9af6aad75aa33329637ef28e12497b0b1ab1568
# Parent  59ca5d7b16561144d95ca3d3b50b26cdf714386f
fix for compiling under fedora where gpgme-config --libs does not include 
-lgpg-error

diff --git a/Makefile.am b/Makefile.am
--- a/Makefile.am
+++ b/Makefile.am
@@ -38,7 +38,7 @@
 nodist_mutt_SOURCES = $(BUILT_SOURCES)
 
 mutt_LDADD = @MUTT_LIB_OBJECTS@ @LIBOBJS@ $(LIBIMAP) $(MUTTLIBS) \
-       $(INTLLIBS) $(LIBICONV)  $(GPGME_LIBS)
+       $(INTLLIBS) $(LIBICONV)  $(GPGME_LIBS) $(GPG_ERROR_LIBS)
 
 mutt_DEPENDENCIES = @MUTT_LIB_OBJECTS@ @LIBOBJS@ $(LIBIMAPDEPS) \
        $(INTLDEPS)
@@ -47,7 +47,7 @@
        -DBINDIR=\"$(bindir)\" -DMUTTLOCALEDIR=\"$(datadir)/locale\" \
        -DHAVE_CONFIG_H=1
 
-AM_CPPFLAGS=-I. -I$(top_srcdir) $(IMAP_INCLUDES) $(GPGME_CFLAGS) -Iintl
+AM_CPPFLAGS=-I. -I$(top_srcdir) $(IMAP_INCLUDES) $(GPGME_CFLAGS) 
$(GPG_ERROR_CFLAGS) -Iintl
 
 CPPFLAGS=@CPPFLAGS@
 
diff --git a/configure.ac b/configure.ac
--- a/configure.ac
+++ b/configure.ac
@@ -137,6 +137,8 @@
       AM_PATH_GPGME(1.0.0, AC_DEFINE(CRYPT_BACKEND_GPGME, 1,
                     [Define if you use GPGME to support OpenPGP]))
       MUTT_LIB_OBJECTS="$MUTT_LIB_OBJECTS crypt-gpgme.o crypt-mod-pgp-gpgme.o 
crypt-mod-smime-gpgme.o"
+
+      AM_PATH_GPG_ERROR
    fi
 else
    AC_MSG_RESULT([no])

Attachment: pgpQXFm8tsBWW.pgp
Description: PGP signature