diff options
author | Vladimír Čunát <vcunat@gmail.com> | 2016-03-08 09:57:58 +0100 |
---|---|---|
committer | Vladimír Čunát <vcunat@gmail.com> | 2016-03-08 09:58:19 +0100 |
commit | 09af15654f0c8091f1b9e0bbb2e523cdee194442 (patch) | |
tree | e648edef1ce4c64c533f2593aa22b8015cf0e506 /pkgs/tools/networking/curl | |
parent | f306e67e15bdbe9a8358c9f81319fc4fcbadc2eb (diff) | |
parent | 0ee75214f336474e127c2e3546c0406a0c4d5fa7 (diff) |
Merge master into closure-size
The kde-5 stuff still didn't merge well. I hand-fixed what I saw, but there may be more problems.
Diffstat (limited to 'pkgs/tools/networking/curl')
-rw-r--r-- | pkgs/tools/networking/curl/7.15.nix | 8 | ||||
-rw-r--r-- | pkgs/tools/networking/curl/default.nix | 21 | ||||
-rw-r--r-- | pkgs/tools/networking/curl/disable-ca-install.patch | 14 |
3 files changed, 28 insertions, 15 deletions
diff --git a/pkgs/tools/networking/curl/7.15.nix b/pkgs/tools/networking/curl/7.15.nix index 4e533878ec189..356c9b4f32d29 100644 --- a/pkgs/tools/networking/curl/7.15.nix +++ b/pkgs/tools/networking/curl/7.15.nix @@ -20,6 +20,8 @@ stdenv.mkDerivation rec { sha256 = "061bgjm6rv0l9804vmm4jvr023l52qvmy9qq4zjv4lgqhlljvhz3"; }; + patches = [ ./disable-ca-install.patch ]; + # Zlib and OpenSSL must be propagated because `libcurl.la' contains # "-lz -lssl", which aren't necessary direct build inputs of # applications that use Curl. @@ -33,12 +35,8 @@ stdenv.mkDerivation rec { sed -e 's|/usr/bin|/no-such-path|g' -i.bak configure ''; - # make curl honor CURL_CA_BUNDLE & SSL_CERT_FILE - postConfigure = '' - echo '#define CURL_CA_BUNDLE (getenv("CURL_CA_BUNDLE") || getenv("SSL_CERT_FILE"))' >> lib/curl_config.h - ''; - configureFlags = [ + "--with-ca-bundle=/etc/ssl/certs/ca-certificates.crt" ( if sslSupport then "--with-ssl=${openssl}" else "--without-ssl" ) ( if scpSupport then "--with-libssh2=${libssh2}" else "--without-libssh2" ) ] diff --git a/pkgs/tools/networking/curl/default.nix b/pkgs/tools/networking/curl/default.nix index 8a950e3fc934e..6008afa278728 100644 --- a/pkgs/tools/networking/curl/default.nix +++ b/pkgs/tools/networking/curl/default.nix @@ -1,4 +1,5 @@ -{ stdenv, fetchurl, pkgconfig +{ stdenv, fetchurl, pkgconfig, perl +, http2Support ? true, libnghttp2 , idnSupport ? false, libidn ? null , ldapSupport ? false, openldap ? null , zlibSupport ? false, zlib ? null @@ -8,6 +9,7 @@ , c-aresSupport ? false, c-ares ? null }: +assert http2Support -> libnghttp2 != null; assert idnSupport -> libidn != null; assert ldapSupport -> openldap != null; assert zlibSupport -> zlib != null; @@ -16,20 +18,22 @@ assert scpSupport -> libssh2 != null; assert c-aresSupport -> c-ares != null; stdenv.mkDerivation rec { - name = "curl-7.45.0"; + name = "curl-7.47.1"; src = fetchurl { - url = "http://ngcobalt13.uxnr.de/mirror/curl/${name}.tar.bz2"; - sha256 = "1slq5c0v9wa8hajgimhkxhvsrd07jmih8sa3gjsl597qp5k4w5b5"; + url = "http://curl.haxx.se/download/${name}.tar.bz2"; + sha256 = "13z9gba3q2ybp50z0gdkzhwcx9m0i7qkvm278yz4pql2jfml7inx"; }; outputs = [ "dev" "out" "bin" "man" "docdev" ]; - nativeBuildInputs = [ pkgconfig ]; + nativeBuildInputs = [ pkgconfig perl ]; + # Zlib and OpenSSL must be propagated because `libcurl.la' contains # "-lz -lssl", which aren't necessary direct build inputs of # applications that use Curl. propagatedBuildInputs = with stdenv.lib; + optional http2Support libnghttp2 ++ optional idnSupport libidn ++ optional ldapSupport openldap ++ optional zlibSupport zlib ++ @@ -44,13 +48,10 @@ stdenv.mkDerivation rec { rm src/tool_hugehelp.c ''; - # make curl honor CURL_CA_BUNDLE & SSL_CERT_FILE - postConfigure = '' - echo '#define CURL_CA_BUNDLE (getenv("CURL_CA_BUNDLE") ? getenv("CURL_CA_BUNDLE") : getenv("SSL_CERT_FILE"))' >> lib/curl_config.h - ''; - configureFlags = [ + "--with-ca-bundle=/etc/ssl/certs/ca-certificates.crt" "--disable-manual" + ( if http2Support then "--with-nghttp2=${libnghttp2}" else "--without-nghttp2" ) ( if sslSupport then "--with-ssl=${openssl}" else "--without-ssl" ) ( if scpSupport then "--with-libssh2=${libssh2}" else "--without-libssh2" ) ( if ldapSupport then "--enable-ldap" else "--disable-ldap" ) diff --git a/pkgs/tools/networking/curl/disable-ca-install.patch b/pkgs/tools/networking/curl/disable-ca-install.patch new file mode 100644 index 0000000000000..aedf8ef5c3e2d --- /dev/null +++ b/pkgs/tools/networking/curl/disable-ca-install.patch @@ -0,0 +1,14 @@ +--- a/lib/Makefile.in ++++ b/lib/Makefile.in +@@ -106,10 +106,7 @@ else + endif + + install-data-hook: +- @if test -n "@CURL_CA_BUNDLE@"; then \ +- $(mkinstalldirs) `dirname $(DESTDIR)@CURL_CA_BUNDLE@`; \ +- @INSTALL_DATA@ $(srcdir)/ca-bundle.crt $(DESTDIR)@CURL_CA_BUNDLE@; \ +- fi ++ echo "install-data-hook disabled" + + # this hook is mainly for non-unix systems to build even if configure + # isn't run |