Для меня сработало следующее (perl 5, версия 28, subversion 0 (v5.28.0), созданная для darwin-thread-multi-2level, XCode 9.4.1):
wget https://www.cpan.org/modules/by-module/WWW/WWW-Curl-4.17.tar.gz
tar zxvf WWW-Curl-4.17.tar.gz
cd WWW-Curl-4.17
cpan Module::Install
git apply cpp.patch
git apply stretch.patch
perl Makefile.PL
make
make install
cpp.patch (см .: этот SO-ответ ):
diff --git a/Makefile.PL b/Makefile.PL
index f9170bb..124e5fd 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -100,7 +100,7 @@ if (!defined($curl_h)) {
print "Found curl.h in $curl_h\n";
my @syms;
my $has_cpp = 0;
- open(H_IN, "-|", "cpp", $curl_h) and $has_cpp++;
+ open(H_IN, "-|", "cc -E", $curl_h) and $has_cpp++;
unless ($has_cpp) {
warn "No working cpp ($!). Parsing curl.h in Perl";
open(H_IN, "<", $curl_h) or die("Can't open curl.h at path $curl_h, because: ".$!);
stretch.patch (см. этот билет ):
From 292c05a8aa9c18bd27d0aaff0b4ee601d9b87b92 Mon Sep 17 00:00:00 2001
From: Slaven Rezic <cpansand@cvrsnica-freebsd-101.herceg.de>
Date: Sun, 16 Apr 2017 22:17:00 +0200
Subject: [PATCH] compilation fixes for curl 7.50.2 and newer (RT #117793)
---
Makefile.PL | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Makefile.PL b/Makefile.PL
index f9170bb..bb852e4 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -127,7 +127,7 @@ if (!defined($curl_h)) {
close H;
for my $e (sort @syms) {
- if($e =~ /(OBSOLETE|^CURL_EXTERN|_LAST\z|_LASTENTRY\z)/) {
+ if($e =~ /(OBSOLETE|^CURL_EXTERN|^CURL_STRICTER\z|^CURL_DID_MEMORY_FUNC_TYPEDEFS\z|_LAST\z|_LASTENTRY\z)/) {
next;
}
my ($group) = $e =~ m/^([^_]+_)/;
--
2.1.2