network-ups-tools: optional CGI support

This commit is contained in:
Dominik Honnef 2015-06-28 05:01:35 +02:00
parent cb0f5e027d
commit 499327971e
1 changed files with 5 additions and 4 deletions

View File

@ -9,10 +9,10 @@ configure_args="
--datadir=/usr/share/ups --with-user=nut --with-group=nut --with-ssl --datadir=/usr/share/ups --with-user=nut --with-group=nut --with-ssl
--with-usb --without-dev --with-serial -with-avahi --with-udev-dir=/usr/lib/udev --with-usb --without-dev --with-serial -with-avahi --with-udev-dir=/usr/lib/udev
--without-libltdl --without-ipmi --without-freeipmi --without-systemdsystemunitdir --without-libltdl --without-ipmi --without-freeipmi --without-systemdsystemunitdir
--with-snmp --with-drvpath=/var/lib/nut" --with-snmp --with-drvpath=/var/lib/nut $(vopt_with cgi)"
hostmakedepends="pkg-config" hostmakedepends="pkg-config"
makedepends="avahi-libs-devel libressl-devel libusb-compat-devel neon-devel makedepends="avahi-libs-devel libressl-devel libusb-compat-devel neon-devel
net-snmp-devel" net-snmp-devel $(vopt_if cgi gd-devel)"
system_accounts="nut" system_accounts="nut"
conf_files=" conf_files="
/etc/ups/ups.conf /etc/ups/ups.conf
@ -28,9 +28,10 @@ homepage="http://www.networkupstools.org/"
distfiles="${homepage}source/${version%.*}/nut-${version}.tar.gz" distfiles="${homepage}source/${version%.*}/nut-${version}.tar.gz"
checksum=ff44d95d06a51559a0a018eef7f8d17911c1002b6352a7d7580ff75acb12126b checksum=ff44d95d06a51559a0a018eef7f8d17911c1002b6352a7d7580ff75acb12126b
build_options="cgi"
desc_option_cgi="Build and install the CGI programs"
post_install() { post_install() {
# remove unused stuff
rm -rf ${DESTDIR}/usr/{html,cgi-bin}
# Prepare configuration files # Prepare configuration files
for f in ups upsd upsmon upssched nut; do for f in ups upsd upsmon upssched nut; do
mv ${DESTDIR}/etc/ups/${f}.conf{.sample,} mv ${DESTDIR}/etc/ups/${f}.conf{.sample,}