From f0949f92d046517aedf401af33aff52d773c9a76 Mon Sep 17 00:00:00 2001 From: bms Date: Thu, 20 May 2004 16:40:07 +0000 Subject: Deprecate the dependency on net-snmp4 by folding it under a WITH_NETSNMP4 switch, and set to depend on net-snmp's builtin SNMP.pm implementation by default. Reviewed by: fenner --- net-mgmt/p5-SNMP-Util/Makefile | 8 ++++++++ .../files/extra-net-snmp-patch-Makefile.PL | 19 +++++++++++++++++ net-mgmt/p5-SNMP-Util/files/patch-Makefile.PL | 24 ++++++++++++++++++++++ net-mgmt/p5-SNMP-Util/files/patch-aa | 24 ---------------------- 4 files changed, 51 insertions(+), 24 deletions(-) create mode 100644 net-mgmt/p5-SNMP-Util/files/extra-net-snmp-patch-Makefile.PL create mode 100644 net-mgmt/p5-SNMP-Util/files/patch-Makefile.PL delete mode 100644 net-mgmt/p5-SNMP-Util/files/patch-aa (limited to 'net-mgmt') diff --git a/net-mgmt/p5-SNMP-Util/Makefile b/net-mgmt/p5-SNMP-Util/Makefile index 297fce90e68b..1ccd5a5b08d1 100644 --- a/net-mgmt/p5-SNMP-Util/Makefile +++ b/net-mgmt/p5-SNMP-Util/Makefile @@ -15,7 +15,15 @@ PKGNAMEPREFIX= p5- MAINTAINER= fenner@FreeBSD.org COMMENT= Perl modules to perform SNMP set,get,walk,next,walk_hash etc +# +# Define WITH_NETSNMP4 to use net-mgmt/net-snmp4 instead of net-mgmt/net-snmp. +# +.if !defined(WITH_NETSNMP4) +RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/SNMP.pm:${PORTSDIR}/net-mgmt/net-snmp +EXTRA_PATCHES+= ${PATCHDIR}/extra-net-snmp-patch-Makefile.PL +.else RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/SNMP.pm:${PORTSDIR}/net-mgmt/p5-SNMP +.endif PERL_CONFIGURE= yes diff --git a/net-mgmt/p5-SNMP-Util/files/extra-net-snmp-patch-Makefile.PL b/net-mgmt/p5-SNMP-Util/files/extra-net-snmp-patch-Makefile.PL new file mode 100644 index 000000000000..96c1354cd6af --- /dev/null +++ b/net-mgmt/p5-SNMP-Util/files/extra-net-snmp-patch-Makefile.PL @@ -0,0 +1,19 @@ +--- Makefile.PL.orig Tue Jun 27 19:40:11 2000 ++++ Makefile.PL Thu May 20 14:04:59 2004 +@@ -1,13 +1,13 @@ + use ExtUtils::MakeMaker; + use FileHandle; + +-print "Checking for SNMP, V1.8 "; ++print "Checking for SNMP, V5.1 "; + $@ = ''; +-eval "use SNMP 1.8 ();"; ++eval "use SNMP 5.1 ();"; + if ($@) { + $ok = 0; +- print("\nYou don't have installed the SNMP module, version 1.8 or", ++ print("\nYou don't have installed the SNMP module, version 5.1 or", + " later.\n"); + } else { + print "ok\n"; + } diff --git a/net-mgmt/p5-SNMP-Util/files/patch-Makefile.PL b/net-mgmt/p5-SNMP-Util/files/patch-Makefile.PL new file mode 100644 index 000000000000..1ada2f247c76 --- /dev/null +++ b/net-mgmt/p5-SNMP-Util/files/patch-Makefile.PL @@ -0,0 +1,24 @@ +--- Makefile.PL.orig Tue Sep 7 15:26:45 1999 ++++ Makefile.PL Tue Sep 7 15:27:02 1999 +@@ -12,21 +12,6 @@ + print "ok\n"; + } + +-$FILE = new FileHandle; +-open($FILE,">t/snmp.data"); +- +-print "\nEnter the IP address of the Device: "; +-chomp($IP = ); +- +-print "Enter the SNMP community string: "; +-chomp($community = ); +- +-print $FILE "IP = $IP\n"; +-print $FILE "community = $community\n"; +- +-close $FILE; +- +- + # See lib/ExtUtils/MakeMaker.pm for details of how to influence + # the contents of the Makefile that is written. + WriteMakefile( diff --git a/net-mgmt/p5-SNMP-Util/files/patch-aa b/net-mgmt/p5-SNMP-Util/files/patch-aa deleted file mode 100644 index 1ada2f247c76..000000000000 --- a/net-mgmt/p5-SNMP-Util/files/patch-aa +++ /dev/null @@ -1,24 +0,0 @@ ---- Makefile.PL.orig Tue Sep 7 15:26:45 1999 -+++ Makefile.PL Tue Sep 7 15:27:02 1999 -@@ -12,21 +12,6 @@ - print "ok\n"; - } - --$FILE = new FileHandle; --open($FILE,">t/snmp.data"); -- --print "\nEnter the IP address of the Device: "; --chomp($IP = ); -- --print "Enter the SNMP community string: "; --chomp($community = ); -- --print $FILE "IP = $IP\n"; --print $FILE "community = $community\n"; -- --close $FILE; -- -- - # See lib/ExtUtils/MakeMaker.pm for details of how to influence - # the contents of the Makefile that is written. - WriteMakefile( -- cgit