<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[154109] trunk/dports/net/net-snmp</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="https://trac.macports.org/changeset/154109">154109</a></dd>
<dt>Author</dt> <dd>ryandesign@macports.org</dd>
<dt>Date</dt> <dd>2016-10-19 21:31:17 -0700 (Wed, 19 Oct 2016)</dd>
</dl>

<h3>Log Message</h3>
<pre>net-snmp: Fix build failure with perl5.24

Resolves #52214</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkdportsnetnetsnmpPortfile">trunk/dports/net/net-snmp/Portfile</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkdportsnetnetsnmpfiles0001CHANGESBUG2712FixPerlmodulecompilationpatch">trunk/dports/net/net-snmp/files/0001-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch</a></li>
<li><a href="#trunkdportsnetnetsnmpfilesPR52214patch">trunk/dports/net/net-snmp/files/PR-52214.patch</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkdportsnetnetsnmpPortfile"></a>
<div class="modfile"><h4>Modified: trunk/dports/net/net-snmp/Portfile (154108 => 154109)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/dports/net/net-snmp/Portfile       2016-10-20 03:40:29 UTC (rev 154108)
+++ trunk/dports/net/net-snmp/Portfile  2016-10-20 04:31:17 UTC (rev 154109)
</span><span class="lines">@@ -54,6 +54,8 @@
</span><span class="cx"> patchfiles-append       patch-include-net-snmp-system-darwin17.h.diff
</span><span class="cx"> patchfiles-append       patch-include-net-snmp-system-darwin18.h.diff
</span><span class="cx"> patchfiles-append       patch-Makefile.in.diff
</span><ins>+patchfiles-append       PR-52214.patch
+patchfiles-append       0001-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch
</ins><span class="cx"> 
</span><span class="cx"> configure.env-append    PERLPROG=${perl5.bin}
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkdportsnetnetsnmpfiles0001CHANGESBUG2712FixPerlmodulecompilationpatch"></a>
<div class="addfile"><h4>Added: trunk/dports/net/net-snmp/files/0001-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch (0 => 154109)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/dports/net/net-snmp/files/0001-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch                          (rev 0)
+++ trunk/dports/net/net-snmp/files/0001-CHANGES-BUG-2712-Fix-Perl-module-compilation.patch     2016-10-20 04:31:17 UTC (rev 154109)
</span><span class="lines">@@ -0,0 +1,182 @@
</span><ins>+From 4e793461e96a2b4fd81142ab312d074d5c8841fa Mon Sep 17 00:00:00 2001
+From: Bart Van Assche <bvanassche@acm.org>
+Date: Sat, 23 Jul 2016 18:41:10 -0700
+Subject: [PATCH] CHANGES: BUG: 2712: Fix Perl module compilation
+
+Avoid that building the Net-SNMP Perl modules fails as follows:
+
+ERROR from evaluation of /sources/net-snmp-5.7.3/perl/ASN/Makefile.PL: Bizarre \ copy of HASH in list assignment at /usr/lib/perl5/site_perl/5.24.0/Carp.pm line\ 229.
+
+See also https://sourceforge.net/p/net-snmp/bugs/2712/.
+---
+ perl/ASN/Makefile.PL                 | 4 +---
+ perl/Makefile.PL                     | 4 +---
+ perl/OID/Makefile.PL                 | 5 +----
+ perl/SNMP/Makefile.PL                | 5 +----
+ perl/TrapReceiver/Makefile.PL        | 5 +----
+ perl/agent/Makefile.PL               | 5 +----
+ perl/agent/Support/Makefile.PL       | 5 +----
+ perl/agent/default_store/Makefile.PL | 5 +----
+ perl/default_store/Makefile.PL       | 6 +-----
+ 9 files changed, 9 insertions(+), 35 deletions(-)
+
+diff --git perl/ASN/Makefile.PL perl/ASN/Makefile.PL
+index f895a41..0e52b3a 100644
+--- perl/ASN/Makefile.PL
++++ perl/ASN/Makefile.PL
+@@ -7,9 +7,7 @@ my $lib_version;
+ # See lib/ExtUtils/MakeMaker.pm for details of how to influence
+ # the contents of the Makefile that is written.

+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);
++WriteMakefile(InitMakeParams());

+ Check_Version();

+diff --git perl/Makefile.PL perl/Makefile.PL
+index f70f991..ac36c15 100644
+--- perl/Makefile.PL
++++ perl/Makefile.PL
+@@ -3,9 +3,7 @@ use Config;
+ use Getopt::Long;
+ require 5;

+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);
++WriteMakefile(InitMakeParams());

