system/apcupsd: Updated for version 3.14.8
This commit is contained in:
parent
99d16d6745
commit
c86d6b37a3
|
@ -13,6 +13,6 @@ the distribution-specific installation to prevent messing with files outside
|
||||||
DESTDIR; however, this does make it require some manual configuration after
|
DESTDIR; however, this does make it require some manual configuration after
|
||||||
installation.
|
installation.
|
||||||
|
|
||||||
After installing, see /usr/doc/apcupsd-3.14.5/README.SLACKWARE for more
|
After installing, see /usr/doc/apcupsd-3.14.8/README.SLACKWARE for more
|
||||||
information on how to modify rc.6 and how to start the apcupsd daemon
|
information on how to modify rc.6 and how to start the apcupsd daemon
|
||||||
automatically at boot.
|
automatically at boot.
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
# Slackware build script for apcupsd
|
# Slackware build script for apcupsd
|
||||||
|
|
||||||
# Copyright 2006-2009 Robby Workman Northport, AL, USA
|
# Copyright 2006-2010 Robby Workman Northport, AL, USA
|
||||||
# All rights reserved.
|
# All rights reserved.
|
||||||
#
|
#
|
||||||
# Redistribution and use of this script, with or without modification, is
|
# Redistribution and use of this script, with or without modification, is
|
||||||
|
@ -26,7 +26,7 @@
|
||||||
# * added log rotation
|
# * added log rotation
|
||||||
|
|
||||||
PRGNAM=apcupsd
|
PRGNAM=apcupsd
|
||||||
VERSION=3.14.5
|
VERSION=3.14.8
|
||||||
ARCH=${ARCH:-i486}
|
ARCH=${ARCH:-i486}
|
||||||
BUILD=${BUILD:-1}
|
BUILD=${BUILD:-1}
|
||||||
TAG=${TAG:-_SBo}
|
TAG=${TAG:-_SBo}
|
||||||
|
@ -46,10 +46,13 @@ UPSCABLE=${UPSCABLE:-usb} # Cable type (RJ45<-->USB == USB)
|
||||||
|
|
||||||
if [ "$ARCH" = "i486" ]; then
|
if [ "$ARCH" = "i486" ]; then
|
||||||
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
|
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
|
||||||
|
LIBDIRSUFFIX=""
|
||||||
elif [ "$ARCH" = "i686" ]; then
|
elif [ "$ARCH" = "i686" ]; then
|
||||||
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
|
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
|
||||||
|
LIBDIRSUFFIX=""
|
||||||
elif [ "$ARCH" = "x86_64" ]; then
|
elif [ "$ARCH" = "x86_64" ]; then
|
||||||
SLKCFLAGS="-O2 -fPIC"
|
SLKCFLAGS="-O2 -fPIC"
|
||||||
|
LIBDIRSUFFIX="64"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
@ -63,16 +66,21 @@ cd $PRGNAM-$VERSION
|
||||||
chown -R root:root .
|
chown -R root:root .
|
||||||
chmod -R a-s,u+w,go+r-w .
|
chmod -R a-s,u+w,go+r-w .
|
||||||
|
|
||||||
# The "--disable-install-distdir" is important - don't remove it
|
# The "--disable-install-distdir" is important - don't remove it.
|
||||||
# If you enable the distribution-specific install, then apcupsd will attempt
|
# If you enable the distribution-specific install, then apcupsd will attempt
|
||||||
# to patch the /etc/rc.d/rc.6 script on your system. This may be acceptable
|
# to patch the /etc/rc.d/rc.6 script on your system. This may be acceptable
|
||||||
# from a single-user standpoint, but for packagers, it's not worth a crap.
|
# from a single-user standpoint, but for packagers, it's not worth a crap.
|
||||||
# If I'd wanted the Makefile tampering with things outside DESTDIR, I wouldn't
|
# If I'd wanted the Makefile tampering with things outside DESTDIR, I wouldn't
|
||||||
# have used the DESTDIR flag - why is this so difficult to comprehend?
|
# have used the DESTDIR flag - why is this so difficult to comprehend?
|
||||||
CFLAGS="$SLKCFLAGS" \
|
#
|
||||||
CXXFLAGS="$SLKCFLAGS" \
|
# Don't use legacy defines in the netsnmp headers
|
||||||
|
# http://www.linuxquestions.org/questions/slackware-14/cannot-build-apcups-on-slack64-current-775065/
|
||||||
|
#
|
||||||
|
CFLAGS="$SLKCFLAGS -DNETSNMP_NO_LEGACY_DEFINITIONS=1" \
|
||||||
|
CXXFLAGS="$SLKCFLAGS -DNETSNMP_NO_LEGACY_DEFINITIONS=1" \
|
||||||
./configure \
|
./configure \
|
||||||
--prefix=/usr \
|
--prefix=/usr \
|
||||||
|
--libdir=/usr/lib${LIBDIRSUFFIX} \
|
||||||
--sbindir=/sbin \
|
--sbindir=/sbin \
|
||||||
--mandir=/usr/man \
|
--mandir=/usr/man \
|
||||||
--localstatedir=/var \
|
--localstatedir=/var \
|
||||||
|
@ -95,7 +103,7 @@ make install DESTDIR=$PKG
|
||||||
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \
|
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | \
|
||||||
xargs strip --strip-unneeded 2> /dev/null || true
|
xargs strip --strip-unneeded 2> /dev/null || true
|
||||||
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \
|
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | \
|
||||||
xargs strip --strip-unneeded 2> /dev/null
|
xargs strip --strip-unneeded 2> /dev/null || true
|
||||||
)
|
)
|
||||||
|
|
||||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||||
|
@ -108,9 +116,6 @@ find $PKG/usr/doc/$PRGNAM-$VERSION -name "Makefile*" -exec rm {} \;
|
||||||
find $PKG/usr/doc/$PRGNAM-$VERSION -name "*.man" -exec rm {} \;
|
find $PKG/usr/doc/$PRGNAM-$VERSION -name "*.man" -exec rm {} \;
|
||||||
chown -R root:root $PKG/usr/doc
|
chown -R root:root $PKG/usr/doc
|
||||||
|
|
||||||
# Install the apctest man page - it's not done automatically for some reason
|
|
||||||
install -m 0644 doc/apctest.man $PKG/usr/man/man8/apctest.8
|
|
||||||
|
|
||||||
# Install the apcupsd init script
|
# Install the apcupsd init script
|
||||||
install -D -m 0755 platforms/slackware/apcupsd \
|
install -D -m 0755 platforms/slackware/apcupsd \
|
||||||
$PKG/etc/rc.d/rc.apcupsd.new
|
$PKG/etc/rc.d/rc.apcupsd.new
|
||||||
|
@ -139,4 +144,4 @@ sed s/@VERSION@/$VERSION/ $CWD/slack-desc > $PKG/install/slack-desc
|
||||||
cat $CWD/doinst.sh > $PKG/install/doinst.sh
|
cat $CWD/doinst.sh > $PKG/install/doinst.sh
|
||||||
|
|
||||||
cd $PKG
|
cd $PKG
|
||||||
/sbin/makepkg -l y -c n -p $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
|
/sbin/makepkg -l y -c n -p $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
|
||||||
|
|
|
@ -1,8 +1,10 @@
|
||||||
PRGNAM="apcupsd"
|
PRGNAM="apcupsd"
|
||||||
VERSION="3.14.5"
|
VERSION="3.14.8"
|
||||||
HOMEPAGE="http://www.apcupsd.org"
|
HOMEPAGE="http://www.apcupsd.org"
|
||||||
DOWNLOAD="http://downloads.sourceforge.net/apcupsd/apcupsd-3.14.5.tar.gz"
|
DOWNLOAD="http://downloads.sourceforge.net/apcupsd/apcupsd-3.14.8.tar.gz"
|
||||||
MD5SUM="4ac73ec91d8ab56f3fac894e172567c4"
|
MD5SUM="cd17f0a903dc2220e55ed54e242359d2"
|
||||||
|
DOWNLOAD_x86_64=""
|
||||||
|
MD5SUM_x86_64=""
|
||||||
MAINTAINER="Robby Workman"
|
MAINTAINER="Robby Workman"
|
||||||
EMAIL="rw@rlworkman.net"
|
EMAIL="rw@rlworkman.net"
|
||||||
APPROVED="dsomero"
|
APPROVED="Erik Hanson"
|
||||||
|
|
Loading…
Reference in New Issue