Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 1 | From e57fc809ad6ae522670f3dc157aadde20d968ca7 Mon Sep 17 00:00:00 2001 |
| 2 | From: Bart Van Assche <bvanassche@acm.org> |
| 3 | Date: Wed, 24 May 2017 17:05:03 +0800 |
| 4 | Subject: [PATCH 3/4] CHANGES: BUG: 2712: Fix Perl module compilation |
| 5 | |
| 6 | Avoid that building the Net-SNMP Perl modules fails as follows: |
| 7 | |
| 8 | 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. |
| 9 | |
| 10 | See also https://sourceforge.net/p/net-snmp/bugs/2712/. |
| 11 | |
| 12 | This patch comes from git://git.code.sf.net/p/net-snmp/code, |
| 13 | the commit is 4e793461e96a2b4fd81142ab312d074d5c8841fa. |
| 14 | |
| 15 | Signed-off-by: Wenlin Kang <wenlin.kang@windriver.com> |
| 16 | --- |
| 17 | perl/ASN/Makefile.PL | 4 +--- |
| 18 | perl/Makefile.PL | 4 +--- |
| 19 | perl/OID/Makefile.PL | 5 +---- |
| 20 | perl/SNMP/Makefile.PL | 5 +---- |
| 21 | perl/TrapReceiver/Makefile.PL | 5 +---- |
| 22 | perl/agent/Makefile.PL | 5 +---- |
| 23 | perl/agent/Support/Makefile.PL | 5 +---- |
| 24 | perl/agent/default_store/Makefile.PL | 5 +---- |
| 25 | perl/default_store/Makefile.PL | 5 +---- |
| 26 | 9 files changed, 9 insertions(+), 34 deletions(-) |
| 27 | |
| 28 | diff --git a/perl/ASN/Makefile.PL b/perl/ASN/Makefile.PL |
| 29 | index 4576781..c33d8ba 100644 |
| 30 | --- a/perl/ASN/Makefile.PL |
| 31 | +++ b/perl/ASN/Makefile.PL |
| 32 | @@ -7,9 +7,7 @@ my $lib_version; |
| 33 | # See lib/ExtUtils/MakeMaker.pm for details of how to influence |
| 34 | # the contents of the Makefile that is written. |
| 35 | |
| 36 | -%MakeParams = InitMakeParams(); |
| 37 | - |
| 38 | -WriteMakefile(%MakeParams); |
| 39 | +WriteMakefile(InitMakeParams()); |
| 40 | |
| 41 | Check_Version(); |
| 42 | |
| 43 | diff --git a/perl/Makefile.PL b/perl/Makefile.PL |
| 44 | index 31fdc40..48aba2a 100644 |
| 45 | --- a/perl/Makefile.PL |
| 46 | +++ b/perl/Makefile.PL |
| 47 | @@ -3,9 +3,7 @@ use Config; |
| 48 | use Getopt::Long; |
| 49 | require 5; |
| 50 | |
| 51 | -%MakeParams = InitMakeParams(); |
| 52 | - |
| 53 | -WriteMakefile(%MakeParams); |
| 54 | +WriteMakefile(InitMakeParams()); |
| 55 | |
| 56 | sub InitMakeParams { |
| 57 | $nsconfig="net-snmp-config"; # in path by default |
| 58 | diff --git a/perl/OID/Makefile.PL b/perl/OID/Makefile.PL |
| 59 | index 6bb1616..2589985 100644 |
| 60 | --- a/perl/OID/Makefile.PL |
| 61 | +++ b/perl/OID/Makefile.PL |
| 62 | @@ -6,11 +6,8 @@ require 5; |
| 63 | use Config; |
| 64 | use Getopt::Long; |
| 65 | my $lib_version; |
| 66 | -my %MakeParams = (); |
| 67 | |
| 68 | -%MakeParams = InitMakeParams(); |
| 69 | - |
| 70 | -WriteMakefile(%MakeParams); |
| 71 | +WriteMakefile(InitMakeParams()); |
| 72 | |
| 73 | Check_Version(); |
| 74 | |
| 75 | diff --git a/perl/SNMP/Makefile.PL b/perl/SNMP/Makefile.PL |
| 76 | index e617cb7..8aab9a9 100644 |
| 77 | --- a/perl/SNMP/Makefile.PL |
| 78 | +++ b/perl/SNMP/Makefile.PL |
| 79 | @@ -3,15 +3,12 @@ require 5; |
| 80 | use Config; |
| 81 | use Getopt::Long; |
| 82 | my $lib_version; |
| 83 | -my %MakeParams = (); |
| 84 | my $opts; |
| 85 | |
| 86 | # See lib/ExtUtils/MakeMaker.pm for details of how to influence |
| 87 | # the contents of the Makefile that is written. |
| 88 | |
| 89 | -%MakeParams = InitMakeParams(); |
| 90 | - |
| 91 | -WriteMakefile(%MakeParams); |
| 92 | +WriteMakefile(InitMakeParams()); |
| 93 | |
| 94 | Check_Version(); |
| 95 | |
| 96 | diff --git a/perl/TrapReceiver/Makefile.PL b/perl/TrapReceiver/Makefile.PL |
| 97 | index 874ee21..7e9e58e 100644 |
| 98 | --- a/perl/TrapReceiver/Makefile.PL |
| 99 | +++ b/perl/TrapReceiver/Makefile.PL |
| 100 | @@ -3,11 +3,8 @@ require 5; |
| 101 | use Config; |
| 102 | use Getopt::Long; |
| 103 | my $lib_version; |
| 104 | -my %MakeParams = (); |
| 105 | |
| 106 | -%MakeParams = InitMakeParams(); |
| 107 | - |
| 108 | -WriteMakefile(%MakeParams); |
| 109 | +WriteMakefile(InitMakeParams()); |
| 110 | |
| 111 | Check_Version(); |
| 112 | |
| 113 | diff --git a/perl/agent/Makefile.PL b/perl/agent/Makefile.PL |
| 114 | index 4f7bee3..003c0d1 100644 |
| 115 | --- a/perl/agent/Makefile.PL |
| 116 | +++ b/perl/agent/Makefile.PL |
| 117 | @@ -3,11 +3,8 @@ require 5; |
| 118 | use Config; |
| 119 | use Getopt::Long; |
| 120 | my $lib_version; |
| 121 | -my %MakeParams = (); |
| 122 | |
| 123 | -%MakeParams = InitMakeParams(); |
| 124 | - |
| 125 | -WriteMakefile(%MakeParams); |
| 126 | +WriteMakefile(InitMakeParams()); |
| 127 | |
| 128 | Check_Version(); |
| 129 | |
| 130 | diff --git a/perl/agent/Support/Makefile.PL b/perl/agent/Support/Makefile.PL |
| 131 | index 48815b6..2325e10 100644 |
| 132 | --- a/perl/agent/Support/Makefile.PL |
| 133 | +++ b/perl/agent/Support/Makefile.PL |
| 134 | @@ -3,14 +3,11 @@ require 5; |
| 135 | use Config; |
| 136 | use Getopt::Long; |
| 137 | my $lib_version; |
| 138 | -my %MakeParams = (); |
| 139 | |
| 140 | # See lib/ExtUtils/MakeMaker.pm for details of how to influence |
| 141 | # the contents of the Makefile that is written. |
| 142 | |
| 143 | -%MakeParams = InitMakeParams(); |
| 144 | - |
| 145 | -WriteMakefile(%MakeParams); |
| 146 | +WriteMakefile(InitMakeParams()); |
| 147 | |
| 148 | Check_Version(); |
| 149 | |
| 150 | diff --git a/perl/agent/default_store/Makefile.PL b/perl/agent/default_store/Makefile.PL |
| 151 | index ed6483a..31cfbee 100644 |
| 152 | --- a/perl/agent/default_store/Makefile.PL |
| 153 | +++ b/perl/agent/default_store/Makefile.PL |
| 154 | @@ -3,11 +3,8 @@ require 5; |
| 155 | use Config; |
| 156 | use Getopt::Long; |
| 157 | my $lib_version; |
| 158 | -my %MakeParams = (); |
| 159 | |
| 160 | -%MakeParams = InitMakeParams(); |
| 161 | - |
| 162 | -WriteMakefile(%MakeParams); |
| 163 | +WriteMakefile(InitMakeParams()); |
| 164 | |
| 165 | Check_Version(); |
| 166 | |
| 167 | diff --git a/perl/default_store/Makefile.PL b/perl/default_store/Makefile.PL |
| 168 | index 7c671b8..01c8dd0 100644 |
| 169 | --- a/perl/default_store/Makefile.PL |
| 170 | +++ b/perl/default_store/Makefile.PL |
| 171 | @@ -3,11 +3,8 @@ require 5; |
| 172 | use Config; |
| 173 | use Getopt::Long; |
| 174 | my $lib_version; |
| 175 | -my %MakeParams = (); |
| 176 | |
| 177 | -%MakeParams = InitMakeParams(); |
| 178 | - |
| 179 | -WriteMakefile(%MakeParams); |
| 180 | +WriteMakefile(InitMakeParams()); |
| 181 | |
| 182 | |
| 183 | sub InitMakeParams { |
| 184 | -- |
| 185 | 1.9.1 |
| 186 | |