+ sub InitMakeParams {
+     $nsconfig="net-snmp-config"; # in path by default
+diff --git perl/OID/Makefile.PL perl/OID/Makefile.PL
+index 5d94338..676c439 100644
+--- perl/OID/Makefile.PL
++++ perl/OID/Makefile.PL
+@@ -6,11 +6,8 @@ require 5;
+ use Config;
+ use Getopt::Long;
+ my $lib_version;
+-my %MakeParams = ();

+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);
++WriteMakefile(InitMakeParams());

+ Check_Version();

+diff --git perl/SNMP/Makefile.PL perl/SNMP/Makefile.PL
+index 928cb67..d7b5a2a 100644
+--- perl/SNMP/Makefile.PL
++++ perl/SNMP/Makefile.PL
+@@ -3,15 +3,12 @@ require 5;
+ use Config;
+ use Getopt::Long;
+ my $lib_version;
+-my %MakeParams = ();
+ my $opts;

+ # See lib/ExtUtils/MakeMaker.pm for details of how to influence
+ # the contents of the Makefile that is written.

+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);
++WriteMakefile(InitMakeParams());

+ Check_Version();

+diff --git perl/TrapReceiver/Makefile.PL perl/TrapReceiver/Makefile.PL
+index 5c9463a..0af6aaf 100644
+--- perl/TrapReceiver/Makefile.PL
++++ perl/TrapReceiver/Makefile.PL
+@@ -3,11 +3,8 @@ require 5;
+ use Config;
+ use Getopt::Long;
+ my $lib_version;
+-my %MakeParams = ();

+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);
++WriteMakefile(InitMakeParams());

+ Check_Version();

+diff --git perl/agent/Makefile.PL perl/agent/Makefile.PL
+index b4b358a..fe105ea 100644
+--- perl/agent/Makefile.PL
++++ perl/agent/Makefile.PL
+@@ -3,11 +3,8 @@ require 5;
+ use Config;
+ use Getopt::Long;
+ my $lib_version;
+-my %MakeParams = ();

+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);
++WriteMakefile(InitMakeParams());

+ Check_Version();

+diff --git perl/agent/Support/Makefile.PL perl/agent/Support/Makefile.PL
+index 3a4f200..0dcb3f6 100644
+--- perl/agent/Support/Makefile.PL
++++ perl/agent/Support/Makefile.PL
+@@ -3,14 +3,11 @@ require 5;
+ use Config;
+ use Getopt::Long;
+ my $lib_version;
+-my %MakeParams = ();

+ # See lib/ExtUtils/MakeMaker.pm for details of how to influence
+ # the contents of the Makefile that is written.

+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);
++WriteMakefile(InitMakeParams());

+ Check_Version();

+diff --git perl/agent/default_store/Makefile.PL perl/agent/default_store/Makefile.PL
+index 67d5ff0..5c6a5d6 100644
+--- perl/agent/default_store/Makefile.PL
++++ perl/agent/default_store/Makefile.PL
+@@ -3,11 +3,8 @@ require 5;
+ use Config;
+ use Getopt::Long;
+ my $lib_version;
+-my %MakeParams = ();

+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);
++WriteMakefile(InitMakeParams());

+ Check_Version();

+diff --git perl/default_store/Makefile.PL perl/default_store/Makefile.PL
+index 54996ab..221d4ed 100644
+--- perl/default_store/Makefile.PL
++++ perl/default_store/Makefile.PL
+@@ -3,12 +3,8 @@ require 5;
+ use Config;
+ use Getopt::Long;
+ my $lib_version;
+-my %MakeParams = ();
+-
+-%MakeParams = InitMakeParams();
+-
+-WriteMakefile(%MakeParams);

++WriteMakefile(InitMakeParams());

