summary refs log tree commit diff
diff options
context:
space:
mode:
authoreburimu <eburimu@users.noreply.github.com>2018-11-20 21:41:16 -0600
committerMatthew Bauer <mjbauer95@gmail.com>2018-11-21 01:48:22 -0600
commitb13af1e87b26a3ee7d81c4b237710a93e1f243e8 (patch)
tree7e65caee87fa464118e6dfeff48cb980f1360b47
parentd492f53faf4b845f357c73031eb6faa7252922db (diff)
downloadnixpkgs-b13af1e87b26a3ee7d81c4b237710a93e1f243e8.tar
nixpkgs-b13af1e87b26a3ee7d81c4b237710a93e1f243e8.tar.gz
nixpkgs-b13af1e87b26a3ee7d81c4b237710a93e1f243e8.tar.bz2
nixpkgs-b13af1e87b26a3ee7d81c4b237710a93e1f243e8.tar.lz
nixpkgs-b13af1e87b26a3ee7d81c4b237710a93e1f243e8.tar.xz
nixpkgs-b13af1e87b26a3ee7d81c4b237710a93e1f243e8.tar.zst
nixpkgs-b13af1e87b26a3ee7d81c4b237710a93e1f243e8.zip
cyrus-sasl: 2.1.26 -> 2.1.27 w/ cross-compiling support
Fixes #50539
-rw-r--r--pkgs/development/libraries/cyrus-sasl/cyrus-sasl-ac-try-run-fix.patch12
-rw-r--r--pkgs/development/libraries/cyrus-sasl/default.nix25
2 files changed, 21 insertions, 16 deletions
diff --git a/pkgs/development/libraries/cyrus-sasl/cyrus-sasl-ac-try-run-fix.patch b/pkgs/development/libraries/cyrus-sasl/cyrus-sasl-ac-try-run-fix.patch
new file mode 100644
index 00000000000..8662e812e99
--- /dev/null
+++ b/pkgs/development/libraries/cyrus-sasl/cyrus-sasl-ac-try-run-fix.patch
@@ -0,0 +1,12 @@
+--- a/m4/sasl2.m4	2018-11-18 22:33:29.902625600 +0300
++++ b/m4/sasl2.m4	2018-11-18 22:33:59.828746176 +0300
+@@ -339,7 +339,8 @@
+ ],	
+ 	[ AC_DEFINE(HAVE_GSS_SPNEGO,,[Define if your GSSAPI implementation supports SPNEGO])
+ 	AC_MSG_RESULT(yes) ],
+-	AC_MSG_RESULT(no))
++	AC_MSG_RESULT(no),
++    AC_MSG_RESULT(no))
+   LIBS="$cmu_save_LIBS"
+ 
+ else
diff --git a/pkgs/development/libraries/cyrus-sasl/default.nix b/pkgs/development/libraries/cyrus-sasl/default.nix
index cec7e1a2d51..4344923f694 100644
--- a/pkgs/development/libraries/cyrus-sasl/default.nix
+++ b/pkgs/development/libraries/cyrus-sasl/default.nix
@@ -1,32 +1,29 @@
-{ lib, stdenv, fetchurl, openssl, openldap, kerberos, db, gettext,
-  pam, fixDarwinDylibNames, autoreconfHook, fetchpatch, enableLdap ? false }:
+{ lib, stdenv, fetchurl, openssl, openldap, kerberos, db, gettext
+, pam, fixDarwinDylibNames, autoreconfHook, fetchpatch, enableLdap ? false
+, buildPackages }:
 
 with stdenv.lib;
 stdenv.mkDerivation rec {
   name = "cyrus-sasl-${version}${optionalString (kerberos == null) "-without-kerberos"}";
-  version = "2.1.26";
+  version = "2.1.27";
 
   src = fetchurl {
     url = "ftp://ftp.cyrusimap.org/cyrus-sasl/${name}.tar.gz";
-    sha256 = "1hvvbcsg21nlncbgs0cgn3iwlnb3vannzwsp6rwvnn9ba4v53g4g";
+    sha256 = "1m85zcpgfdhm43cavpdkhb1s2zq1b31472hq1w1gs3xh94anp1i6";
   };
 
   outputs = [ "bin" "dev" "out" "man" "devdoc" ];
 
+  depsBuildBuild = [ buildPackages.stdenv.cc ];
+  nativeBuildInputs = [ autoreconfHook fixDarwinDylibNames ];
   buildInputs =
     [ openssl db gettext kerberos ]
     ++ lib.optional enableLdap openldap
-    ++ lib.optional stdenv.isFreeBSD autoreconfHook
-    ++ lib.optional stdenv.isLinux pam
-    ++ lib.optional stdenv.isDarwin fixDarwinDylibNames;
+    ++ lib.optional stdenv.isLinux pam;
 
   patches = [
     ./missing-size_t.patch # https://bugzilla.redhat.com/show_bug.cgi?id=906519
-    (fetchpatch {
-      name = "CVE-2013-4122.patch";
-      url = "http://sourceforge.net/projects/miscellaneouspa/files/glibc217/cyrus-sasl-2.1.26-glibc217-crypt.diff";
-      sha256 = "05l7dh1w9d5fvzg0pjwzqh0fy4ah8y5cv6v67s4ssbq8xwd4pkf2";
-    })
+    ./cyrus-sasl-ac-try-run-fix.patch
   ] ++ lib.optional stdenv.isFreeBSD (
       fetchurl {
         url = "http://www.linuxfromscratch.org/patches/blfs/svn/cyrus-sasl-2.1.26-fixes-3.patch";
@@ -42,10 +39,6 @@ stdenv.mkDerivation rec {
     "--enable-shared"
   ] ++ lib.optional enableLdap "--with-ldap=${openldap.dev}";
 
-  # Avoid triggering regenerating using broken autoconf/libtool bits.
-  # (many distributions carry patches to remove/replace, but this works for now)
-  dontUpdateAutotoolsGnuConfigScripts = if stdenv.hostPlatform.isMusl then true else null;
-
   installFlags = lib.optional stdenv.isDarwin [ "framedir=$(out)/Library/Frameworks/SASL2.framework" ];
 
   postInstall = ''