Don't pull in conflicting functions (which do seem to work, but cause

a lot of warning spam on the console e.g. with mrtg).

Fedora diff identified by giovanni@ as fixing the problem, further
research and diff from okan@.

ok jasper@
(reminder, ports is not fully open, do not commit without specific permission)
This commit is contained in:
sthen 2010-02-26 23:00:56 +00:00
parent a090480935
commit 62afe9ccf8
3 changed files with 25 additions and 2 deletions

View File

@ -1,9 +1,10 @@
# $OpenBSD: Makefile,v 1.11 2009/12/13 23:47:51 sthen Exp $
# $OpenBSD: Makefile,v 1.12 2010/02/26 23:00:56 sthen Exp $
COMMENT= provides rudimentary access to remote SNMP agents
MODULES= cpan
DISTNAME= SNMP_Session-1.13
PKGNAME= p5-${DISTNAME}p0
CATEGORIES= net
HOMEPAGE= http://code.google.com/p/snmp-session/

View File

@ -0,0 +1,21 @@
$OpenBSD: patch-lib_SNMP_Session_pm,v 1.1 2010/02/26 23:00:56 sthen Exp $
--- lib/SNMP_Session.pm.orig Fri Jan 8 23:23:52 2010
+++ lib/SNMP_Session.pm Fri Jan 8 23:24:48 2010
@@ -146,7 +146,7 @@ BEGIN {
if (eval {local $SIG{__DIE__};require Socket6;} &&
eval {local $SIG{__DIE__};require IO::Socket::INET6; IO::Socket::INET6->VERSION("1.26");}) {
- import Socket6;
+ Socket6->import(qw(pack_sockaddr_in6 inet_pton));
$ipv6_addr_len = length(pack_sockaddr_in6(161, inet_pton(AF_INET6(), "::1")));
$SNMP_Session::ipv6available = 1;
}
@@ -605,7 +605,7 @@ use Carp;
BEGIN {
if($SNMP_Session::ipv6available) {
import IO::Socket::INET6;
- import Socket6;
+ Socket6->import(qw(pack_sockaddr_in6 inet_pton));
}
}

View File

@ -1,4 +1,5 @@
@comment $OpenBSD: PLIST,v 1.5 2004/09/15 18:17:44 espie Exp $
@comment $OpenBSD: PLIST,v 1.6 2010/02/26 23:00:56 sthen Exp $
${P5SITE}/BER.pm
${P5SITE}/SNMP_Session.pm
@comment ${P5SITE}/SNMP_Session.pm.orig
${P5SITE}/SNMP_util.pm