Merge pull request #9915 from khumba/claws-mime-fix

claws-mail: fix attachment MIME detection, enable parallel build
This commit is contained in:
lethalman 2015-09-18 14:15:04 +02:00
commit 60d1c0cfd1
2 changed files with 21 additions and 1 deletions

View File

@ -1,7 +1,7 @@
{ fetchurl, stdenv
, curl, dbus, dbus_glib, enchant, gtk, gnutls, gnupg, gpgme, libarchive
, libcanberra, libetpan, libnotify, libsoup, libxml2, networkmanager, openldap
, perl, pkgconfig, poppler, python, webkitgtk2
, perl, pkgconfig, poppler, python, shared_mime_info, webkitgtk2
# Build options
# TODO: A flag to build the manual.
@ -47,6 +47,8 @@ stdenv.mkDerivation {
sha256 = "0w13xzri9d3165qsxf1dig1f0gxn3ib4lysfc9pgi4zpyzd0zgrw";
};
patches = [ ./mime.patch ];
buildInputs =
[ curl dbus dbus_glib gtk gnutls libetpan perl pkgconfig python ]
++ optional enableSpellcheck enchant
@ -80,8 +82,12 @@ stdenv.mkDerivation {
++ optional (!enablePluginVcalendar) "--disable-vcalendar-plugin"
++ optional (!enableSpellcheck) "--disable-enchant";
enableParallelBuilding = true;
postInstall = ''
mkdir -p $out/share/applications
cp claws-mail.desktop $out/share/applications
ln -sT ${shared_mime_info}/share/mime $out/share/mime
'';
}

View File

@ -0,0 +1,14 @@
--- a/src/procmime.c 2015-09-18 04:03:11.767654094 -0700
+++ b/src/procmime.c 2015-09-18 04:08:38.834503034 -0700
@@ -1196,11 +1196,7 @@
if (mime_type_list)
return mime_type_list;
-#if defined(__NetBSD__) || defined(__OpenBSD__) || defined(__FreeBSD__)
if ((fp = procmime_fopen(DATAROOTDIR "/mime/globs", "rb")) == NULL)
-#else
- if ((fp = procmime_fopen("/usr/share/mime/globs", "rb")) == NULL)
-#endif
{
fp_is_glob_file = FALSE;
if ((fp = procmime_fopen("/etc/mime.types", "rb")) == NULL) {