aboutsummaryrefslogtreecommitdiffstats
path: root/main/apcupsd/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'main/apcupsd/APKBUILD')
-rw-r--r--main/apcupsd/APKBUILD22
1 files changed, 12 insertions, 10 deletions
diff --git a/main/apcupsd/APKBUILD b/main/apcupsd/APKBUILD
index d80f277015..e12e41f6d5 100644
--- a/main/apcupsd/APKBUILD
+++ b/main/apcupsd/APKBUILD
@@ -1,28 +1,30 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=apcupsd
pkgver=3.14.14
-pkgrel=0
+pkgrel=1
pkgdesc="A Daemon to control APC UPSes"
-subpackages="$pkgname-doc $pkgname-webif"
+subpackages="$pkgname-doc $pkgname-webif $pkgname-openrc"
url="http://www.apcupsd.org"
arch="all"
-license="GPL-2.0"
+license="GPL-2.0-only"
depends="util-linux"
-makedepends="net-snmp-dev man linux-headers gd-dev"
+makedepends="net-snmp-dev man linux-headers gd-dev libusb-compat-dev"
+options="!check" # no test suite included
source="https://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz
apcupsd.initd
apcupsd-alpine.patch
"
_builddir="$srcdir/$pkgname-$pkgver"
+
prepare() {
cd "$_builddir"
- update_config_sub || return 1
+ update_config_sub
+ default_prepare
}
build() {
cd "$_builddir"
- patch -p1 < ../apcupsd-alpine.patch || return 1
export CHARSET="ISO8859-1"
export LANG="C"
@@ -33,16 +35,16 @@ build() {
--host=$CHOST \
--prefix=/usr \
--mandir=/usr/share/man \
+ --enable-modbus-usb \
--enable-usb \
--enable-snmp \
- --enable-cgi \
- || return 1
- make || return 1
+ --enable-cgi
+ make
}
package() {
cd "$_builddir"
- make DESTDIR=$pkgdir install || return 1
+ make DESTDIR=$pkgdir install
install -D -m755 "$srcdir"/apcupsd.initd "$pkgdir"/etc/init.d/apcupsd
}