aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortobik <tobik@FreeBSD.org>2018-07-08 02:54:31 +0800
committertobik <tobik@FreeBSD.org>2018-07-08 02:54:31 +0800
commitc24203c22d0d42fa5c8bdca8d41dbec0a5712d06 (patch)
tree96923ab2e022791e84d7d617324ab2daaea942d6
parentd03da898990fe29bbd5ce033319ef0194050d659 (diff)
downloadfreebsd-ports-gnome-c24203c22d0d42fa5c8bdca8d41dbec0a5712d06.tar.gz
freebsd-ports-gnome-c24203c22d0d42fa5c8bdca8d41dbec0a5712d06.tar.zst
freebsd-ports-gnome-c24203c22d0d42fa5c8bdca8d41dbec0a5712d06.zip
dns/ddclient: Move to newer snapshot
CloudFlare will shutdown the old v1 API on June 4, 2018. ddclient on the repository already supports the current v4 API, but there is no newer release since 2015. Also includes CloudFlare IPv6 support. PR: 228600 Submitted by: maintainer
-rw-r--r--dns/ddclient/Makefile12
-rw-r--r--dns/ddclient/distinfo5
-rw-r--r--dns/ddclient/files/patch-ddclient67
3 files changed, 22 insertions, 62 deletions
diff --git a/dns/ddclient/Makefile b/dns/ddclient/Makefile
index 0bcdb45fd685..246c11254833 100644
--- a/dns/ddclient/Makefile
+++ b/dns/ddclient/Makefile
@@ -2,23 +2,25 @@
# $FreeBSD$
PORTNAME= ddclient
-PORTVERSION= 3.8.3
-PORTREVISION= 3
+DISTVERSIONPREFIX= v
+DISTVERSION= 3.8.3-104
+DISTVERSIONSUFFIX= -gec2acfb
CATEGORIES= dns
-MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}
MAINTAINER= mjl@luckie.org.nz
COMMENT= Update dynamic DNS entries
LICENSE= GPLv2
-NO_BUILD= yes
+RUN_DEPENDS= p5-Data-Validate-IP>0:net-mgmt/p5-Data-Validate-IP
USES= perl5 tar:bzip2
+USE_GITHUB= yes
USE_PERL5= run
-
USE_RC_SUBR= ${PORTNAME}
+NO_ARCH= yes
+NO_BUILD= yes
SUB_FILES= pkg-message ddclient_force
OPTIONS_DEFINE= SSL
diff --git a/dns/ddclient/distinfo b/dns/ddclient/distinfo
index 48786d678dbf..3ac0e8326b9a 100644
--- a/dns/ddclient/distinfo
+++ b/dns/ddclient/distinfo
@@ -1,2 +1,3 @@
-SHA256 (ddclient-3.8.3.tar.bz2) = d40e2f1fd3f4bff386d27bbdf4b8645199b1995d27605a886b8c71e44d819591
-SIZE (ddclient-3.8.3.tar.bz2) = 49026
+TIMESTAMP = 1530988927
+SHA256 (ddclient-ddclient-v3.8.3-104-gec2acfb_GH0.tar.gz) = 116d30dee4d6ad9b07b6a7511ab218f9c73c10f807bfdfac2af65e7fddeaeced
+SIZE (ddclient-ddclient-v3.8.3-104-gec2acfb_GH0.tar.gz) = 57944
diff --git a/dns/ddclient/files/patch-ddclient b/dns/ddclient/files/patch-ddclient
index 9424ccd4615e..45d08058741a 100644
--- a/dns/ddclient/files/patch-ddclient
+++ b/dns/ddclient/files/patch-ddclient
@@ -1,14 +1,14 @@
---- ddclient.orig 2015-05-30 21:37:38.000000000 +1200
-+++ ddclient 2017-02-08 11:00:23.812579000 +1300
-@@ -25,6 +25,7 @@
- use Getopt::Long;
+--- ddclient.orig 2018-05-23 10:25:05 UTC
++++ ddclient
+@@ -25,6 +25,7 @@ use Getopt::Long;
use Sys::Hostname;
use IO::Socket;
+ use Data::Validate::IP;
+use POSIX 'setsid';
- # my ($VERSION) = q$Revision: 184 $ =~ /(\d+)/;
-
-@@ -35,9 +36,9 @@
+ my $version = "3.8.3";
+ my $programd = $0;
+@@ -33,9 +34,9 @@ my $program = $programd;
$program =~ s/d$//;
my $now = time;
my $hostname = hostname();
@@ -21,7 +21,7 @@
my $msgs = '';
my $last_msgs = '';
-@@ -45,7 +46,7 @@
+@@ -43,7 +44,7 @@ use vars qw($file $lineno);
local $file = '';
local $lineno = '';
@@ -30,7 +30,7 @@
sub T_ANY {'any'};
sub T_STRING {'string'};
-@@ -743,6 +744,9 @@
+@@ -792,6 +793,9 @@ if (opt('foreground') || opt('force')) {
;
} elsif (opt('daemon')) {
$SIG{'CHLD'} = 'IGNORE';
@@ -40,7 +40,7 @@
my $pid = fork;
if ($pid < 0) {
print STDERR "${program}: can not fork ($!)\n";
-@@ -750,10 +754,9 @@
+@@ -799,10 +803,9 @@ if (opt('foreground') || opt('force')) {
} elsif ($pid) {
exit 0;
}
@@ -53,7 +53,7 @@
}
# write out the pid file if we're daemon'ized
-@@ -1544,17 +1547,17 @@
+@@ -1595,17 +1598,17 @@ sub pipecmd {
## execute the command.
local *FD;
if (! open(FD, $cmd)) {
@@ -75,24 +75,7 @@
} else {
$ok = 1;
-@@ -1878,13 +1881,13 @@
- ## load_json_support
- ######################################################################
- sub load_json_support {
-- my $json_loaded = eval {require JSON::Any};
-+ my $json_loaded = eval {require JSON::PP};
- unless ($json_loaded) {
- fatal(<<"EOM");
--Error loading the Perl module JSON::Any needed for cloudflare update.
-+Error loading the Perl module JSON::PP needed for cloudflare update.
- EOM
- }
-- import JSON::Any;
-+ import JSON::PP (qw/decode_json/);
- }
- ######################################################################
- ## geturl
-@@ -1957,6 +1960,7 @@
+@@ -2034,6 +2037,7 @@ sub geturl {
$sd = IO::Socket::SSL->new(
PeerAddr => $peer,
PeerPort => $port,
@@ -100,29 +83,3 @@
Proto => 'tcp',
MultiHomed => 1,
Timeout => opt('timeout'),
-@@ -4096,9 +4100,9 @@
-
- # Strip header
- $reply =~ s/^.*?\n\n//s;
-- my $response = JSON::Any->jsonToObj($reply);
-- if ($response->{result} eq 'error') {
-- failed ("%s", $response->{msg});
-+ my $response = eval {decode_json($reply)};
-+ if (!defined $response || !defined $response->{result}) {
-+ failed ("invalid json or result.");
- next;
- }
-
-@@ -4128,9 +4132,9 @@
-
- # Strip header
- $reply =~ s/^.*?\n\n//s;
-- $response = JSON::Any->jsonToObj($reply);
-- if ($response->{result} eq 'error') {
-- failed ("%s", $response->{msg});
-+ $response = eval {decode_json($reply)};
-+ if (!defined $response || !defined $response->{result}) {
-+ failed ("invalid json or result.");
- } else {
- success ("%s -- Updated Successfully to %s", $domain, $ip);
-