Check-in Number:
|
3602 | |
Date: |
2003-Sep-10 16:17:05 (local)
2003-Sep-10 14:17:05 (UTC) |
User: | rse |
Branch: | |
Comment: |
Add Autoconf option --with-snmp=PREFIX for specifying
installation prefix of net-snmp package in order to
find the net-snmp MIB directory. |
Tickets: |
|
Inspections: |
|
Files: |
|
ossp-pkg/snmpdx/00TODO 1.13 -> 1.14
--- 00TODO 2003/09/10 13:54:33 1.13
+++ 00TODO 2003/09/10 14:17:05 1.14
@@ -9,8 +9,6 @@
TODO
====
- - snmp mibs dir was lost
- - we should add --with-snmp
- implement more probes [thl]
- write snmpdx.pod documentation
|
|
ossp-pkg/snmpdx/ChangeLog 1.9 -> 1.10
--- ChangeLog 2003/09/10 13:57:30 1.9
+++ ChangeLog 2003/09/10 14:17:05 1.10
@@ -10,6 +10,11 @@
Changes between 0.2.5 and 0.2.6 (10-Sep-2003 to 10-Sep-2003):
+ *) Add Autoconf option --with-snmp=PREFIX for specifying
+ installation prefix of net-snmp package in order to
+ find the net-snmp MIB directory.
+ [Ralf S. Engelschall]
+
*) Place executable "snmpdx" into sbindir/ and man/man8/
[Ralf S. Engelschall]
|
|
ossp-pkg/snmpdx/Makefile.in 1.9 -> 1.10
--- Makefile.in 2003/09/10 13:57:30 1.9
+++ Makefile.in 2003/09/10 14:17:05 1.10
@@ -46,6 +46,7 @@
mandir = @mandir@
datadir = @datadir@
localstatedir = @localstatedir@
+snmpmibdir = @snmpmibdir@
DESTDIR =
@@ -63,6 +64,7 @@
-e "s;\@libexecdir\@;$(libexecdir);" \
-e "s;\@datadir\@;$(datadir);" \
-e "s;\@localstatedir\@;$(localstatedir);" \
+ -e "s;\@snmpmibdir\@;$(snmpmibdir);" \
<snmpdx.pl >snmpdx && \
chmod a+x snmpdx
@@ -72,6 +74,7 @@
-e 's;\@libexecdir\@;$(libexecdir);g' \
-e 's;\@datadir\@;$(datadir);g' \
-e 's;\@localstatedir\@;$(localstatedir);g' \
+ -e "s;\@snmpmibdir\@;$(snmpmibdir);" \
<snmpdx.cfg.in >snmpdx.cfg
snmpdx.8: snmpdx.pod
|
|
ossp-pkg/snmpdx/configure.ac 1.4 -> 1.5
--- configure.ac 2003/09/10 13:54:33 1.4
+++ configure.ac 2003/09/10 14:17:05 1.5
@@ -25,16 +25,19 @@
## configure.ac: auto-configuration source (syntax: Autoconf)
##
+dnl # standard Autoconf prolog
AC_PREREQ(2.53)
AC_INIT
+dnl # standard OSSP style header
V=`./shtool version -ltxt -dlong VERSION`
./shtool echo -e "Configuring %BOSSP snmpdx%b, Version %B${V}%b"
echo "Copyright (c) 2003 Ralf S. Engelschall <rse@engelschall.com>"
echo "Copyright (c) 2003 The OSSP Project <http://www.ossp.org/>"
echo "Copyright (c) 2003 Cable & Wireless <http://www.cw.com/>"
-AC_MSG_CHECKING(for Perl program)
+dnl # check for Perl
+AC_MSG_CHECKING(for perl program)
AC_ARG_WITH(perl,dnl
[ --with-perl=PATH force the use of a particular Perl program],
with_perl="$withval",
@@ -48,8 +51,33 @@
PATH_POD2MAN=`echo "$PATH_PERL" | sed -e 's;/[[^/]]*$;/pod2man;'`
AC_SUBST(PATH_POD2MAN)
+dnl # check for net-snmp
+AC_MSG_CHECKING(for net-snmp prefix)
+AC_ARG_WITH(snmp,dnl
+[ --with-snmp=PREFIX force the use of a particular net-snmp installation],
+snmp_prefix="$withval",
+if test ".$snmp_prefix" = .; then
+ snmp_prefix=`(net-snmp-config --prefix) 2>/dev/null`
+fi
+)dnl
+if test ".$snmp_prefix" = .; then
+ AC_MSG_ERROR([path to net-snmp package not found (specify with --with-snmp=PREFIX])
+fi
+snmp_mibdir=`find $snmp_prefix/share/ -type d -name "mibs" -print 2>/dev/null | head -1 | sed -e 's;//*;/;g'`
+if test ".$snmp_mibdir" = .; then
+ snmp_mibdir=`find $snmp_prefix/ -type d -name "mibs" -print 2>/dev/null | head -1 | sed -e 's;//*;/;g'`
+fi
+if test ".$snmp_mibdir" = .; then
+ AC_MSG_ERROR([net-snmp MIB directory not found under $snmp_prefix])
+fi
+snmpmibdir="$snmp_mibdir"
+AC_SUBST(snmpmibdir)
+AC_MSG_RESULT($snmpmibdir)
+
+dnl # check for make(1)
AC_SET_MAKE
+dnl # standard Autoconf epilog
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
|
|
ossp-pkg/snmpdx/devtool.conf 1.3 -> 1.4
--- devtool.conf 2003/09/10 13:30:47 1.3
+++ devtool.conf 2003/09/10 14:17:05 1.4
@@ -13,6 +13,8 @@
%configure
./configure \
--prefix=/tmp/snmpdx \
+ --with-perl=/cw/bin/perl \
+ --with-snmp=/cw \
"$@"
%release
|
|
ossp-pkg/snmpdx/snmpdx.cfg.in 1.3 -> 1.4
--- snmpdx.cfg.in 2003/09/10 13:35:15 1.3
+++ snmpdx.cfg.in 2003/09/10 14:17:05 1.4
@@ -2,7 +2,7 @@
## snmpdx.cfg -- configuration file for SNMP Daemon Extension
##
-mibdir @datadir@/snmpdx:@datadir@/snmp/mibs
+mibdir @datadir@/snmpdx:@snmpmibdir@
probedir @libexecdir@/snmpdx
logfile @localstatedir@/snmpdx/snmpdx.log
|
|
ossp-pkg/snmpdx/snmpdx.pl 1.6 -> 1.7
--- snmpdx.pl 2003/09/10 13:35:15 1.6
+++ snmpdx.pl 2003/09/10 14:17:05 1.7
@@ -487,7 +487,7 @@
'bindir' => "/cw/bin",
'probedir' => "@libexecdir@/snmpdx",
'probename' => "*",
- 'mibdir' => "@datadir@/snmpdx", # FIXME
+ 'mibdir' => "@datadir@/snmpdx:@snmpmibdir@",
'mibname' => "snmpdx",
'logfile' => "@localstatedir@/snmpdx.log",
'loglevel' => 9,
|
|