summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Volkov <pva@gentoo.org>2008-06-16 17:16:27 +0000
committerPeter Volkov <pva@gentoo.org>2008-06-16 17:16:27 +0000
commit3de966806fbaf3b2220c16eb73c7374cb7f5d7b5 (patch)
treeb74765d63997acaef0a22b9bb8fb6a0586d1854a /net-analyzer/net-snmp
parentVersion bump. (diff)
downloadgentoo-2-3de966806fbaf3b2220c16eb73c7374cb7f5d7b5.tar.gz
gentoo-2-3de966806fbaf3b2220c16eb73c7374cb7f5d7b5.tar.bz2
gentoo-2-3de966806fbaf3b2220c16eb73c7374cb7f5d7b5.zip
Removed old. This also fixes bug #226583, thank Diego Pettenò for his work.
(Portage version: 2.1.4.4)
Diffstat (limited to 'net-analyzer/net-snmp')
-rw-r--r--net-analyzer/net-snmp/ChangeLog13
-rw-r--r--net-analyzer/net-snmp/files/net-snmp-5.2.1-conf-elf-rpm-bz2.patch147
-rw-r--r--net-analyzer/net-snmp/files/net-snmp-5.2.2-asneeded.patch70
-rw-r--r--net-analyzer/net-snmp/files/net-snmp-5.2.2-conf-elf-rpm-bz2.patch144
-rw-r--r--net-analyzer/net-snmp/files/net-snmp-5.3.1-retrans-time.patch93
-rw-r--r--net-analyzer/net-snmp/files/net-snmp-5.3.1-tcp-udp-mib-byteorder.patch233
-rw-r--r--net-analyzer/net-snmp/files/net-snmp-maxreps.patch122
-rw-r--r--net-analyzer/net-snmp/files/snmpd-5.1.conf17
-rw-r--r--net-analyzer/net-snmp/files/snmpd-5.1.rc630
-rw-r--r--net-analyzer/net-snmp/net-snmp-5.2.2-r3.ebuild181
-rw-r--r--net-analyzer/net-snmp/net-snmp-5.3.1-r1.ebuild186
11 files changed, 12 insertions, 1224 deletions
diff --git a/net-analyzer/net-snmp/ChangeLog b/net-analyzer/net-snmp/ChangeLog
index e66dca147bd4..c0babd54cc52 100644
--- a/net-analyzer/net-snmp/ChangeLog
+++ b/net-analyzer/net-snmp/ChangeLog
@@ -1,6 +1,17 @@
# ChangeLog for net-analyzer/net-snmp
# Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/net-snmp/ChangeLog,v 1.170 2008/06/16 13:48:22 pva Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/net-snmp/ChangeLog,v 1.171 2008/06/16 17:16:27 pva Exp $
+
+ 16 Jun 2008; Peter Volkov <pva@gentoo.org> -files/snmpd-5.1.conf,
+ -files/snmpd-5.1.rc6, -files/net-snmp-5.2.1-conf-elf-rpm-bz2.patch,
+ -files/net-snmp-5.2.2-asneeded.patch,
+ -files/net-snmp-5.2.2-conf-elf-rpm-bz2.patch,
+ -files/net-snmp-5.3.1-retrans-time.patch,
+ -files/net-snmp-5.3.1-tcp-udp-mib-byteorder.patch,
+ -files/net-snmp-maxreps.patch, -net-snmp-5.2.2-r3.ebuild,
+ -net-snmp-5.3.1-r1.ebuild:
+ Removed old. This also fixes bug #226583, thank Diego Pettenò for his
+ work.
*net-snmp-5.4.1.1 (16 Jun 2008)
diff --git a/net-analyzer/net-snmp/files/net-snmp-5.2.1-conf-elf-rpm-bz2.patch b/net-analyzer/net-snmp/files/net-snmp-5.2.1-conf-elf-rpm-bz2.patch
deleted file mode 100644
index 9ba303369298..000000000000
--- a/net-analyzer/net-snmp/files/net-snmp-5.2.1-conf-elf-rpm-bz2.patch
+++ /dev/null
@@ -1,147 +0,0 @@
---- configure.orig 2005-02-17 20:20:50.735101408 +0930
-+++ configure 2005-02-17 20:36:35.883389400 +0930
-@@ -1253,7 +1253,9 @@
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-pic try to use only PIC/non-PIC objects default=use both
- --with-libwrap=LIBPATH Compile in libwrap (tcp_wrappers) support.
-+ --without-elf use elf libraries
- --with-zlib=DIR use libz in DIR
-+ --with-bzip2=DIR use libbzip2 in DIR
-
- Some influential environment variables:
- CC C compiler command
-@@ -5911,7 +5913,7 @@
- case $host in
- *-*-irix6*)
- # Find out which ABI we are using.
-- echo '#line 5914 "configure"' > conftest.$ac_ext
-+ echo '#line 5916 "configure"' > conftest.$ac_ext
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
-@@ -6483,7 +6485,7 @@
- save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
- compiler_c_o=no
--if { (eval echo configure:6486: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
-+if { (eval echo configure:6488: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s out/conftest.err; then
-@@ -8447,7 +8449,7 @@
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<EOF
--#line 8450 "configure"
-+#line 8452 "configure"
- #include "confdefs.h"
-
- #if HAVE_DLFCN_H
-@@ -8545,7 +8547,7 @@
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<EOF
--#line 8548 "configure"
-+#line 8550 "configure"
- #include "confdefs.h"
-
- #if HAVE_DLFCN_H
-@@ -14405,6 +14407,12 @@
-
- # nlist is needed for uptime on some sytems in the generic library
-
-+# Check whether --with-elf or --without-elf was given.
-+if test "${with_elf+set}" = set; then
-+ withval="$with_elf"
-+
-+ if test "x$with_elf" != "xno"; then
-+
- echo "$as_me:$LINENO: checking for nlist in -lelf" >&5
- echo $ECHO_N "checking for nlist in -lelf... $ECHO_C" >&6
- if test "${ac_cv_lib_elf_nlist+set}" = set; then
-@@ -14478,6 +14486,11 @@
-
- fi
-
-+ fi
-+
-+fi;
-+
-+
-
- # On some platforms (Irix) libnsl and libsocket should not be used.
- echo "$as_me:$LINENO: checking for gethostbyname" >&5
-@@ -15250,7 +15263,17 @@
-
-
- # two variants of bzip2 need checking.
-- echo "$as_me:$LINENO: checking for bzread in -lbz2" >&5
-+
-+# Check whether --with-bzip2 or --without-bzip2 was given.
-+if test "${with_bzip2+set}" = set; then
-+ withval="$with_bzip2"
-+
-+ if test -d "$withval"; then
-+ CPPFLAGS="${CPPFLAGS} -I$withval/include"
-+ LDFLAGS="${LDFLAGS} -L$withval/lib"
-+ fi
-+ if test "x$with_bzip2" != "xno"; then
-+ echo "$as_me:$LINENO: checking for bzread in -lbz2" >&5
- echo $ECHO_N "checking for bzread in -lbz2... $ECHO_C" >&6
- if test "${ac_cv_lib_bz2_bzread+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-@@ -15387,6 +15410,10 @@
-
- fi
-
-+ fi
-+
-+fi;
-+
-
- # two variants of db1 need checking.
- echo "$as_me:$LINENO: checking for dbopen in -ldb1" >&5
---- configure.in.orig 2005-02-17 19:14:14.000000000 +0930
-+++ configure.in 2005-02-17 20:36:18.450039672 +0930
-@@ -1,3 +1,4 @@
-+Wrpm
- # Portions of this file are subject to the following copyright. See
- # the Net-SNMP's COPYING file for more details and other copyrights
- # that may apply:
-@@ -2172,7 +2173,14 @@
- # AC_CHECK_LIB(des, main)
- AC_CHECK_LIB(m, asin)
- # nlist is needed for uptime on some sytems in the generic library
--AC_CHECK_LIB(elf, nlist)
-+ AC_ARG_WITH(elf,
-+ [ --without-elf use elf libraries],[
-+ if test "x$with_elf" != "xno"; then
-+ AC_CHECK_LIB(elf, nlist)
-+ fi
-+ ])
-+
-+
-
- # On some platforms (Irix) libnsl and libsocket should not be used.
- AC_CHECK_FUNC(gethostbyname, AC_DEFINE(HAVE_GETHOSTBYNAME),
-@@ -2219,8 +2227,18 @@
- CPPFLAGS=${_cppflags} LDFLAGS=${_ldflags})
-
- # two variants of bzip2 need checking.
-- AC_CHECK_LIB(bz2, bzread, [_rpmlibs="$_rpmlibs -lbz2"],
-- AC_CHECK_LIB(bz2, BZ2_bzread, [_rpmlibs="$_rpmlibs -lbz2"],))
-+ AC_ARG_WITH(bzip2,
-+ [ --with-bzip2[=DIR] use libbzip2 in DIR],[
-+ if test -d "$withval"; then
-+ CPPFLAGS="${CPPFLAGS} -I$withval/include"
-+ LDFLAGS="${LDFLAGS} -L$withval/lib"
-+ fi
-+ if test "x$with_bzip2" != "xno"; then
-+ AC_CHECK_LIB(bz2, bzread, [_rpmlibs="$_rpmlibs -lbz2"],
-+ AC_CHECK_LIB(bz2, BZ2_bzread, [_rpmlibs="$_rpmlibs -lbz2"],))
-+ fi
-+ ])
-+
-
- # two variants of db1 need checking.
- AC_CHECK_LIB(db1, dbopen, [_rpmlibs="-ldb1 $_rpmlibs"],
diff --git a/net-analyzer/net-snmp/files/net-snmp-5.2.2-asneeded.patch b/net-analyzer/net-snmp/files/net-snmp-5.2.2-asneeded.patch
deleted file mode 100644
index 12af501d6602..000000000000
--- a/net-analyzer/net-snmp/files/net-snmp-5.2.2-asneeded.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-Index: net-snmp-5.2.2/snmplib/Makefile.in
-===================================================================
---- net-snmp-5.2.2.orig/snmplib/Makefile.in
-+++ net-snmp-5.2.2/snmplib/Makefile.in
-@@ -185,11 +185,11 @@ all: standardall
-
- # how to build the libraries.
- libnetsnmp.$(LIB_EXTENSION)$(LIB_VERSION): ${TOBJS}
-- $(LIB_LD_CMD) libnetsnmp.$(LIB_EXTENSION)$(LIB_VERSION) ${TOBJS}
-+ $(LIB_LD_CMD) libnetsnmp.$(LIB_EXTENSION)$(LIB_VERSION) ${TOBJS} @LIBCRYPTO@
- $(RANLIB) libnetsnmp.$(LIB_EXTENSION)$(LIB_VERSION)
-
- libsnmp.$(LIB_EXTENSION)$(LIB_VERSION): ${TOBJS}
-- $(LIB_LD_CMD) libsnmp.$(LIB_EXTENSION)$(LIB_VERSION) ${TOBJS}
-+ $(LIB_LD_CMD) libsnmp.$(LIB_EXTENSION)$(LIB_VERSION) ${TOBJS} @LIBCRYPTO@
- $(RANLIB) libsnmp.$(LIB_EXTENSION)$(LIB_VERSION)
-
- #
-Index: net-snmp-5.2.2/configure.in
-===================================================================
---- net-snmp-5.2.2.orig/configure.in
-+++ net-snmp-5.2.2/configure.in
-@@ -2362,11 +2362,12 @@ if test $? -eq 0 ; then
- *)
- AC_CHECK_HEADER(sensors/sensors.h,,
- [AC_MSG_ERROR([asked to use lm_sensors but I couldn't find sensors/sensors.h])])
-- AC_CHECK_LIB(sensors, sensors_get_detected_chips, LIBS="${LIBS} -lsensors",
-+ AC_CHECK_LIB(sensors, sensors_get_detected_chips, SENSORLIBS="-lsensors",
- [AC_MSG_ERROR([asked to use lm_sensors but I couldn't find -lsensors])])
- ;;
- esac
- fi
-+AC_SUBST(SENSORLIBS)
-
- #
- # Install the various perl modules
-@@ -2691,6 +2692,7 @@ if test "x$useopenssl" != "xno" ; then
- encrmodes="[disabled]"
- fi
- AC_DEFINE(USE_OPENSSL)
-+ LIBCRYPTO="-lcrypto"
- AC_MSG_RESULT(OpenSSL Support)
- elif test "x$usepkcs" != "xno" ; then
- authmodes="MD5 SHA1"
-@@ -2710,6 +2712,7 @@ fi
- if test "x$enable_md5" = "xno"; then
- authmodes=`echo $authmodes | sed 's/MD5 *//;'`
- fi
-+AC_SUBST(LIBCRYPTO)
-
- AC_MSG_CACHE_ADD(Authentication support: $authmodes)
- AC_MSG_CACHE_ADD(Encryption support: $encrmodes)
-Index: net-snmp-5.2.2/agent/Makefile.in
-===================================================================
---- net-snmp-5.2.2.orig/agent/Makefile.in
-+++ net-snmp-5.2.2/agent/Makefile.in
-@@ -130,11 +130,11 @@ snmpd$(EXEEXT): ${LAGENTOBJS} $(USELIBS)
-
-
- libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION): ${LLIBAGENTOBJS} libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION)
-- $(LIB_LD_CMD) libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION) ${LLIBAGENTOBJS} $(LIB_LD_LIBS)
-+ $(LIB_LD_CMD) libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION) ${LLIBAGENTOBJS} $(LIB_LD_LIBS) helpers/libnetsnmphelpers.la
- $(RANLIB) libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION)
-
- libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION): ${LMIBOBJS}
-- $(LIB_LD_CMD) libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION) ${LMIBOBJS} $(LIB_LD_LIBS)
-+ $(LIB_LD_CMD) libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION) ${LMIBOBJS} $(LIB_LD_LIBS) @SENSORLIBS@
- $(RANLIB) libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION)
-
- embedperlinstall:
diff --git a/net-analyzer/net-snmp/files/net-snmp-5.2.2-conf-elf-rpm-bz2.patch b/net-analyzer/net-snmp/files/net-snmp-5.2.2-conf-elf-rpm-bz2.patch
deleted file mode 100644
index 362fcbcc87be..000000000000
--- a/net-analyzer/net-snmp/files/net-snmp-5.2.2-conf-elf-rpm-bz2.patch
+++ /dev/null
@@ -1,144 +0,0 @@
-diff --exclude='*~' -Naur net-snmp-5.2.2.orig/configure net-snmp-5.2.2/configure
---- net-snmp-5.2.2.orig/configure 2005-12-26 19:05:44.000000000 -0200
-+++ net-snmp-5.2.2/configure 2005-12-26 19:10:47.000000000 -0200
-@@ -1254,7 +1254,9 @@
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-pic try to use only PIC/non-PIC objects default=use both
- --with-libwrap=LIBPATH Compile in libwrap (tcp_wrappers) support.
-+ --without-elf use elf libraries
- --with-zlib=DIR use libz in DIR
-+ --with-bzip2=DIR use libbzip2 in DIR
-
- Some influential environment variables:
- CC C compiler command
-@@ -5935,7 +5937,7 @@
- case $host in
- *-*-irix6*)
- # Find out which ABI we are using.
-- echo '#line 5938 "configure"' > conftest.$ac_ext
-+ echo '#line 5940 "configure"' > conftest.$ac_ext
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
-@@ -6507,7 +6509,7 @@
- save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
- compiler_c_o=no
--if { (eval echo configure:6510: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
-+if { (eval echo configure:6512: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s out/conftest.err; then
-@@ -8471,7 +8473,7 @@
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<EOF
--#line 8474 "configure"
-+#line 8476 "configure"
- #include "confdefs.h"
-
- #if HAVE_DLFCN_H
-@@ -13996,6 +13998,12 @@
-
- # nlist is needed for uptime on some sytems in the generic library
- # add hosts which don't use nlist to the blank first line
-+# Check whether --with-elf or --without-elf was given.
-+if test "${with_elf+set}" = set; then
-+ withval="$with_elf"
-+
-+ if test "x$with_elf" != "xno"; then
-+
- case $target_os in
- linux*) ;;
- irix*) # Check for nlist in mld (irix)
-@@ -14226,6 +14234,10 @@
- ;;
- esac
-
-+ fi
-+
-+fi;
-+
- # On some platforms (Irix) libnsl and libsocket should not be used.
- echo "$as_me:$LINENO: checking for gethostbyname" >&5
- echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
-@@ -16020,7 +16032,16 @@
-
-
- # two variants of bzip2 need checking.
-- echo "$as_me:$LINENO: checking for bzread in -lbz2" >&5
-+# Check whether --with-bzip2 or --without-bzip2 was given.
-+if test "${with_bzip2+set}" = set; then
-+ withval="$with_bzip2"
-+
-+ if test -d "$withval"; then
-+ CPPFLAGS="${CPPFLAGS} -I$withval/include"
-+ LDFLAGS="${LDFLAGS} -L$withval/lib"
-+ fi
-+ if test "x$with_bzip2" != "xno"; then
-+ echo "$as_me:$LINENO: checking for bzread in -lbz2" >&5
- echo $ECHO_N "checking for bzread in -lbz2... $ECHO_C" >&6
- if test "${ac_cv_lib_bz2_bzread+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-@@ -16157,6 +16178,9 @@
-
- fi
-
-+ fi
-+
-+fi;
-
- # two variants of db1 need checking.
- echo "$as_me:$LINENO: checking for dbopen in -ldb1" >&5
-diff --exclude='*~' -Naur net-snmp-5.2.2.orig/configure.in net-snmp-5.2.2/configure.in
---- net-snmp-5.2.2.orig/configure.in 2005-12-26 19:05:44.000000000 -0200
-+++ net-snmp-5.2.2/configure.in 2005-12-26 19:23:50.000000000 -0200
-@@ -1,3 +1,4 @@
-+Wrpm
- # Portions of this file are subject to the following copyright. See
- # the Net-SNMP's COPYING file for more details and other copyrights
- # that may apply:
-@@ -2152,11 +2153,21 @@
- case $target_os in
- linux*) ;;
- irix*) # Check for nlist in mld (irix)
-- AC_CHECK_LIB(elf, nlist)
-+ AC_ARG_WITH(elf,
-+ [ --without-elf use elf libraries],[
-+ if test "x$with_elf" != "xno"; then
-+ AC_CHECK_LIB(elf, nlist)
-+ fi
-+ ])
- AC_CHECK_LIB(mld, nlist)
- ;;
- *) # default
-- AC_CHECK_LIB(elf, nlist)
-+ AC_ARG_WITH(elf,
-+ [ --without-elf use elf libraries],[
-+ if test "x$with_elf" != "xno"; then
-+ AC_CHECK_LIB(elf, nlist)
-+ fi
-+ ])
- ;;
- esac
-
-@@ -2280,8 +2291,17 @@
- CPPFLAGS=${_cppflags} LDFLAGS=${_ldflags})
-
- # two variants of bzip2 need checking.
-- AC_CHECK_LIB(bz2, bzread, [_rpmlibs="$_rpmlibs -lbz2"],
-- AC_CHECK_LIB(bz2, BZ2_bzread, [_rpmlibs="$_rpmlibs -lbz2"],))
-+ AC_ARG_WITH(bzip2,
-+ [ --with-bzip2[=DIR] use libbzip2 in DIR],[
-+ if test -d "$withval"; then
-+ CPPFLAGS="${CPPFLAGS} -I$withval/include"
-+ LDFLAGS="${LDFLAGS} -L$withval/lib"
-+ fi
-+ if test "x$with_bzip2" != "xno"; then
-+ AC_CHECK_LIB(bz2, bzread, [_rpmlibs="$_rpmlibs -lbz2"],
-+ AC_CHECK_LIB(bz2, BZ2_bzread, [_rpmlibs="$_rpmlibs -lbz2"],))
-+ fi
-+ ])
-
- # two variants of db1 need checking.
- AC_CHECK_LIB(db1, dbopen, [_rpmlibs="-ldb1 $_rpmlibs"],
diff --git a/net-analyzer/net-snmp/files/net-snmp-5.3.1-retrans-time.patch b/net-analyzer/net-snmp/files/net-snmp-5.3.1-retrans-time.patch
deleted file mode 100644
index 45eb35cff2a8..000000000000
--- a/net-analyzer/net-snmp/files/net-snmp-5.3.1-retrans-time.patch
+++ /dev/null
@@ -1,93 +0,0 @@
-Index: agent/mibgroup/if-mib/data_access/interface_linux.c
-===================================================================
---- agent/mibgroup/if-mib/data_access/interface_linux.c.orig
-+++ agent/mibgroup/if-mib/data_access/interface_linux.c
-@@ -22,6 +22,8 @@
- #include "interface_ioctl.h"
-
- #include <sys/types.h>
-+#include <sys/stat.h>
-+#include <unistd.h>
-
- #ifdef HAVE_LINUX_ETHTOOL_H
- #include <sys/types.h>
-@@ -40,6 +42,10 @@ unsigned int
- netsnmp_linux_interface_get_if_speed_mii(int fd, const char *name);
- #endif
-
-+#define PROC_SYS_NET_IPVx_NEIGH_RETRANS_TIME_MS "/proc/sys/net/ipv%d/neigh/%s/retrans_time_ms"
-+#define PROC_SYS_NET_IPVx_NEIGH_RETRANS_TIME "/proc/sys/net/ipv%d/neigh/%s/retrans_time"
-+static char *proc_sys_retrans_time;
-+static unsigned short retrans_time_factor = 0;
-
- void
- netsnmp_arch_interface_init(void)
-@@ -47,6 +53,20 @@ netsnmp_arch_interface_init(void)
- /*
- * nothing to do
- */
-+ char proc_path[64+IF_NAMESIZE];
-+ char proc_path2[64+IF_NAMESIZE];
-+ struct stat st;
-+
-+ snprintf(proc_path, sizeof(proc_path), PROC_SYS_NET_IPVx_NEIGH_RETRANS_TIME_MS, 6, "default");
-+ snprintf(proc_path2, sizeof(proc_path2), PROC_SYS_NET_IPVx_NEIGH_RETRANS_TIME_MS, 4, "default");
-+
-+ if ((stat(proc_path, &st) == 0) || (stat(proc_path2, &st) == 0)) {
-+ proc_sys_retrans_time = PROC_SYS_NET_IPVx_NEIGH_RETRANS_TIME_MS;
-+ }
-+ else {
-+ proc_sys_retrans_time = PROC_SYS_NET_IPVx_NEIGH_RETRANS_TIME;
-+ retrans_time_factor = 10;
-+ }
- }
-
- /*
-@@ -161,7 +181,7 @@ _arch_interface_flags_v4_get(netsnmp_int
- /*
- * get the retransmit time
- */
-- snprintf(line,sizeof(line),"/proc/sys/net/ipv4/neigh/%s/retrans_time",
-+ snprintf(line,sizeof(line),proc_sys_retrans_time, 4,
- entry->name);
- if (!(fin = fopen(line, "r"))) {
- DEBUGMSGTL(("access:interface",
-@@ -169,7 +189,12 @@ _arch_interface_flags_v4_get(netsnmp_int
- }
- else {
- if (fgets(line, sizeof(line), fin)) {
-- entry->retransmit_v4 = atoi(line) * 100;
-+ if (retrans_time_factor) {
-+ entry->retransmit_v4 = atoi(line) * retrans_time_factor;
-+ }
-+ else {
-+ entry->retransmit_v4 = atoi(line);
-+ };
- entry->ns_flags |= NETSNMP_INTERFACE_FLAGS_HAS_V4_RETRANSMIT;
- }
- fclose(fin);
-@@ -191,7 +216,7 @@ _arch_interface_flags_v6_get(netsnmp_int
- /*
- * get the retransmit time
- */
-- snprintf(line,sizeof(line),"/proc/sys/net/ipv6/neigh/%s/retrans_time",
-+ snprintf(line,sizeof(line),proc_sys_retrans_time, 6,
- entry->name);
- if (!(fin = fopen(line, "r"))) {
- DEBUGMSGTL(("access:interface",
-@@ -199,7 +224,12 @@ _arch_interface_flags_v6_get(netsnmp_int
- }
- else {
- if (fgets(line, sizeof(line), fin)) {
-- entry->retransmit_v6 = atoi(line);
-+ if (retrans_time_factor) {
-+ entry->retransmit_v6 = atoi(line) * retrans_time_factor;
-+ }
-+ else {
-+ entry->retransmit_v6 = atoi(line);
-+ };
- entry->ns_flags |= NETSNMP_INTERFACE_FLAGS_HAS_V6_RETRANSMIT;
- }
- fclose(fin);
-
-
diff --git a/net-analyzer/net-snmp/files/net-snmp-5.3.1-tcp-udp-mib-byteorder.patch b/net-analyzer/net-snmp/files/net-snmp-5.3.1-tcp-udp-mib-byteorder.patch
deleted file mode 100644
index 389cd2bfd873..000000000000
--- a/net-analyzer/net-snmp/files/net-snmp-5.3.1-tcp-udp-mib-byteorder.patch
+++ /dev/null
@@ -1,233 +0,0 @@
-Index: agent/mibgroup/tcp-mib/data_access/tcpConn_linux.c
-===================================================================
-RCS file: /cvsroot/net-snmp/net-snmp/agent/mibgroup/tcp-mib/data_access/tcpConn_linux.c,v
-retrieving revision 1.5.2.1
-diff -u -p -u -r1.5.2.1 tcpConn_linux.c
---- agent/mibgroup/tcp-mib/data_access/tcpConn_linux.c 17 Aug 2006 08:52:15 -0000 1.5.2.1
-+++ agent/mibgroup/tcp-mib/data_access/tcpConn_linux.c 1 Sep 2006 17:15:23 -0000
-@@ -169,11 +169,20 @@ _load4(netsnmp_container *container, u_i
- break;
- }
-
-- entry->loc_port = htons((unsigned short) local_port);
-- entry->rmt_port = htons((unsigned short) remote_port);
-+ /** oddly enough, these appear to already be in network order */
-+ entry->loc_port = (unsigned short) local_port;
-+ entry->rmt_port = (unsigned short) remote_port;
- entry->tcpConnState = state;
-+
-+ /** the addr string may need work */
- buf_len = strlen(local_addr);
-- netsnmp_assert(8 == buf_len);
-+ if ((8 != buf_len) ||
-+ (-1 == netsnmp_addrstr_hton(local_addr, 8))) {
-+ DEBUGMSGT(("verbose:access:tcpconn:container",
-+ " error processing local address\n"));
-+ netsnmp_access_tcpconn_entry_free(entry);
-+ continue;
-+ }
- offset = 0;
- tmp_ptr = entry->loc_addr;
- rc = netsnmp_hex_to_binary(&tmp_ptr, &buf_len,
-@@ -188,8 +197,15 @@ _load4(netsnmp_container *container, u_i
- continue;
- }
-
-- buf_len = strlen(remote_addr);
-- netsnmp_assert(8 == buf_len);
-+ /** the addr string may need work */
-+ buf_len = strlen((char*)remote_addr);
-+ if ((8 != buf_len) ||
-+ (-1 == netsnmp_addrstr_hton(remote_addr, 8))) {
-+ DEBUGMSGT(("verbose:access:tcpconn:container",
-+ " error processing remote address\n"));
-+ netsnmp_access_tcpconn_entry_free(entry);
-+ continue;
-+ }
- offset = 0;
- tmp_ptr = entry->rmt_addr;
- rc = netsnmp_hex_to_binary(&tmp_ptr, &buf_len,
-@@ -244,6 +260,8 @@ _load6(netsnmp_container *container, u_i
- fgets(line, sizeof(line), in); /* skip header */
-
- /*
-+ * Note: PPC (big endian)
-+ *
- * sl local_address rem_address st tx_queue rx_queue tr tm->when retrnsmt uid timeout inode
- * 0: 00000000000000000000000000000001:1466 00000000000000000000000000000000:0000 0A 00000000:00000000 00:00000000 00000000 500 0 326699 1 efb81580 3000 0 0 2 -1
- */
-@@ -291,11 +309,20 @@ _load6(netsnmp_container *container, u_i
- break;
- }
-
-- entry->loc_port = htons((unsigned short) local_port);
-- entry->rmt_port = htons((unsigned short) remote_port);
-+ /** oddly enough, these appear to already be in network order */
-+ entry->loc_port = (unsigned short) local_port;
-+ entry->rmt_port = (unsigned short) remote_port;
- entry->tcpConnState = state;
-
-- buf_len = strlen(local_addr);
-+ /** the addr string may need work */
-+ buf_len = strlen((char*)local_addr);
-+ if ((32 != buf_len) ||
-+ (-1 == netsnmp_addrstr_hton(local_addr, 32))) {
-+ DEBUGMSGT(("verbose:access:tcpconn:container",
-+ " error processing local address\n"));
-+ netsnmp_access_tcpconn_entry_free(entry);
-+ continue;
-+ }
- offset = 0;
- tmp_ptr = entry->loc_addr;
- rc = netsnmp_hex_to_binary(&tmp_ptr, &buf_len,
-@@ -310,7 +337,14 @@ _load6(netsnmp_container *container, u_i
- continue;
- }
-
-- buf_len = strlen(remote_addr);
-+ buf_len = strlen((char*)remote_addr);
-+ if ((32 != buf_len) ||
-+ (-1 == netsnmp_addrstr_hton(remote_addr, 32))) {
-+ DEBUGMSGT(("verbose:access:tcpconn:container",
-+ " error processing remote address\n"));
-+ netsnmp_access_tcpconn_entry_free(entry);
-+ continue;
-+ }
- offset = 0;
- tmp_ptr = entry->rmt_addr;
- rc = netsnmp_hex_to_binary(&tmp_ptr, &buf_len,
-Index: agent/mibgroup/udp-mib/data_access/udp_endpoint_linux.c
-===================================================================
-RCS file: /cvsroot/net-snmp/net-snmp/agent/mibgroup/udp-mib/data_access/udp_endpoint_linux.c,v
-retrieving revision 1.2.2.1
-diff -u -p -u -r1.2.2.1 udp_endpoint_linux.c
---- agent/mibgroup/udp-mib/data_access/udp_endpoint_linux.c 25 Jan 2006 16:27:40 -0000 1.2.2.1
-+++ agent/mibgroup/udp-mib/data_access/udp_endpoint_linux.c 1 Sep 2006 17:15:23 -0000
-@@ -112,9 +112,9 @@ _process_line_udp_ep(netsnmp_line_info *
- struct netsnmp_line_process_info_s* lpi)
- {
- netsnmp_udp_endpoint_entry *ep = (netsnmp_udp_endpoint_entry *)mem;
-- char *ptr;
-+ char *ptr, *sep;
- u_char *u_ptr;
-- size_t u_ptr_len, offset;
-+ size_t u_ptr_len, offset, len;
-
- /*
- * skip 'sl'
-@@ -135,10 +135,22 @@ _process_line_udp_ep(netsnmp_line_info *
- /*
- * get local address. ignore error on hex conversion, since that
- * function doesn't like the ':' between address and port. check the
-- * offset to see if it worked.
-+ * offset to see if it worked. May need to flip string too.
- */
- u_ptr = ep->loc_addr;
- u_ptr_len = sizeof(ep->loc_addr);
-+ sep = strchr(ptr, ':');
-+ if (NULL == sep) {
-+ DEBUGMSGTL(("text:util:tvi", "no ':' '%s'\n",
-+ line_info->start));
-+ return PMLP_RC_MEMORY_UNUSED;
-+ }
-+ len = (sep - ptr);
-+ if (-1 == netsnmp_addrstr_hton(ptr, len)) {
-+ DEBUGMSGTL(("text:util:tvi", "bad length %d for loc addr '%s'\n",
-+ u_ptr_len, line_info->start));
-+ return PMLP_RC_MEMORY_UNUSED;
-+ }
- offset = 0;
- netsnmp_hex_to_binary(&u_ptr, &u_ptr_len, &offset, 0, ptr, NULL);
- if ((4 != offset) && (16 != offset)) {
-@@ -159,14 +171,26 @@ _process_line_udp_ep(netsnmp_line_info *
- /*
- * get remote address. ignore error on hex conversion, since that
- * function doesn't like the ':' between address and port. check the
-- * offset to see if it worked.
-+ * offset to see if it worked. May need to flip string too.
- */
- u_ptr = ep->rmt_addr;
- u_ptr_len = sizeof(ep->rmt_addr);
-+ sep = strchr(ptr, ':');
-+ if (NULL == sep) {
-+ DEBUGMSGTL(("text:util:tvi", "no ':' '%s'\n",
-+ line_info->start));
-+ return PMLP_RC_MEMORY_UNUSED;
-+ }
-+ len = (sep - ptr);
-+ if (-1 == netsnmp_addrstr_hton(ptr, len)) {
-+ DEBUGMSGTL(("text:util:tvi", "bad length %d for rmt addr '%s'\n",
-+ u_ptr_len, line_info->start));
-+ return PMLP_RC_MEMORY_UNUSED;
-+ }
- offset = 0;
- netsnmp_hex_to_binary(&u_ptr, &u_ptr_len, &offset, 0, ptr, NULL);
- if ((4 != offset) && (16 != offset)) {
-- DEBUGMSGTL(("text:util:tvi", "bad offset %d for loc addr '%s'\n",
-+ DEBUGMSGTL(("text:util:tvi", "bad offset %d for rmt addr '%s'\n",
- offset, line_info->start));
- return PMLP_RC_MEMORY_UNUSED;
- }
-Index: include/net-snmp/library/tools.h
-===================================================================
-RCS file: /cvsroot/net-snmp/net-snmp/include/net-snmp/library/tools.h,v
-retrieving revision 5.8.2.2
-diff -u -p -u -r5.8.2.2 tools.h
---- include/net-snmp/library/tools.h 13 Jun 2006 12:50:36 -0000 5.8.2.2
-+++ include/net-snmp/library/tools.h 1 Sep 2006 17:15:24 -0000
-@@ -198,7 +198,9 @@ extern "C" {
- int marker_tticks(marker_t pm);
- int timeval_tticks(struct timeval *tv);
- char *netsnmp_getenv(const char *name);
--
-+
-+ int netsnmp_addrstr_hton(char *ptr, size_t len);
-+
- #ifdef __cplusplus
- }
- #endif
-Index: snmplib/tools.c
-===================================================================
-RCS file: /cvsroot/net-snmp/net-snmp/snmplib/tools.c,v
-retrieving revision 5.10.2.2
-diff -u -p -u -r5.10.2.2 tools.c
---- snmplib/tools.c 25 Jul 2006 08:04:35 -0000 5.10.2.2
-+++ snmplib/tools.c 1 Sep 2006 17:15:26 -0000
-@@ -1042,3 +1042,35 @@ char *netsnmp_getenv(const char *name)
- #endif
- }
-
-+/*
-+ * swap the order of an inet addr string
-+ */
-+int
-+netsnmp_addrstr_hton(char *ptr, size_t len)
-+{
-+#ifndef WORDS_BIGENDIAN
-+ char tmp[8];
-+
-+ if (8 == len) {
-+ tmp[0] = ptr[6];
-+ tmp[1] = ptr[7];
-+ tmp[2] = ptr[4];
-+ tmp[3] = ptr[5];
-+ tmp[4] = ptr[2];
-+ tmp[5] = ptr[3];
-+ tmp[6] = ptr[0];
-+ tmp[7] = ptr[1];
-+ memcpy (ptr, &tmp, 8);
-+ }
-+ else if (32 == len) {
-+ netsnmp_addrstr_hton(ptr , 8);
-+ netsnmp_addrstr_hton(ptr+8 , 8);
-+ netsnmp_addrstr_hton(ptr+16, 8);
-+ netsnmp_addrstr_hton(ptr+24, 8);
-+ }
-+ else
-+ return -1;
-+#endif
-+
-+ return 0;
-+}
-
-
diff --git a/net-analyzer/net-snmp/files/net-snmp-maxreps.patch b/net-analyzer/net-snmp/files/net-snmp-maxreps.patch
deleted file mode 100644
index 7d9627deaad5..000000000000
--- a/net-analyzer/net-snmp/files/net-snmp-maxreps.patch
+++ /dev/null
@@ -1,122 +0,0 @@
-Index: man/snmpd.conf.5.def
-===================================================================
---- man/snmpd.conf.5.def (revision 16338)
-+++ man/snmpd.conf.5.def (working copy)
-@@ -71,6 +71,28 @@
- .IP "leave_pidfile yes"
- instructs the agent to not remove its pid file on shutdown. Equivalent to
- specifying "-U" on the command line.
-+.IP "maxGetbulkRepeats NUM"
-+Sets the maximum number of responses allowed for a single variable in
-+a getbulk request. Set to 0 to enable the default and set it to -1 to
-+enable unlimited. Because memory is allocated ahead of time, sitting
-+this to unlimited is not considered safe if your user population can
-+not be trusted. A repeat number greater than this will be truncated
-+to this value.
-+.IP
-+This is set by default to -1.
-+.IP "maxGetbulkResponses NUM"
-+Sets the maximum number of responses allowed for a getbulk request.
-+This is set by default to 100. Set to 0 to enable the default and set
-+it to -1 to enable unlimited. Because memory is allocated ahead of
-+time, sitting this to unlimited is not considered safe if your user
-+population can not be trusted.
-+.IP
-+In general, the total number of responses will not be allowed to
-+exceed the maxGetbulkResponses number and the total number returned
-+will be an integer multiple of the number of variables requested times
-+the calculated number of repeats allow to fit below this number.
-+.IP
-+Also not that processing of maxGetbulkRepeats is handled first.
- .SS SNMPv3 Configuration
- SNMPv3 requires an SNMP agent to define a unique "engine ID"
- in order to respond to SNMPv3 requests.
-Index: include/net-snmp/agent/ds_agent.h
-===================================================================
---- include/net-snmp/agent/ds_agent.h (revision 16338)
-+++ include/net-snmp/agent/ds_agent.h (working copy)
-@@ -59,5 +59,7 @@
- #define NETSNMP_DS_AGENT_CACHE_TIMEOUT 10 /* default cache timeout */
- #define NETSNMP_DS_AGENT_INTERNAL_VERSION 11 /* used by internal queries */
- #define NETSNMP_DS_AGENT_INTERNAL_SECLEVEL 12 /* used by internal queries */
-+#define NETSNMP_DS_AGENT_MAX_GETBULKREPEATS 13 /* max getbulk repeats */
-+#define NETSNMP_DS_AGENT_MAX_GETBULKRESPONSES 14 /* max getbulk respones */
-
- #endif
-Index: agent/agent_read_config.c
-===================================================================
---- agent/agent_read_config.c (revision 16338)
-+++ agent/agent_read_config.c (working copy)
-@@ -258,6 +258,12 @@
- netsnmp_ds_register_config(ASN_BOOLEAN, app, "dontLogTCPWrappersConnects",
- NETSNMP_DS_APPLICATION_ID,
- NETSNMP_DS_AGENT_DONT_LOG_TCPWRAPPERS_CONNECTS);
-+ netsnmp_ds_register_config(ASN_INTEGER, app, "maxGetbulkRepeats",
-+ NETSNMP_DS_APPLICATION_ID,
-+ NETSNMP_DS_AGENT_MAX_GETBULKREPEATS);
-+ netsnmp_ds_register_config(ASN_INTEGER, app, "maxGetbulkResponses",
-+ NETSNMP_DS_APPLICATION_ID,
-+ NETSNMP_DS_AGENT_MAX_GETBULKRESPONSES);
- netsnmp_init_handler_conf();
-
- #include "agent_module_dot_conf.h"
-Index: agent/snmp_agent.c
-===================================================================
---- agent/snmp_agent.c (revision 16338)
-+++ agent/snmp_agent.c (working copy)
-@@ -2156,7 +2156,6 @@
- * getbulk prep
- */
- int count = count_varbinds(asp->pdu->variables);
--
- if (asp->pdu->errstat < 0) {
- asp->pdu->errstat = 0;
- }
-@@ -2173,8 +2172,37 @@
- r = 0;
- asp->bulkcache = NULL;
- } else {
-+ int numresponses;
-+ int maxbulk =
-+ netsnmp_ds_get_int(NETSNMP_DS_APPLICATION_ID,
-+ NETSNMP_DS_AGENT_MAX_GETBULKREPEATS);
-+ int maxresponses =
-+ netsnmp_ds_get_int(NETSNMP_DS_APPLICATION_ID,
-+ NETSNMP_DS_AGENT_MAX_GETBULKRESPONSES);
-+
-+ if (maxresponses == 0)
-+ maxresponses = 100; /* more than reasonable default */
-+
-+ if (maxbulk == 0)
-+ maxbulk = -1;
-+
-+ /* limit getbulk number of repeats to a configured size */
-+ if (asp->pdu->errindex > maxbulk && maxbulk != -1) {
-+ asp->pdu->errindex = maxbulk;
-+ }
-+
-+ numresponses = asp->pdu->errindex * r;
-+
-+ /* limit getbulk number of getbulk responses to a configured size */
-+ if (maxresponses != -1 && numresponses > maxresponses) {
-+ /* attempt to truncate this */
-+ asp->pdu->errindex = maxresponses/r;
-+ numresponses = asp->pdu->errindex * r;
-+ DEBUGMSGTL(("snmp_agent", "truncating number of getbulk repeats to %d\n", asp->pdu->errindex));
-+ }
-+
- asp->bulkcache =
-- (netsnmp_variable_list **) malloc(asp->pdu->errindex * r *
-+ (netsnmp_variable_list **) malloc(numresponses *
- sizeof(struct
- varbind_list *));
- if (!asp->bulkcache) {
-@@ -2184,6 +2212,8 @@
- }
- DEBUGMSGTL(("snmp_agent", "GETBULK N = %d, M = %d, R = %d\n",
- n, asp->pdu->errindex, r));
-+ fprintf(stderr, "GETBULK N = %d, M = %d, R = %d\n",
-+ n, asp->pdu->errindex, r);
- }
-
- /*
diff --git a/net-analyzer/net-snmp/files/snmpd-5.1.conf b/net-analyzer/net-snmp/files/snmpd-5.1.conf
deleted file mode 100644
index 60e8a77e5aaf..000000000000
--- a/net-analyzer/net-snmp/files/snmpd-5.1.conf
+++ /dev/null
@@ -1,17 +0,0 @@
-# Copyright 1999-2004 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/net-snmp/files/snmpd-5.1.conf,v 1.3 2004/07/14 23:06:06 agriffis Exp $
-
-# Initial (empty) options.
-SNMPD_FLAGS=""
-
-# Enable connection logging.
-#SNMPD_FLAGS="${SNMPD_FLAGS} -a"
-
-# Enable syslog and disable file log.
-#SNMPD_FLAGS="${SNMPD_FLAGS} -Lsd -Lf /dev/null"
-
-# Enable agentx socket as /var/agentx/master
-# *NOTE* Before uncommenting this, make sure
-# the /var/agentx directory exists.
-#SNMPD_FLAGS="${SNMPD_FLAGS} -x /var/agentx/master"
diff --git a/net-analyzer/net-snmp/files/snmpd-5.1.rc6 b/net-analyzer/net-snmp/files/snmpd-5.1.rc6
deleted file mode 100644
index d4cd2306cc2f..000000000000
--- a/net-analyzer/net-snmp/files/snmpd-5.1.rc6
+++ /dev/null
@@ -1,30 +0,0 @@
-#!/sbin/runscript
-# Copyright 1999-2004 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/net-snmp/files/snmpd-5.1.rc6,v 1.3 2004/07/14 23:06:06 agriffis Exp $
-
-depend() {
- use logger
- need net
-}
-
-checkconfig() {
- if [ ! -e /etc/snmp/snmpd.conf ] ; then
- eerror "You need an /etc/snmp/snmpd.conf config file to run snmpd"
- return 1
- fi
-}
-
-start() {
- checkconfig || return 1
- ebegin "Starting net-snmpd"
- start-stop-daemon --start --quiet --exec /usr/sbin/snmpd \
- -- -p /var/run/snmpd.pid ${SNMPD_FLAGS}
- eend $?
-}
-
-stop() {
- ebegin "Stopping net-snmpd"
- start-stop-daemon --stop --quiet --pidfile /var/run/snmpd.pid
- eend $?
-}
diff --git a/net-analyzer/net-snmp/net-snmp-5.2.2-r3.ebuild b/net-analyzer/net-snmp/net-snmp-5.2.2-r3.ebuild
deleted file mode 100644
index ebfab6d5c373..000000000000
--- a/net-analyzer/net-snmp/net-snmp-5.2.2-r3.ebuild
+++ /dev/null
@@ -1,181 +0,0 @@
-# Copyright 1999-2007 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/net-snmp/net-snmp-5.2.2-r3.ebuild,v 1.3 2007/05/01 18:09:57 genone Exp $
-
-inherit eutils fixheadtails perl-module
-
-DESCRIPTION="Software for generating and retrieving SNMP data"
-HOMEPAGE="http://net-snmp.sourceforge.net/"
-SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
-
-LICENSE="as-is BSD"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
-IUSE="doc elf ipv6 lm_sensors mfd-rewrites minimal perl rpm selinux smux ssl tcpd X"
-
-DEPEND=">=sys-libs/zlib-1.1.4
- ssl? ( >=dev-libs/openssl-0.9.6d )
- tcpd? ( >=sys-apps/tcp-wrappers-7.6 )
- rpm? ( app-arch/rpm
- dev-libs/popt
- app-arch/bzip2
- )
- elf? ( dev-libs/elfutils )
- lm_sensors? ( sys-apps/lm_sensors )"
-
-RDEPEND="${DEPEND}
- perl? (
- X? ( dev-perl/perl-tk )
- !minimal? ( dev-perl/TermReadKey )
- )
- selinux? ( sec-policy/selinux-snmpd )"
-
-DEPEND="${DEPEND}
- >=sys-apps/sed-4
- doc? ( app-doc/doxygen )"
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
-
- epatch "${FILESDIR}"/${PN}-5.2.2-conf-elf-rpm-bz2.patch
-
-# The lm_sensors patch has a memory leak
-# If you can help, please attach a patch to bug 109785
-
-# if use lm_sensors; then
-# if use x86 || use amd64; then
-# epatch "${FILESDIR}"/${PN}-lm_sensors.patch
-# else
-# eerror "Unfortunatly you are trying to enable lm_sensors support for an unsupported arch."
-# eerror "please check the availability of sys-apps/lm_sensors - if it is available on"
-# eerror "your arch, please file a bug about this."
-# die "lm_sensors patch error: unsupported arch."
-# fi
-# fi
-
- # bug 118016
- epatch "${FILESDIR}"/${PN}-5.2.2-asneeded.patch
-
- # bugs 68467 and 68254
- sed -i -e 's;embed_perl="yes",;embed_perl=$enableval,;' configure.in \
- || die "sed configure.in failed"
- # Insecure run-path - bug 103776
- sed -i -e 's/\(@(cd perl ; $(MAKE)\)\() ; \\\)/\1 LD_RUN_PATH=\2/g' \
- Makefile.in || die "sed Makefile.in failed"
- # fix access violation in make check
- sed -i -e 's/\(snmpd.*\)-Lf/\1-l/' testing/eval_tools.sh || \
- die "sed eval_tools.sh failed"
- # fix path in fixproc
- sed -i -e 's|\(database_file =.*\)/local\(.*\)$|\1\2|' local/fixproc || \
- die "sed fixproc failed"
-
- ht_fix_all
-}
-
-src_compile() {
- local mibs
-
- autoconf || die "autoconf failed"
-
- mibs="host ucd-snmp/dlmod"
- use smux && mibs="${mibs} smux"
- use lm_sensors && mibs="${mibs} ucd-snmp/lmSensors"
-
- econf \
- --with-install-prefix="${D}" \
- --with-sys-location="Unknown" \
- --with-sys-contact="root@Unknown" \
- --with-default-snmp-version="3" \
- --with-mib-modules="${mibs}" \
- --with-logfile="/var/log/net-snmpd.log" \
- --with-persistent-directory="/var/lib/net-snmp" \
- --enable-ucd-snmp-compatibility \
- --enable-shared \
- --with-zlib \
- $(use_enable mfd-rewrites) \
- $(use_enable perl embedded-perl) \
- $(use_enable ipv6) \
- $(use_enable !ssl internal-md5) \
- $(use_with ssl openssl) \
- $(use_with tcpd libwrap) \
- $(use_with rpm) \
- $(use_with rpm bzip2) \
- $(use_with elf) \
- || die "econf failed"
-
- emake -j1 || die "emake failed"
-
- if use perl ; then
- emake perlmodules || die "compile perl modules problem"
- fi
-
- if use doc ; then
- einfo "Building HTML Documentation"
- make docsdox || die "failed to build docs"
- fi
-}
-
-src_test() {
- cd testing
- if ! make test ; then
- echo
- einfo "Don't be alarmed if a few tests FAIL."
- einfo "This could happen for several reasons:"
- einfo " - You don't already have a working configuration."
- einfo " - Your ethernet interface isn't properly configured."
- echo
- fi
-}
-
-src_install () {
- make DESTDIR="${D}" install || die "make install failed"
-
- if use perl ; then
- make DESTDIR="${D}" perlinstall || die "make perlinstall failed"
- fixlocalpod
-
- use X || rm -f "${D}/usr/bin/tkmib"
- else
- rm -f "${D}/usr/bin/mib2c" "${D}/usr/bin/tkmib"
- fi
-
- dodoc AGENT.txt ChangeLog FAQ INSTALL NEWS PORTING README* TODO
- newdoc EXAMPLE.conf.def EXAMPLE.conf
-
- use doc && dohtml docs/html/*
-
- keepdir /etc/snmp /var/lib/net-snmp
-
- newinitd "${FILESDIR}"/snmpd-5.1.rc6 snmpd || die
- newconfd "${FILESDIR}"/snmpd-5.1.conf snmpd || die
-
- # snmptrapd can use the same rc script just slightly modified
- sed -e 's/net-snmpd/snmptrapd/g' \
- -e 's/snmpd/snmptrapd/g' \
- -e 's/SNMPD/SNMPTRAPD/g' \
- "${D}"/etc/init.d/snmpd > "${D}"/etc/init.d/snmptrapd || \
- die "failed to create snmptrapd init script"
- chmod 0755 "${D}"/etc/init.d/snmptrapd
-
- newconfd "${FILESDIR}"/snmptrapd.conf snmptrapd || die
-
- # Remove everything, keeping only the snmpd, snmptrapd, MIBs, libs, and includes.
- if use minimal; then
- elog "USE=minimal is set. Cleaning up excess cruft for a embedded/minimal/server only install."
- rm -rf "${D}"/usr/bin/{encode_keychange,snmp{get,getnext,set,usm,walk,bulkwalk,table,trap,bulkget,translate,status,delta,test,df,vacm,netstat,inform}}
- rm -rf "${D}"/usr/share/snmp/snmpconf-data "${D}"/usr/share/snmp/*.conf
- rm -rf "${D}"/usr/bin/{fixproc,traptoemail} "${D}"/usr/bin/snmpc{heck,onf}
- find "${D}" -name '*.pl' -exec rm -f '{}' \;
- use ipv6 || rm -rf "${D}"/usr/share/snmp/mibs/IPV6*
- fi
-
- # bug 113788, install example config
- insinto /etc/snmp
- newins "${S}"/EXAMPLE.conf snmpd.conf.example
-}
-
-pkg_postinst() {
- elog "An example configuration file has been installed in"
- elog "/etc/snmp/snmpd.conf.example."
-}
diff --git a/net-analyzer/net-snmp/net-snmp-5.3.1-r1.ebuild b/net-analyzer/net-snmp/net-snmp-5.3.1-r1.ebuild
deleted file mode 100644
index 262d6262f4d2..000000000000
--- a/net-analyzer/net-snmp/net-snmp-5.3.1-r1.ebuild
+++ /dev/null
@@ -1,186 +0,0 @@
-# Copyright 1999-2007 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/net-snmp/net-snmp-5.3.1-r1.ebuild,v 1.4 2007/07/11 23:49:24 mr_bones_ Exp $
-
-inherit fixheadtails flag-o-matic perl-module
-
-DESCRIPTION="Software for generating and retrieving SNMP data"
-HOMEPAGE="http://net-snmp.sourceforge.net/"
-SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
-
-LICENSE="as-is BSD"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
-IUSE="diskio doc elf ipv6 lm_sensors mfd-rewrites minimal perl rpm selinux smux ssl tcpd X"
-
-DEPEND=">=sys-libs/zlib-1.1.4
- ssl? ( >=dev-libs/openssl-0.9.6d )
- tcpd? ( >=sys-apps/tcp-wrappers-7.6 )
- rpm? ( app-arch/rpm
- dev-libs/popt
- app-arch/bzip2
- )
- elf? ( dev-libs/elfutils )
- lm_sensors? ( sys-apps/lm_sensors )"
-
-RDEPEND="${DEPEND}
- perl? (
- X? ( dev-perl/perl-tk )
- !minimal? ( dev-perl/TermReadKey )
- )
- selinux? ( sec-policy/selinux-snmpd )"
-
-DEPEND="${DEPEND}
- >=sys-apps/sed-4
- doc? ( app-doc/doxygen )"
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
-
-# The lm_sensors patch has a memory leak
-# If you can help, please attach a patch to bug 109785
-
-# if use lm_sensors; then
-# if use x86 || use amd64; then
-# epatch "${FILESDIR}"/${PN}-lm_sensors.patch
-# else
-# eerror "Unfortunatly you are trying to enable lm_sensors support for an unsupported arch."
-# eerror "please check the availability of sys-apps/lm_sensors - if it is available on"
-# eerror "your arch, please file a bug about this."
-# die "lm_sensors patch error: unsupported arch."
-# fi
-# fi
-
-# RedHat Patches to generally fix x86_64 type issues
- epatch "${FILESDIR}"/${PN}-5.3.1-retrans-time.patch
- epatch "${FILESDIR}"/${PN}-5.3.1-tcp-udp-mib-byteorder.patch
-
- # bugs 68467 and 68254
- sed -i -e \
- 's/^NSC_AGENTLIBS="@AGENTLIBS@"/NSC_AGENTLIBS="@AGENTLIBS@ @WRAPLIBS@"/' \
- net-snmp-config.in || die "sed net-snmp-config.in"
- sed -i -e 's;embed_perl="yes",;embed_perl=$enableval,;' configure.in \
- || die "sed configure.in failed"
- # Insecure run-path - bug 103776
- sed -i -e 's/\(@(cd perl ; $(MAKE)\)\() ; \\\)/\1 LD_RUN_PATH=\2/g' \
- Makefile.in || die "sed Makefile.in failed"
- # fix access violation in make check
- sed -i -e 's/\(snmpd.*\)-Lf/\1-l/' testing/eval_tools.sh || \
- die "sed eval_tools.sh failed"
- # fix path in fixproc
- sed -i -e 's|\(database_file =.*\)/local\(.*\)$|\1\2|' local/fixproc || \
- die "sed fixproc failed"
-
- ht_fix_all
-}
-
-src_compile() {
- local mibs
-
- strip-flags
-
- autoconf || die "autoconf failed"
-
- mibs="host ucd-snmp/dlmod"
- use smux && mibs="${mibs} smux"
- use lm_sensors && mibs="${mibs} ucd-snmp/lmSensors"
- use diskio && mibs="${mibs} ucd-snmp/diskio"
-
- econf \
- --with-install-prefix="${D}" \
- --with-sys-location="Unknown" \
- --with-sys-contact="root@Unknown" \
- --with-default-snmp-version="3" \
- --with-mib-modules="${mibs}" \
- --with-logfile="/var/log/net-snmpd.log" \
- --with-persistent-directory="/var/lib/net-snmp" \
- --enable-ucd-snmp-compatibility \
- --enable-shared \
- --with-zlib \
- $(use_enable mfd-rewrites) \
- $(use_enable perl embedded-perl) \
- $(use_enable ipv6) \
- $(use_enable !ssl internal-md5) \
- $(use_with ssl openssl) \
- $(use_with tcpd libwrap) \
- $(use_with rpm) \
- $(use_with rpm bzip2) \
- $(use_with elf) \
- || die "econf failed"
-
- emake -j1 || die "emake failed"
-
- if use perl ; then
- emake perlmodules || die "compile perl modules problem"
- fi
-
- if use doc ; then
- einfo "Building HTML Documentation"
- make docsdox || die "failed to build docs"
- fi
-}
-
-src_test() {
- cd testing
- if ! make test ; then
- echo
- einfo "Don't be alarmed if a few tests FAIL."
- einfo "This could happen for several reasons:"
- einfo " - You don't already have a working configuration."
- einfo " - Your ethernet interface isn't properly configured."
- echo
- fi
-}
-
-src_install () {
- make DESTDIR="${D}" install || die "make install failed"
-
- if use perl ; then
- make DESTDIR="${D}" perlinstall || die "make perlinstall failed"
- fixlocalpod
-
- use X || rm -f "${D}/usr/bin/tkmib"
- else
- rm -f "${D}/usr/bin/mib2c" "${D}/usr/bin/tkmib"
- fi
-
- dodoc AGENT.txt ChangeLog FAQ INSTALL NEWS PORTING README* TODO
- newdoc EXAMPLE.conf.def EXAMPLE.conf
-
- use doc && dohtml docs/html/*
-
- keepdir /etc/snmp /var/lib/net-snmp
-
- newinitd "${FILESDIR}"/snmpd-5.1.rc6 snmpd || die
- newconfd "${FILESDIR}"/snmpd-5.1.conf snmpd || die
-
- # snmptrapd can use the same rc script just slightly modified
- sed -e 's/net-snmpd/snmptrapd/g' \
- -e 's/snmpd/snmptrapd/g' \
- -e 's/SNMPD/SNMPTRAPD/g' \
- "${D}"/etc/init.d/snmpd > "${D}"/etc/init.d/snmptrapd || \
- die "failed to create snmptrapd init script"
- chmod 0755 "${D}"/etc/init.d/snmptrapd
-
- newconfd "${FILESDIR}"/snmptrapd.conf snmptrapd || die
-
- # Remove everything, keeping only the snmpd, snmptrapd, MIBs, libs, and includes.
- if use minimal; then
- elog "USE=minimal is set. Cleaning up excess cruft for a embedded/minimal/server only install."
- rm -rf "${D}"/usr/bin/{encode_keychange,snmp{get,getnext,set,usm,walk,bulkwalk,table,trap,bulkget,translate,status,delta,test,df,vacm,netstat,inform}}
- rm -rf "${D}"/usr/share/snmp/snmpconf-data "${D}"/usr/share/snmp/*.conf
- rm -rf "${D}"/usr/bin/{fixproc,traptoemail} "${D}"/usr/bin/snmpc{heck,onf}
- find "${D}" -name '*.pl' -exec rm -f '{}' \;
- use ipv6 || rm -rf "${D}"/usr/share/snmp/mibs/IPV6*
- fi
-
- # bug 113788, install example config
- insinto /etc/snmp
- newins "${S}"/EXAMPLE.conf snmpd.conf.example
-}
-
-pkg_postinst() {
- elog "An example configuration file has been installed in"
- elog "/etc/snmp/snmpd.conf.example."
-}