From 27a9ef8709bf0fe257a0e9acd13bb6b71d1244be Mon Sep 17 00:00:00 2001 From: Rahul Gopinath Date: Sun, 3 Jul 2016 19:05:46 -0700 Subject: [PATCH] mailutils: fix build break See #14606 for the breakage. It is fixed by using default guile 2.0 Also addes support for fribidi, sasl, and gssapi --- pkgs/tools/networking/mailutils/default.nix | 19 ++++++++++--------- .../networking/mailutils/scm_c_string.patch | 15 +++++++++++++++ pkgs/top-level/all-packages.nix | 2 +- 3 files changed, 26 insertions(+), 10 deletions(-) create mode 100644 pkgs/tools/networking/mailutils/scm_c_string.patch diff --git a/pkgs/tools/networking/mailutils/default.nix b/pkgs/tools/networking/mailutils/default.nix index cbca408f0842..4b1633947b09 100644 --- a/pkgs/tools/networking/mailutils/default.nix +++ b/pkgs/tools/networking/mailutils/default.nix @@ -1,7 +1,6 @@ { fetchurl, stdenv, gettext, gdbm, libtool, pam, readline -, ncurses, gnutls, mysql, guile, texinfo, gnum4, dejagnu, sendmailPath ? "/var/setuid-wrappers/sendmail" }: - -/* TODO: Add GNU SASL, GNU GSSAPI, and FreeBidi. */ +, ncurses, gnutls, sasl, fribidi, gss , mysql, guile, texinfo, + gnum4, dejagnu, nettools }: stdenv.mkDerivation rec { name = "mailutils-2.2"; @@ -11,17 +10,19 @@ stdenv.mkDerivation rec { sha256 = "0szbqa12zqzldqyw97lxqax3ja2adis83i7brdfsxmrfw68iaf65"; }; - patches = [ ./path-to-cat.patch ./no-gets.patch ]; + patches = [ ./path-to-cat.patch ./no-gets.patch ./scm_c_string.patch ]; - configureFlags = "--with-path-sendmail=${sendmailPath}"; + configureFlags = [ + "--with-gsasl" + "--with-gssapi=${gss}" + ]; buildInputs = [ gettext gdbm libtool pam readline ncurses - gnutls mysql.lib guile texinfo gnum4 ] + gnutls mysql.lib guile texinfo gnum4 sasl fribidi gss nettools ] ++ stdenv.lib.optional doCheck dejagnu; - # Tests fail since gcc 4.8 - doCheck = false; + doCheck = true; meta = with stdenv.lib; { description = "Rich and powerful protocol-independent mail framework"; @@ -51,7 +52,7 @@ stdenv.mkDerivation rec { gpl3Plus /* tools */ ]; - maintainers = [ ]; + maintainers = with maintainers; [ vrthra ]; homepage = http://www.gnu.org/software/mailutils/; diff --git a/pkgs/tools/networking/mailutils/scm_c_string.patch b/pkgs/tools/networking/mailutils/scm_c_string.patch new file mode 100644 index 000000000000..367dd2d64066 --- /dev/null +++ b/pkgs/tools/networking/mailutils/scm_c_string.patch @@ -0,0 +1,15 @@ +See https://lists.gnu.org/archive/html/bug-mailutils/2010-10/msg00005.html + +diff -u mailutils-2.2/libmu_scm/mu_message.c mailutils-2.2.new/libmu_scm/mu_message.c +--- mailutils-2.2/libmu_scm/mu_message.c 2010-04-18 10:29:07.000000000 -0700 ++++ mailutils-2.2.new/libmu_scm/mu_message.c 2016-07-03 21:18:53.746185547 -0700 +@@ -510,8 +510,8 @@ + { + SCM car = SCM_CAR (lst); + if (scm_is_string (car) + && mu_c_strncasecmp (scm_i_string_chars (car), name, +- scm_i_string_length (car)) == 0) ++ scm_c_string_length (car)) == 0) + return 1; + } + return 0; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index bd53a7de54cd..7bf83f4054f2 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -2420,7 +2420,7 @@ in mailpile = callPackage ../applications/networking/mailreaders/mailpile { }; mailutils = callPackage ../tools/networking/mailutils { - guile = guile_1_8; + sasl = gsasl; }; email = callPackage ../tools/networking/email { };