OSSP CVS Repository

ossp - Check-in [4661]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 4661
Date: 2004-Jul-30 11:30:04 (local)
2004-Jul-30 09:30:04 (UTC)
User:thl
Branch:
Comment: support a configurable OpenPKG instance
Tickets:
Inspections:
Files:
ossp-pkg/snmpdx/Makefile.in      1.12 -> 1.13     3 inserted, 0 deleted
ossp-pkg/snmpdx/README      1.14 -> 1.15     1 inserted, 0 deleted
ossp-pkg/snmpdx/configure.ac      1.5 -> 1.6     35 inserted, 3 deleted
ossp-pkg/snmpdx/devtool.conf      1.6 -> 1.7     3 inserted, 2 deleted
ossp-pkg/snmpdx/snmpdx.cfg.in      1.4 -> 1.5     4 inserted, 3 deleted
ossp-pkg/snmpdx/snmpdx.pl      1.14 -> 1.15     4 inserted, 1 deleted

ossp-pkg/snmpdx/Makefile.in 1.12 -> 1.13

--- Makefile.in  2003/09/19 10:33:14     1.12
+++ Makefile.in  2004/07/30 09:30:04     1.13
@@ -46,6 +46,7 @@
 datadir       = @datadir@
 localstatedir = @localstatedir@
 snmpmibdir    = @snmpmibdir@
+openpkg       = @openpkg@
 
 DESTDIR       =
 
@@ -65,6 +66,7 @@
                 -e "s;\@datadir\@;$(datadir);" \
                 -e "s;\@localstatedir\@;$(localstatedir);" \
                 -e "s;\@snmpmibdir\@;$(snmpmibdir);" \
+                -e "s;\@openpkg\@;$(openpkg);" \
                 <snmpdx.pl >snmpdx && \
                 chmod a+x snmpdx
 
@@ -75,6 +77,7 @@
                 -e 's;\@datadir\@;$(datadir);g' \
                 -e 's;\@localstatedir\@;$(localstatedir);g' \
                 -e "s;\@snmpmibdir\@;$(snmpmibdir);" \
+                -e "s;\@openpkg\@;$(openpkg);" \
                 <snmpdx.cfg.in >snmpdx.cfg
 
 snmpdx.8: snmpdx.pod


ossp-pkg/snmpdx/README 1.14 -> 1.15

--- README       2004/07/28 13:42:01     1.14
+++ README       2004/07/30 09:30:04     1.15
@@ -50,6 +50,7 @@
     $ ./devtool autogen #optional
     $ PREFIX=/openpkg-dev; ./configure \
         --prefix=$PREFIX \
+        --with-openpkg=$PREFIX \
         --with-snmp=$PREFIX \
         --with-perl=$PREFIX/bin/perl
     $ make


ossp-pkg/snmpdx/configure.ac 1.5 -> 1.6

--- configure.ac 2003/09/10 14:17:05     1.5
+++ configure.ac 2004/07/30 09:30:04     1.6
@@ -32,9 +32,41 @@
 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/>"
+echo "Copyright (c) 2003-2004 Ralf S. Engelschall <rse@engelschall.com>"
+echo "Copyright (c) 2003-2004 The OSSP Project <http://www.ossp.org/>"
+echo "Copyright (c) 2003-2004 Cable & Wireless <http://www.cw.com/>"
+
+dnl # check for OpenPKG
+AC_MSG_CHECKING(for openpkg instance)
+AC_ARG_WITH(openpkg,dnl
+[  --with-openpkg=PATH     force the use of a particular OpenPKG instance],
+with_openpkg="$withval",
+dnl # find any OpenPKG 2.x
+if test ".$with_openpkg" = .; then
+    for i in `cat </etc/openpkg` /openpkg; do
+        if test -x $i/bin/openpkg -a -x $i/libexec/openpkg/rpm; then
+            with_openpkg="$i"
+            break;
+        fi
+    done
+fi
+dnl # find any OpenPKG 1.x
+if test ".$with_openpkg" = .; then
+    for i in `cat </etc/openpkg` /cw; do
+        if test -x $i/bin/rpm -a ! -x $i/libexec/openpkg/rpm; then
+            with_openpkg="$i"
+            break;
+        fi
+    done
+fi
+dnl # take first configured
+if test ".$with_openpkg" = .; then
+    with_openpkg="`sed </etc/openpkg -n -e 1p`"
+fi
+)dnl
+openpkg="$with_openpkg"
+AC_SUBST(openpkg)
+AC_MSG_RESULT($openpkg)
 
 dnl # check for Perl
 AC_MSG_CHECKING(for perl program)


ossp-pkg/snmpdx/devtool.conf 1.6 -> 1.7

--- devtool.conf 2004/07/30 09:20:10     1.6
+++ devtool.conf 2004/07/30 09:30:04     1.7
@@ -13,8 +13,9 @@
 %configure
     ./configure \
         --prefix=/tmp/snmpdx \
-        --with-perl=/cw/bin/perl \
-        --with-snmp=/cw \
+        --with-openpkg=/openpkg \
+        --with-snmp=/openpkg \
+        --with-perl=/openpkg/bin/perl \
         "$@"
 
 %release


ossp-pkg/snmpdx/snmpdx.cfg.in 1.4 -> 1.5

--- snmpdx.cfg.in        2003/09/10 14:17:05     1.4
+++ snmpdx.cfg.in        2004/07/30 09:30:04     1.5
@@ -2,7 +2,8 @@
 ##  snmpdx.cfg -- configuration file for SNMP Daemon Extension
 ##
 
-mibdir    @datadir@/snmpdx:@snmpmibdir@
-probedir  @libexecdir@/snmpdx
-logfile   @localstatedir@/snmpdx/snmpdx.log
+mibdir    "@datadir@/snmpdx:@snmpmibdir@"
+probedir  "@libexecdir@/snmpdx"
+logfile   "@localstatedir@/snmpdx/snmpdx.log"
+openpkg   "@openpkg@"
 


ossp-pkg/snmpdx/snmpdx.pl 1.14 -> 1.15

--- snmpdx.pl    2004/07/30 09:27:21     1.14
+++ snmpdx.pl    2004/07/30 09:30:04     1.15
@@ -495,6 +495,7 @@
     'logfile'   => "@localstatedir@/snmpdx.log",
     'loglevel'  => 9,
     'strict'    => 0,
+    'openpkg'   => "@openpkg@",
 };
 
 #   command line parsing
@@ -514,6 +515,7 @@
     'l|logfile=s'   => \$opt->{'logfile'},
     'L|loglevel=i'  => \$opt->{'loglevel'},
     'S|strict'      => \$opt->{'strict'},
+    'O|openpkg'     => \$opt->{'openpkg'},
 );
 Getopt::Long::Configure("bundling");
 my $result = GetOptions(%options) || die "option parsing failed";
@@ -534,7 +536,8 @@
           " -m,--mibname=MIB    the name of the MIB to act under\n" .
           " -l,--logfile=PATH   path to daemon logfile\n" .
           " -L,--loglevel=NUM   logging level (0...9)\n" .
-          " -S,--strict         strict processing of unknown values\n";
+          " -S,--strict         strict processing of unknown values\n" .
+          " -O,--openpkg        OpenPKG instance to use for swOp, swBind\n";
     exit(0);
 }
 if ($opt->{'version'}) {

CVSTrac 2.0.1