# Maintainer: Natanael Copa pkgname=quagga pkgver=0.99.22.1 pkgrel=1 pkgdesc="A free routing daemon replacing Zebra supporting RIP, OSPF and BGP." url="http://quagga.net/" arch="all" license="GPL-2" depends="iproute2" makedepends="readline-dev ncurses-dev gawk texinfo perl net-snmp-dev" install="$pkgname.pre-install $pkgname.post-install $pkgname.post-upgrade" subpackages="$pkgname-dev $pkgname-doc" pkgusers="quagga" pkggroups="quagga" source="http://download.savannah.gnu.org/releases/quagga/quagga-$pkgver.tar.xz $pkgname-0.99.11-del-routes.patch quagga-0.99.16-ipctl_forwarding.patch bgpd.initd ospf6d.initd ospfd.initd ripd.initd ripngd.initd zebra.initd zebra.confd " _builddir="$srcdir"/$pkgname-$pkgver prepare() { cd "$_builddir" for i in i$source; do case $i in *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; esac done } build() { cd "$_builddir" ./configure \ --build=$CBUILD \ --host=$CHOST \ --prefix=/usr \ --disable-static \ --enable-ipv6 \ --enable-ospf6d \ --enable-rtadv \ --enable-user=quagga \ --enable-group=quagga \ --enable-vty-group=quagga \ --enable-vtysh \ --enable-snmp \ --enable-multipath=64 \ --sysconfdir=/etc/quagga \ --enable-exampledir=/usr/share/doc/quagga/ \ --localstatedir=/var/run/quagga \ || return 1 # add CFLAGS to work around textrel issue make CFLAGS+="-fPIC" || return 1 } package() { cd "$_builddir" make DESTDIR="$pkgdir" install || return 1 rm "$pkgdir"/usr/lib/*.la || return 1 install -o quagga -g quagga -d "$pkgdir"/var/run/quagga for i in zebra ripd ospfd bgpd ripngd ospf6d; do install -Dm755 "$srcdir"/$i.initd "$pkgdir"/etc/init.d/$i done install -Dm644 "$srcdir/zebra.confd" "$pkgdir"/etc/conf.d/zebra install -d -m755 "$pkgdir"/etc/quagga } md5sums="94962234ba1e35426e168e60726567ce quagga-0.99.22.1.tar.xz 1cbcf60a637b2577dee4d6df711e1247 quagga-0.99.11-del-routes.patch 2328ad4066584654cfc73f66d39dc267 quagga-0.99.16-ipctl_forwarding.patch ec7ac8cc1103f023cf5b9482b26ece59 bgpd.initd 92aba039c049050c48abf984c2db7e2b ospf6d.initd 878328ead225e6eb5f5f77f05ab39106 ospfd.initd 5945863133a0db33898c5c39ef23663c ripd.initd cda4115283d9f4a8304fec1b6881a7eb ripngd.initd 172e5b0e3f169e2b3328123e73517084 zebra.initd 34e06a1d2bc602ce691abc9ed169dd15 zebra.confd" sha256sums="fb49dce0d54b83bf4cb82cf998dc3adddd34a7579f3c7cba0572a252c010c6a6 quagga-0.99.22.1.tar.xz 11eee48e2954f1ac47e522dee8ca6e87f486abafccfe12ee5bd0f5845077ffc5 quagga-0.99.11-del-routes.patch f06053e2a9030be80992bb7d4b18f4cfecd2d43cb09458557b6b8c1ac3fd22ca quagga-0.99.16-ipctl_forwarding.patch 962afa79a0bcb781acc4c367ed55ccea2fbb927cf1271bc1fefaffcbb2f9389a bgpd.initd f1017e7681692d99eab6f9842313be18104612055bcdab14dd7ac4ac1be38f53 ospf6d.initd fed815e6530551f314297704e5491f5d2eeb16e930dcff6f12edc88a78b6023a ospfd.initd 36abd1158130a9268b6b852b7511a3457f8a17528f7d1b8a0b3f8ac41248a3c3 ripd.initd 565b6c0380a0010f464e37490468d58b9867bf6cfcbb36ac682a5e2760c40191 ripngd.initd ca7c252cc1c79f05a55f933317d9a7f523dc6501bf5c72c553c43da4f8fd68dd zebra.initd f7a52d383f60270a5a8fee5d4ac522c5c0ec2b7c4b5252cff54e260f32d9b323 zebra.confd" sha512sums="0ebe2fe2062a9f9db985fb3ac56df142bc35b45e5afe1b265a211cc3310920b39defab0baae805092cc20ce99e1af57ad1f03d7d65691f2150b4a23cdc70b5d4 quagga-0.99.22.1.tar.xz 34fda1c9ccb645a3df1ccc1947f87c4086f8aadeb9b53746bfd45f3562f6c1051964b45ec3a6f7e0eb1db46e424aae3daada49fea2582a62aeff71f78b885f4b quagga-0.99.11-del-routes.patch 1f4c45765bc1a8678ad1404bfab65799d9329e8f78a897b5c9c294d167745dd10d25304ba490988d9e94ae815c2c6f107b13efb3c710c44515470a61e2dd7c84 quagga-0.99.16-ipctl_forwarding.patch a865d9f5d2593270abc56dc65785317115337da00e8f389df3bf9af314052a4dc9e8f7af1142f7726637e06f1d8f7640cafd2a9e5ee8a7b4fd6b4e7b7c5bc784 bgpd.initd f76aaacb1949a528a71a4bb69e9b6fa522c507000e8fa0cd60e0d80b8d2820155fa40fe7dedd86bdf38dc8029b1958c90bfbc8423afc737aae59248adba906b3 ospf6d.initd fa3edb10d5b543c3f53a4dbd82edcda011be01f2d94b7b208cc02c1137a33adb703b734e7a4f22a51ec4d66203c44918dc9441be02b67248858b413146c61c16 ospfd.initd 95c96968133ed082a9e49661d1ea66fbeeb871d9bdd0dc5602953360e73ec2a83992c787f745211448629e3d90e69dc38a5fcae948825a7a73d3f2e4b8b91cc6 ripd.initd 6dbb662755ef84827768f2ed4779205e52b7eae50d377af5e4a951eb94317dbce3958184deb70dd3aa27f96d614e0be4d0fe2d871d961f4ffceaa84de454181c ripngd.initd 978a61e24ec9fc5558df550894f24cde4b729f88243e3f3d45394ec78009e22a87116c5a1dc4c382c7fa41e888155c8d901fc6028fba1cf9554349d4b432524e zebra.initd 900972c6f98e561dfacf384111251db262326e8764b8c763a5ef639fa11c7949c03eef5e3bce324a4b1964fe45416d2db74ae1b6bc967f7d4ba48c2eeda017c4 zebra.confd"