[36259] trunk/dports/net

ryandesign at macports.org ryandesign at macports.org
Thu Apr 24 14:52:34 PDT 2008


Revision: 36259
          http://trac.macosforge.org/projects/macports/changeset/36259
Author:   ryandesign at macports.org
Date:     2008-04-24 14:52:34 -0700 (Thu, 24 Apr 2008)

Log Message:
-----------
curl: make use of an external ca-bundle.crt file since curl doesn't include it anymore as of 7.18.0
curl-ca-bundle: new port which builds the ca-bundle.crt using a script in the curl source and the certdata.txt from the mozilla project
Closes #15048

Modified Paths:
--------------
    trunk/dports/net/curl/Portfile

Added Paths:
-----------
    trunk/dports/net/curl-ca-bundle/
    trunk/dports/net/curl-ca-bundle/Portfile
    trunk/dports/net/curl-ca-bundle/files/
    trunk/dports/net/curl-ca-bundle/files/patch-no-autodownload.diff

Modified: trunk/dports/net/curl/Portfile
===================================================================
--- trunk/dports/net/curl/Portfile	2008-04-24 21:40:28 UTC (rev 36258)
+++ trunk/dports/net/curl/Portfile	2008-04-24 21:52:34 UTC (rev 36259)
@@ -3,7 +3,9 @@
 PortSystem              1.0
 
 name                    curl
+# keep the version in sync with the curl-ca-bundle port
 version                 7.18.1
+revision                1
 categories              net www
 maintainers             ryandesign
 homepage                http://curl.haxx.se/
@@ -18,6 +20,7 @@
     the supported protocols. The command is designed to work without \
     user interaction or any kind of interactivity.
 
+# keep the master_sites in sync with the curl-ca-bundle port
 master_sites \
     http://curl.haxx.se/download/ \
     ftp://ftp.sunet.se/pub/www/utilities/curl/ \
@@ -88,7 +91,9 @@
 }
 
 variant ssl {
-    depends_lib-append      port:openssl
+    depends_lib-append      port:openssl \
+                            port:curl-ca-bundle
+    configure.args-append   --with-ca-bundle=${prefix}/share/curl/curl-ca-bundle.crt
     configure.args-delete   --without-ssl
 }
 

Added: trunk/dports/net/curl-ca-bundle/Portfile
===================================================================
--- trunk/dports/net/curl-ca-bundle/Portfile	                        (rev 0)
+++ trunk/dports/net/curl-ca-bundle/Portfile	2008-04-24 21:52:34 UTC (rev 36259)
@@ -0,0 +1,80 @@
+# $Id: Portfile 35609 2008-03-31 03:35:29Z ryandesign at macports.org $
+
+PortSystem              1.0
+
+name                    curl-ca-bundle
+# keep the version in sync with the curl port
+version                 7.18.1
+set curl_name           curl
+categories              net
+maintainers             ryandesign
+homepage                http://curl.haxx.se/
+platforms               darwin freebsd
+use_bzip2               yes
+use_configure           no
+universal_variant       no
+distname                ${curl_name}-${version}
+dist_subdir             ${curl_name}
+set curl_source         ${distname}${extract.suffix}
+set certdata_file       certdata.txt
+set certdata_version    1.47
+set certdata_distfile   certdata-${certdata_version}.txt
+set certdata_path       security/nss/lib/ckfw/builtins/${certdata_file}
+build.target            ca-bundle
+extract.only            ${curl_source}
+
+description \
+    CA certificate bundle for curl
+
+long_description \
+    Installs a bundle of certification authority certificates (CA certs) \
+    which curl (when linked with OpenSSL) uses to verify the authenticity \
+    of secure web and FTP servers.
+
+# keep the master_sites in sync with the curl port
+master_sites \
+    http://curl.haxx.se/download/ \
+    ftp://ftp.sunet.se/pub/www/utilities/curl/ \
+    http://curl.sourceforge.net/download/ \
+    http://cool.haxx.se/curl/ \
+    ftp://gd.tuwien.ac.at/utils/archivers/curl/ \
+    http://gd.tuwien.ac.at/utils/archivers/curl/ \
+    http://www.execve.net/curl/ \
+    sourceforge \
+    http://lxr.mozilla.org/seamonkey/source/${certdata_path}?raw=1:certdata
+
+distfiles \
+    ${curl_source} \
+    ${certdata_distfile}:certdata
+
+checksums \
+    ${curl_source} \
+        md5 805834fc1136ff7600d2179bc0386c5a \
+        sha1 685b9388ee9e646158a83cd435f7be664816ad78 \
+        rmd160 f7dac868b2a449aa92a3466b24fe2bb3309ff1e0 \
+    ${certdata_distfile} \
+        md5 01d516427e80ccced20260ce63c46588 \
+        sha1 47f6fbc0d603beed9fa76483bd5b564fdd47d438 \
+        rmd160 551692b8fc12f406e8c1ce8bacd24cfc56df3130
+
+depends_build \
+    path:${prefix}/bin/perl:perl5.8 \
+    port:p5-mime-base64
+
+patchfiles \
+    patch-no-autodownload.diff
+
+post-extract {
+    xinstall ${distpath}/${certdata_distfile} ${worksrcpath}/${certdata_file}
+}
+
+destroot {
+    set ca_bundle_dir ${destroot}${prefix}/share/curl
+    xinstall -d ${ca_bundle_dir}
+    xinstall ${worksrcpath}/lib/ca-bundle.crt ${ca_bundle_dir}/curl-ca-bundle.crt
+}
+
+livecheck.check         regex
+livecheck.url           http://bonsai.mozilla.org/cvsquery.cgi?file=mozilla/${certdata_path}&date=month
+livecheck.version       ${certdata_version}
+livecheck.regex         '${certdata_file}','(\[0-9.\]+)'

Added: trunk/dports/net/curl-ca-bundle/files/patch-no-autodownload.diff
===================================================================
--- trunk/dports/net/curl-ca-bundle/files/patch-no-autodownload.diff	                        (rev 0)
+++ trunk/dports/net/curl-ca-bundle/files/patch-no-autodownload.diff	2008-04-24 21:52:34 UTC (rev 36259)
@@ -0,0 +1,20 @@
+--- Makefile	2008-03-30 04:10:14.000000000 -0500
++++ Makefile	2008-04-20 01:40:17.000000000 -0500
+@@ -263,6 +263,6 @@
+ 
+ ca-bundle: lib/mk-ca-bundle.pl
+ 	@echo "generate a fresh ca-bundle.crt"
+-	@perl $< -b -l -u lib/ca-bundle.crt
++	@perl $< -n lib/ca-bundle.crt
+ 
+ 
+--- lib/mk-ca-bundle.pl	2008-02-15 03:28:40.000000000 -0600
++++ lib/mk-ca-bundle.pl	2008-04-20 01:40:17.000000000 -0500
+@@ -33,7 +33,6 @@
+ #
+ use Getopt::Std;
+ use MIME::Base64;
+-use LWP::UserAgent;
+ use strict;
+ use vars qw($opt_b $opt_h $opt_i $opt_l $opt_n $opt_q $opt_t $opt_u $opt_v);  
+ 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20080424/82dd9cf0/attachment.html


More information about the macports-changes mailing list