summaryrefslogtreecommitdiffstats
path: root/source/n/net-snmp/net-snmp.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'source/n/net-snmp/net-snmp.SlackBuild')
-rwxr-xr-xsource/n/net-snmp/net-snmp.SlackBuild25
1 files changed, 13 insertions, 12 deletions
diff --git a/source/n/net-snmp/net-snmp.SlackBuild b/source/n/net-snmp/net-snmp.SlackBuild
index 3214d47d2..864fdd5a5 100755
--- a/source/n/net-snmp/net-snmp.SlackBuild
+++ b/source/n/net-snmp/net-snmp.SlackBuild
@@ -1,6 +1,6 @@
#!/bin/sh
-# Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2012 Patrick J. Volkerding, Sebeka, MN, USA
+# Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2014 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -23,12 +23,12 @@
PKGNAM=net-snmp
VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
-BUILD=${BUILD:-2}
+BUILD=${BUILD:-3}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
- i?86) export ARCH=i486 ;;
+ i?86) export ARCH=i586 ;;
arm*) export ARCH=arm ;;
# Unless $ARCH is already set, use uname -m for all other archs:
*) export ARCH=$( uname -m ) ;;
@@ -41,8 +41,8 @@ PKG=$TMP/package-${PKGNAM}
rm -rf $PKG
mkdir -p $TMP $PKG
-if [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "s390" ]; then
SLKCFLAGS="-O2"
@@ -70,6 +70,10 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
+# Fix destdir for python modules
+sed -i "s|\$(PYMAKE) install|\$(PYMAKE) install --root=$PKG|" \
+ Makefile.in
+
# Configure:
CFLAGS="$SLKCFLAGS" \
./configure \
@@ -90,12 +94,9 @@ CFLAGS="$SLKCFLAGS" \
--without-rpm \
--program-suffix= \
--program-prefix= \
- --with-mib-modules="ucd-snmp/lmsensorsMib" \
- --build=$ARCH-slackware-linux
-
-# This appears to require additional third-party python modules?
-# Maybe something for later.
-# --with-python-modules
+ --with-mib-modules="ucd-snmp/lmsensorsMib ucd-snmp/diskio" \
+ --with-python-modules \
+ --build=$ARCH-slackware-linux || exit 1
# Build and install:
# This seems to not play well with "-j N"...
@@ -111,7 +112,7 @@ fi
mkdir -p $PKG/usr
mv $PKG/usr/share/man $PKG/usr
-mkdir -p $PKG/var/lib/net-snmp
+mkdir -p $PKG/var/lib/net-snmp/{cert,mib}_indexes
mkdir -p $PKG/etc/snmp
zcat $CWD/snmpd.conf.gz > $PKG/etc/snmp/snmpd.conf.new
mkdir -p $PKG/etc/rc.d