Commit 23274e33 authored by Natanael Copa's avatar Natanael Copa

extra/opennhrp: new aport

NBMA Next Hop Resolution Protocol daemon
http://sourceforge.net/projects/opennhrp
parent af54c832
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=opennhrp
pkgver=0.9.2
pkgrel=0
pkgdesc="NBMA Next Hop Resolution Protocol daemon"
url="http://sourceforge.net/projects/opennhrp"
license="GPL-3"
depends="uclibc"
subpackages="$pkgname-doc"
source="http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.bz2
$pkgname-$pkgver-cflags.patch
$pkgname-$pkgver-fix-false-assert.patch
$pkgname.initd
$pkgname.confd
"
build() {
cd "$srcdir"/$pkgname-$pkgver
for i in ../*.patch; do
msg "Applying $i"
patch -p1 < $i || return 1
done
make || return 1
make DESTDIR="$pkgdir" install
install -Dm755 "$srcdir"/opennhrp.initd "$pkgdir"/etc/init.d/opennhrp
install -Dm644 "$srcdir"/opennhrp.confd "$pkgdir"/etc/cond.d/opennhrp
}
md5sums="71a017151292461aaee572c908ac9ac7 opennhrp-0.9.2.tar.bz2"
--- opennhrp-0.9.2/Makefile.orig Tue Feb 3 14:51:18 2009
+++ opennhrp-0.9.2/Makefile Tue Feb 3 14:51:07 2009
@@ -22,9 +22,9 @@
INSTALL=install
INSTALLDIR=$(INSTALL) -d
-CFLAGS=-Werror -Wall -Wstrict-prototypes -std=gnu99 -O2 \
- -DOPENNHRP_VERSION=\"$(FULL_VERSION)\"
-LDFLAGS=
+CFLAGS?=-Werror -Wall -Wstrict-prototypes -O2
+CFLAGS+=-std=gnu99 -DOPENNHRP_VERSION=\"$(FULL_VERSION)\"
+LDFLAGS?=
DESTDIR=
SBINDIR=/usr/sbin
diff -ru opennhrp-0.9.2.orig/nhrp/nhrp_peer.c opennhrp-0.9.2/nhrp/nhrp_peer.c
--- opennhrp-0.9.2.orig/nhrp/nhrp_peer.c 2009-02-02 13:12:46 +0000
+++ opennhrp-0.9.2/nhrp/nhrp_peer.c 2009-02-02 13:36:51 +0000
@@ -1260,7 +1260,8 @@
{
char tmp[NHRP_PEER_FORMAT_LEN];
- NHRP_BUG_ON(peer->flags & NHRP_PEER_FLAG_REMOVED);
+ if (peer->flags & NHRP_PEER_FLAG_REMOVED)
+ return;
nhrp_debug("Removing %s %s",
nhrp_peer_type[peer->type],
# Uncomment the row below to enable verbose logging.
#OPENNHRP_OPTS=-v
#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-analyzer/net-snmp/files/snmpd.rc7,v 1.1 2006/11/26 21:37:22 cedk Exp $
PIDFILE=/var/run/opennhrp.pid
depend() {
use logger
need net
}
checkconfig() {
if [ ! -e /etc/opennhrp/opennhrp.conf ] ; then
eerror "You need an /etc/opennhrp/opennhrp.conf config file to run opennhrp"
return 1
fi
}
start() {
checkconfig || return 1
ebegin "Starting opennhrp"
start-stop-daemon --start --quiet --pidfile $PIDFILE \
--exec /usr/sbin/opennhrp -- -d -p $PIDFILE 2> /dev/null
eend $?
}
stop() {
ebegin "Stopping opennhrp"
start-stop-daemon --stop --quiet --pidfile $PIDFILE
eend $?
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment