diff options
author | Nicolas Thill <nico@openwrt.org> | 2005-12-14 23:01:47 +0000 |
---|---|---|
committer | Nicolas Thill <nico@openwrt.org> | 2005-12-14 23:01:47 +0000 |
commit | 7ec285553efbb64a077be097330a20a7079b387d (patch) | |
tree | 1802064dc5e232bf2a6d31e15e3230af1d1bad2b /openwrt/package/vrrpd/files | |
parent | c7221546a12bc52a3730f15918bfb0acf81b3cf1 (diff) | |
download | mtk-20170518-7ec285553efbb64a077be097330a20a7079b387d.zip mtk-20170518-7ec285553efbb64a077be097330a20a7079b387d.tar.gz mtk-20170518-7ec285553efbb64a077be097330a20a7079b387d.tar.bz2 |
fix package name in template call, remove unneeded patch, don't use PKG_INSTALL_DIR since upstream does not provide a make install target, add configurable init script, add Id tag and target optimization cflags..
SVN-Revision: 2674
Diffstat (limited to 'openwrt/package/vrrpd/files')
-rw-r--r-- | openwrt/package/vrrpd/files/vrrpd.default | 4 | ||||
-rw-r--r-- | openwrt/package/vrrpd/files/vrrpd.init | 21 |
2 files changed, 25 insertions, 0 deletions
diff --git a/openwrt/package/vrrpd/files/vrrpd.default b/openwrt/package/vrrpd/files/vrrpd.default new file mode 100644 index 0000000..0dfee0c --- /dev/null +++ b/openwrt/package/vrrpd/files/vrrpd.default @@ -0,0 +1,4 @@ +ID=1 +IF=vlan1 +IP=10.0.0.1 +OPTIONS="-i $IF -v $ID $IP" diff --git a/openwrt/package/vrrpd/files/vrrpd.init b/openwrt/package/vrrpd/files/vrrpd.init new file mode 100644 index 0000000..5afc734 --- /dev/null +++ b/openwrt/package/vrrpd/files/vrrpd.init @@ -0,0 +1,21 @@ +#!/bin/sh + +BIN=vrrpd +DEFAULT=/etc/default/$BIN +[ -f $DEFAULT ] && . $DEFAULT +RUN_D=/var/run +PID_F=$RUN_D/$BIN_${IF}_${ID}.pid + +case $1 in + start) + $BIN $OPTIONS + ;; + stop) + [ -f $PID_F ] && kill $(cat $PID_F) >/dev/null 2>&1 + ;; + *) + echo "usage: $0 (start|stop)" + exit 1 +esac + +exit $? |