Last change
on this file was
c5c522c,
checked in by Edwin Eefting <edwin@datux.nl>, 8 years ago
|
initial commit, transferred from cleaned syn3 svn tree
|
-
Property mode set to
100755
|
File size:
1.3 KB
|
Rev | Line | |
---|
[c5c522c] | 1 | #!/bin/bash |
---|
| 2 | |
---|
| 3 | NAME=net_snmp |
---|
| 4 | VER=5.4.2.1 |
---|
| 5 | CWD=`pwd` |
---|
| 6 | PKGTMP=/tmp/pkgtmp |
---|
| 7 | TARNAME=net-snmp |
---|
| 8 | |
---|
| 9 | mkdir -p $PKGTMP &>/dev/null |
---|
| 10 | |
---|
| 11 | tar -xzf $TARNAME-$VER.tar.gz || exit 1 |
---|
| 12 | cd $TARNAME-$VER || exit 1 |
---|
| 13 | |
---|
| 14 | |
---|
| 15 | #HACK: deze header geeft parse errors, maar lijkt niet nodig te zijn? |
---|
| 16 | sed 's@#include <netinet/if_ether.h>@@' -i ./agent/mibgroup/mibII/at.c || exit 1 |
---|
| 17 | |
---|
| 18 | #niet? mibII/interfaces tunnel |
---|
| 19 | #extra dep: ucd-snmp/lmSensors |
---|
| 20 | ./configure --with-defaults \ |
---|
| 21 | --prefix=/usr \ |
---|
| 22 | --sysconfdir=/etc \ |
---|
| 23 | --with-mib-modules="host misc/ipfwacc misc/ipfwacc ip-mib/ipv4InterfaceTable ucd-snmp/diskio disman/event-mib ucd-snmp/extensible agent/extend" \ |
---|
| 24 | || exit 1 |
---|
| 25 | make -j1 || exit 1 |
---|
| 26 | #make test || exit 1 |
---|
| 27 | make -j1 INSTALL_PREFIX=$PKGTMP install || exit 1 |
---|
| 28 | |
---|
| 29 | cd $CWD |
---|
| 30 | mkdir -p $PKGTMP/etc |
---|
| 31 | cp snmpd.conf.new $PKGTMP/etc || exit 1 |
---|
| 32 | |
---|
| 33 | mkdir -p $PKGTMP/service/snmpd |
---|
| 34 | cp run $PKGTMP/service/snmpd || exit 1 |
---|
| 35 | chmod +x $PKGTMP/service/snmpd/run || exit 1 |
---|
| 36 | #by default don't run dhcpd |
---|
| 37 | touch $PKGTMP/service/snmpd/down |
---|
| 38 | |
---|
| 39 | #postinstall |
---|
| 40 | mkdir -p $PKGTMP/etc/postinst.d |
---|
| 41 | cp $CWD/post.net_snmpd $PKGTMP/etc/postinst.d |
---|
| 42 | chmod +x $PKGTMP/etc/postinst.d/post.net_snmpd |
---|
| 43 | #logrotate files |
---|
| 44 | mkdir -p $PKGTMP/etc/logrotate.d |
---|
| 45 | cp $CWD/snmpd.logrotate $PKGTMP/etc/logrotate.d/snmpd |
---|
| 46 | |
---|
| 47 | cd "$PKGTMP" || exit 1 |
---|
| 48 | makepkg -l y -c n $CWD/$NAME.pkg > /dev/null && |
---|
| 49 | echo $VER > $CWD/$NAME.version && |
---|
| 50 | arch > $CWD/$NAME.arch |
---|
| 51 | |
---|
Note: See
TracBrowser
for help on using the repository browser.