+ sub InitMakeParams {
+     my $opts;
+-- 
+2.10.0
+
</ins></span></pre></div>
<a id="trunkdportsnetnetsnmpfilesPR52214patch"></a>
<div class="addfile"><h4>Added: trunk/dports/net/net-snmp/files/PR-52214.patch (0 => 154109)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/dports/net/net-snmp/files/PR-52214.patch                           (rev 0)
+++ trunk/dports/net/net-snmp/files/PR-52214.patch      2016-10-20 04:31:17 UTC (rev 154109)
</span><span class="lines">@@ -0,0 +1,139 @@
</span><ins>+Reported at: https://trac.macports.org/ticket/52214
+
+Fix from FreeBSD: https://svnweb.freebsd.org/ports/head/net-mgmt/net-snmp/files/patch-perl5.23?revision=396053&view=co
+
+--- agent/snmp_perl.c.orig     2015-08-11 13:07:06 UTC
++++ agent/snmp_perl.c
+@@ -5,6 +5,10 @@
+ #include <EXTERN.h>
+ #include "perl.h"

++#ifdef U64TYPE
++#define U64 U64pairU32
++#endif
++
+ #include <net-snmp/net-snmp-config.h>
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
+--- perl/OID/OID.xs.orig       2015-08-11 13:07:28 UTC
++++ perl/OID/OID.xs
+@@ -7,6 +7,10 @@
+ #include "perl.h"
+ #include "XSUB.h"

++#ifdef U64TYPE
++#define U64 U64pairU32
++#endif
++
+ #include <net-snmp/net-snmp-config.h>
+ #include <net-snmp/net-snmp-includes.h>

+--- perl/SNMP/SNMP.xs.orig     2015-08-11 13:07:54 UTC
++++ perl/SNMP/SNMP.xs
+@@ -16,6 +16,10 @@
+ #include "perl.h"
+ #include "XSUB.h"

++#ifdef U64TYPE
++#define U64 U64pairU32
++#endif
++
+ #include <net-snmp/net-snmp-config.h>
+ #include <net-snmp/net-snmp-includes.h>
+ #include <sys/types.h>
+--- perl/TrapReceiver/TrapReceiver.xs.orig     2015-08-11 13:08:02 UTC
++++ perl/TrapReceiver/TrapReceiver.xs
+@@ -9,6 +9,10 @@

+ #include "ppport.h"

++#ifdef U64TYPE
++#define U64 U64pairU32
++#endif
++
+ #include <net-snmp/net-snmp-config.h>
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
+--- perl/agent/agent.xs.orig   2015-08-11 13:07:48 UTC
++++ perl/agent/agent.xs
+@@ -9,6 +9,10 @@
+ #include <netdb.h>
+ #include <sys/socket.h>

++#ifdef U64TYPE
++#define U64 U64pairU32
++#endif
++
+ #include <net-snmp/net-snmp-config.h>
+ #include <net-snmp/net-snmp-includes.h>
+ #include <net-snmp/agent/net-snmp-agent-includes.h>
+--- perl/ASN/Makefile.PL.orig  2014-12-08 20:23:22 UTC
++++ perl/ASN/Makefile.PL
+@@ -1,3 +1,4 @@
++package ASN;
+ use ExtUtils::MakeMaker;
+ require 5;
+ use Config;
+--- perl/AnyData_SNMP/Makefile.PL.orig 2015-09-03 22:27:45 UTC
++++ perl/AnyData_SNMP/Makefile.PL
+@@ -1,3 +1,4 @@
++package AnyData_SNMP;
+ use ExtUtils::MakeMaker;
+ # See lib/ExtUtils/MakeMaker.pm for details of how to influence
+ # the contents of the Makefile that is written.
+--- perl/OID/Makefile.PL.orig  2014-12-08 20:23:22 UTC
++++ perl/OID/Makefile.PL
+@@ -1,3 +1,4 @@
++package OID;
+ # See lib/ExtUtils/MakeMaker.pm for details of how to influence
+ # the contents of the Makefile that is written.

+--- perl/SNMP/Makefile.PL.orig 2014-12-08 20:23:22 UTC
++++ perl/SNMP/Makefile.PL
+@@ -1,3 +1,4 @@
++package SNMP;
+ use ExtUtils::MakeMaker;
+ require 5;
+ use Config;
+--- perl/TrapReceiver/Makefile.PL.orig 2014-12-08 20:23:22 UTC
++++ perl/TrapReceiver/Makefile.PL
+@@ -1,3 +1,4 @@
++package TrapReceiver;
+ use ExtUtils::MakeMaker;
+ require 5;
+ use Config;
+--- perl/agent/Makefile.PL.orig        2014-12-08 20:23:22 UTC
++++ perl/agent/Makefile.PL
+@@ -1,3 +1,4 @@
++package agent;
+ use ExtUtils::MakeMaker;
+ require 5;
+ use Config;
+--- perl/agent/Support/Makefile.PL.orig        2014-12-08 20:23:22 UTC
++++ perl/agent/Support/Makefile.PL
+@@ -1,3 +1,4 @@
++package agent_Support;
+ use ExtUtils::MakeMaker;
+ require 5;
+ use Config;
+--- perl/agent/default_store/Makefile.PL.orig  2014-12-08 20:23:22 UTC
++++ perl/agent/default_store/Makefile.PL
+@@ -1,3 +1,4 @@
++package agent_default_store;
+ use ExtUtils::MakeMaker;
+ require 5;
+ use Config;
+--- perl/default_store/Makefile.PL.orig        2014-12-08 20:23:22 UTC
++++ perl/default_store/Makefile.PL
+@@ -1,3 +1,4 @@
++package default_store;
+ use ExtUtils::MakeMaker;
+ require 5;
+ use Config;
+--- perl/manager/Makefile.PL.orig      2014-12-08 20:23:22 UTC
++++ perl/manager/Makefile.PL
+@@ -1,3 +1,4 @@
++package manager;
+ use ExtUtils::MakeMaker;
+ # See lib/ExtUtils/MakeMaker.pm for details of how to influence
+ # the contents of the Makefile that is written.
</ins></span></pre>
</div>
</div>

</body>
</html>