mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-16 19:50:19 +01:00
network/radvd: Updated for version 2.8.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
parent
43126a6327
commit
d3e1cdea70
4 changed files with 33 additions and 26 deletions
|
@ -18,13 +18,16 @@ if [ -e etc/rc.d/rc.radvd ]; then
|
|||
mv etc/rc.d/rc.radvd.new.incoming etc/rc.d/rc.radvd.new
|
||||
fi
|
||||
|
||||
# Keep same perms on radvd.conf.new:
|
||||
if [ -e etc/radvd.conf ]; then
|
||||
cp -a etc/radvd.conf etc/radvd.conf.new.incoming
|
||||
cat etc/radvd.conf.new > etc/radvd.conf.new.incoming
|
||||
mv etc/radvd.conf.new.incoming etc/radvd.conf.new
|
||||
config etc/rc.d/rc.radvd.new
|
||||
|
||||
if ! grep rc.radvd etc/rc.d/rc.local > /dev/null
|
||||
then
|
||||
cat >> etc/rc.d/rc.local <<EOF
|
||||
|
||||
# Start radvd
|
||||
if [ -x /etc/rc.d/rc.radvd ]; then
|
||||
. /etc/rc.d/rc.radvd start
|
||||
fi
|
||||
|
||||
config etc/rc.d/rc.radvd.new
|
||||
config etc/radvd.conf.new
|
||||
|
||||
EOF
|
||||
fi
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
PRGNAM=radvd
|
||||
VERSION=1.15
|
||||
VERSION=${VERSION:-2.8}
|
||||
BUILD=${BUILD:-1}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
||||
|
@ -67,15 +67,16 @@ find -L . \
|
|||
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
|
||||
-o -perm 511 \) -exec chmod 755 {} \; -o \
|
||||
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
|
||||
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
|
||||
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
|
||||
|
||||
CFLAGS="$SLKCFLAGS" \
|
||||
CXXFLAGS="$SLKCFLAGS" \
|
||||
./configure \
|
||||
--prefix=/usr \
|
||||
--mandir=/usr/man \
|
||||
--docdir=/usr/doc/$PRGNAM-$VERSION \
|
||||
--libdir=/usr/lib${LIBDIRSUFFIX} \
|
||||
--sysconfdir=/etc \
|
||||
--localstatedir=/var \
|
||||
--docdir=/usr/doc/radvd-$VERSION \
|
||||
--with-configfile=/etc/radvd.conf \
|
||||
--with-pidfile=/var/run/radvd/radvd.pid \
|
||||
--build=$ARCH-slackware-linux
|
||||
|
@ -90,15 +91,20 @@ make install DESTDIR=$PKG
|
|||
xargs strip --strip-debug 2> /dev/null || true
|
||||
)
|
||||
|
||||
find $PKG/usr/man -type f -exec gzip -9 {} \;
|
||||
mv $PKG/usr/share/man $PKG/usr/man
|
||||
( cd $PKG/usr/man
|
||||
find . -type f -exec gzip -9 {} \;
|
||||
)
|
||||
|
||||
mkdir -p $PKG/etc/rc.d
|
||||
install -D -m 0644 $CWD/rc.radvd.new $PKG/etc/rc.d/rc.radvd.new
|
||||
mv $TMP/$PRGNAM-$VERSION/radvd.conf.example $PKG/etc/radvd.conf.new
|
||||
install -D -m 0644 $CWD/rc.radvd.new $PKG/etc/rc.d
|
||||
install -D -m 0644 $TMP/$PRGNAM-$VERSION/radvd.conf.example $PKG/etc
|
||||
|
||||
mkdir -p $PKG/var/run/radvd
|
||||
chown -R daemon:daemon $PKG/var/run/radvd
|
||||
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a CHANGES-1 COPYRIGHT INTRO.html README TODO \
|
||||
$PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a CHANGES COPYRIGHT INTRO.html README TODO $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
|
||||
|
||||
mkdir -p $PKG/install
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
PRGNAM="radvd"
|
||||
VERSION="1.15"
|
||||
VERSION="2.8"
|
||||
HOMEPAGE="http://www.litech.org/radvd"
|
||||
DOWNLOAD="http://www.litech.org/radvd/dist/radvd-1.15.tar.xz"
|
||||
MD5SUM="d1aded1d13e0c53d5be65193c4378974"
|
||||
DOWNLOAD="http://www.litech.org/radvd/dist/radvd-2.8.tar.xz"
|
||||
MD5SUM="67b8662d422f15014bb4d1e42e8b8c7f"
|
||||
DOWNLOAD_x86_64=""
|
||||
MD5SUM_x86_64=""
|
||||
REQUIRES="libdaemon"
|
||||
REQUIRES="check"
|
||||
MAINTAINER="Leigh Wedding"
|
||||
EMAIL="leigh8904@gmail.com"
|
||||
|
|
|
@ -5,22 +5,20 @@
|
|||
# Start/stop/restart the radvd daemon.
|
||||
|
||||
if ! [ -f /proc/net/if_inet6 ]; then
|
||||
echo "IPv6 support not found; exiting..."
|
||||
echo "IPv6 support not found, exiting"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
radvd_start() {
|
||||
if [ -x /usr/sbin/radvd ]; then
|
||||
echo "Starting radvd: /usr/sbin/radvd -u daemon"
|
||||
echo "Starting radvd..."
|
||||
echo 1 > /proc/sys/net/ipv6/conf/all/forwarding
|
||||
mkdir -p /var/run/radvd
|
||||
chown daemon:daemon /var/run/radvd
|
||||
/usr/sbin/radvd -u daemon
|
||||
fi
|
||||
}
|
||||
|
||||
radvd_stop() {
|
||||
/bin/kill $(cat /var/run/radvd/radvd.pid 2>/dev/null) 2>/dev/null
|
||||
/bin/kill $(cat /var/run/radvd/radvd.pid)
|
||||
}
|
||||
|
||||
radvd_restart() {
|
||||
|
|
Loading…
Reference in a new issue