initial import

This commit is contained in:
2025-06-22 20:39:04 -05:00
commit f8a70886f0
3428 changed files with 302546 additions and 0 deletions

79
net-snmp/PKGBUILD Normal file
View File

@@ -0,0 +1,79 @@
# Maintainer: Jesus E. <heckyel@riseup.net>
pkgname=net-snmp
pkgver=5.9.3
_debver=$pkgver
_debrel=2
pkgrel=2
pkgdesc="A suite of applications used to implement SNMP v1, SNMP v2c and SNMP v3 using both IPv4 and IPv6"
arch=('i686' 'x86_64')
url='http://www.net-snmp.org/'
license=('Expat' 'ISC' 'Modified-BSD')
depends=('libnsl' 'libpcap' 'pciutils' 'pcre')
makedepends=('python-setuptools' 'quilt')
optdepends=('perl-term-readkey: for snmpcheck application'
'perl-tk: for snmpcheck and tkmib applications'
'python: for the python modules'
'logger: message logging support')
options=('!emptydirs' '!makeflags')
source=(https://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.gz
https://deb.debian.org/debian/pool/main/n/net-snmp/net-snmp_${_debver}+dfsg-${_debrel}.debian.tar.xz
snmpd.initd
snmpd.confd
snmptrapd.initd
snmptrapd.confd)
sha512sums=('a476df4967029a2eb03d27b0e250170785d0a8c143d49b900ee958c3cbdfaccd415b70af40f6fbed9cb8819d522c35a6073a431091d908ccc7c018fa0aaa2abc'
'6fdefc9f42c55a23cfbb7066dda98eff78f0f918934489b5dcd182bac5bf5622168dd7b9349343cd77e7a9bb20138c0359d8991ac9cf20274c898db384b482fb'
'10394f04dee23537a195f5aed63a3e758ca90227e269076ae9d13f883c7bd666c1c43823d1b869c43f232e97dc4138e52648cae995327f7a7f676ba416ee6fff'
'e64f93631e5cb2160d3fb26abb84fc74f5632d8875227d5c8dfa24809b25e8202dcf23251ea8f296aedf16298c31ce49b8e64fb6325c18775d8899a50b853bbc'
'316964703559082b1626280bd0532a32533185741d1919f255473ae6bfe30f82b71bee79093cb0b341c99427e14a5ed201b6aa2886a9123c89d5f5f78496f706'
'283d1503ebca55046cc273f693a257be3e8e6f26b5db10a3b64a5455079a41568eb40c1a3f5dbc698b822502d5e8120ea80b9e2c3ac4aa1d830d318228c0beca')
prepare() {
cd ${pkgname}-${pkgver}
if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
# Debian patches
export QUILT_PATCHES=debian/patches
export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
export QUILT_DIFF_ARGS='--no-timestamps'
mv "$srcdir"/debian .
# Doesn't apply
rm -v debian/patches/26_kfreebsd.patch || true
rm -v debian/patches/27_kfreebsd.patch || true
quilt push -av
fi
autoreconf -vi
}
build() {
cd ${pkgname}-${pkgver}
./configure --prefix=/usr \
--sysconfdir=/etc \
--mandir=/usr/share/man \
--enable-ucd-snmp-compatibility \
--enable-ipv6 \
--with-python-modules \
--with-default-snmp-version="3" \
--with-sys-contact="root@localhost" \
--with-sys-location="Unknown" \
--with-logfile="/var/log/snmpd.log" \
--with-mib-modules="host misc/ipfwacc ucd-snmp/diskio tunnel ucd-snmp/dlmod" \
--with-persistent-directory="/var/net-snmp"
make NETSNMP_DONT_CHECK_VERSION=1
}
package() {
cd ${pkgname}-${pkgver}
sed -i -e "s:install --basedir=\$\$dir:install --basedir=\$\$dir --root=${pkgdir}:" Makefile
make DESTDIR="${pkgdir}" INSTALL_PREFIX="${pkgdir}" INSTALLDIRS=vendor install
install -D -m644 COPYING -t "${pkgdir}/usr/share/licenses/${pkgname}"
for f in snmpd snmptrapd; do
install -D -m644 "${srcdir}/$f.confd" "${pkgdir}/etc/conf.d/$f"
install -D -m755 "${srcdir}/$f.initd" "${pkgdir}/etc/init.d/$f"
done
}