2018-11-14 04:53:20 +00:00
|
|
|
# Template file for 'frr'
|
|
|
|
pkgname=frr
|
2019-03-24 18:46:16 +00:00
|
|
|
version=7.0
|
2019-04-20 16:09:54 +00:00
|
|
|
revision=2
|
2018-11-14 04:53:20 +00:00
|
|
|
wrksrc="${pkgname}-${pkgname}-${version}"
|
|
|
|
build_style=gnu-configure
|
|
|
|
# chroot-texinfo is not able to build frr's docs
|
|
|
|
configure_args="--disable-doc
|
|
|
|
--localstatedir=/run/frr --sysconfdir=/etc/frr
|
|
|
|
--enable-exampledir=/usr/share/examples/frr
|
|
|
|
--enable-user=_frr --enable-group=_frr --enable-vty-group=_frrvty"
|
|
|
|
make_build_args="SPHINXBUILD=sphinx-build3"
|
|
|
|
conf_files="/etc/frr/*.conf"
|
|
|
|
make_dirs="/var/log/frr 0700 _frr _frr"
|
|
|
|
hostmakedepends="pkg-config flex bison autoconf automake libtool
|
2019-03-24 18:46:16 +00:00
|
|
|
python python3 python3-Sphinx python-devel python3-devel libyang-tools"
|
2018-11-14 04:53:20 +00:00
|
|
|
makedepends="pcre-devel libcap-devel json-c-devel pam-devel c-ares-devel
|
2019-03-24 18:46:16 +00:00
|
|
|
readline-devel python-devel python3-devel libyang-devel"
|
2018-11-14 04:53:20 +00:00
|
|
|
short_desc="IP routing protocol suite"
|
|
|
|
maintainer="Cameron Nemo <camerontnorman@gmail.com>"
|
|
|
|
license="GPL-2.0-or-later, LGPL-2.1-or-later"
|
|
|
|
homepage="https://frrouting.org"
|
|
|
|
distfiles="https://github.com/FRRouting/frr/archive/${pkgname}-${version}.tar.gz"
|
2019-03-24 18:46:16 +00:00
|
|
|
checksum=15b62dc0c52531e4bcefa6b830e9b9b07d1d0f189c2110307dbc19d80b719354
|
2018-11-14 04:53:20 +00:00
|
|
|
nocross="http://ix.io/1rQ6"
|
|
|
|
system_groups="_frrvty"
|
|
|
|
system_accounts="_frr"
|
|
|
|
_frr_groups="_frrvty"
|
2019-04-20 16:09:54 +00:00
|
|
|
_daemons="zebra staticd bgpd ospfd ospf6d ripd ripngd isisd pimd ldpd nhrpd
|
|
|
|
eigrpd babeld sharpd pbrd bfdd fabricd"
|
2018-11-14 04:53:20 +00:00
|
|
|
|
|
|
|
pre_configure() {
|
|
|
|
autoreconf -fi
|
|
|
|
}
|
|
|
|
|
|
|
|
post_install() {
|
|
|
|
# LSB init script is not needed
|
|
|
|
rm -f -- "${DESTDIR}/usr/bin/frr"
|
|
|
|
|
2019-04-20 16:09:54 +00:00
|
|
|
# frr-reload wrapper script hardcodes sbindir as usr/lib/frr, avoid it
|
2018-11-14 04:53:20 +00:00
|
|
|
rm -f -- "${DESTDIR}/usr/bin/frr-reload"
|
|
|
|
mv "${DESTDIR}/usr/bin/frr-reload.py" "${DESTDIR}/usr/bin/frr-reload"
|
|
|
|
|
|
|
|
vbin "${FILESDIR}"/frr-flush
|
|
|
|
vsv frr-generic
|
|
|
|
vmkdir etc/frr 0755
|
|
|
|
vinstall /dev/null 0640 etc/frr vtysh.conf
|
2019-04-20 16:09:54 +00:00
|
|
|
for daemon in ${_daemons}; do
|
2018-11-14 04:53:20 +00:00
|
|
|
vinstall /dev/null 0640 etc/frr "${daemon}.conf"
|
|
|
|
vsv "${daemon}"
|
|
|
|
done
|
|
|
|
}
|
|
|
|
|
|
|
|
frr-flush_package() {
|
|
|
|
short_desc+=" - route flushing tool"
|
2019-04-20 16:09:54 +00:00
|
|
|
depends="iproute2 ${sourcepkg}-${version}_${revision}"
|
2018-11-14 04:53:20 +00:00
|
|
|
pkg_install() {
|
|
|
|
vmove usr/bin/frr-flush
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
frr-reload_package() {
|
|
|
|
short_desc+=" - reload tool"
|
2019-04-20 16:09:54 +00:00
|
|
|
depends="python-ipaddr python ${sourcepkg}-${version}_${revision}"
|
2018-11-14 04:53:20 +00:00
|
|
|
pkg_install() {
|
|
|
|
vmove usr/bin/frr-reload
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
libfrr_package() {
|
|
|
|
short_desc+=" - client library"
|
|
|
|
pkg_install() {
|
|
|
|
vmove "usr/lib/libfrr.so.*"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
libfrr-devel_package() {
|
|
|
|
short_desc+=" - client library (development files)"
|
|
|
|
depends="${pkgname%-devel}-${version}_${revision}"
|
|
|
|
pkg_install() {
|
|
|
|
vmove "usr/include/frr/*.h"
|
|
|
|
vmove usr/include/frr/ospfd
|
|
|
|
vmove usr/include/frr/eigrpd
|
|
|
|
vmove usr/lib/libfrr.so
|
|
|
|
vmove usr/lib/libfrr.a
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
libfrrospfapiclient_package() {
|
|
|
|
short_desc+=" - OSPF client library"
|
|
|
|
pkg_install() {
|
|
|
|
vmove "usr/lib/libfrrospfapiclient.so.*"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
libfrrospfapiclient-devel_package() {
|
|
|
|
short_desc+=" - OSPF client library (development files)"
|
|
|
|
depends="${pkgname%-devel}-${version}_${revision}"
|
|
|
|
pkg_install() {
|
|
|
|
vmove usr/include/frr/ospfapi
|
|
|
|
vmove usr/lib/libfrrospfapiclient.so
|
|
|
|
vmove usr/lib/libfrrospfapiclient.a
|
|
|
|
}
|
|
|
|
}
|