net/frr8: remove vtysh port option, housekeeping, fix build with SNMP

Remove the vtysh port option due to upstream breakage. At this time, both
net/frr8 and net/frr9 cannot be built without vtysh. This is an uncommon
scenario and upstream does not currently test this build option.
Also cleanup the Makefile and pkg-plist structure and ordering.

PR:		272757
Reported by:	R. Christian McDonald <rcm@rcm.sh>, brd
Obtained from:	R. Christian McDonald <rcm@rcm.sh>
This commit is contained in:
Olivier Cochard 2023-09-28 18:32:46 +02:00
parent 4c905ade22
commit cf8cec813d
2 changed files with 74 additions and 72 deletions

View File

@ -1,6 +1,7 @@
PORTNAME= frr
PORTVERSION= 8.5.3
DISTVERSIONPREFIX= frr-
PORTREVISION= 1
CATEGORIES= net
.if defined(PYTHONTOOLS)
PKGNAMESUFFIX= 8-pythontools
@ -36,17 +37,17 @@ do-install:
${INSTALL_DATA} ${WRKSRC}/tools/etc/frr/support_bundle_commands.conf ${STAGEDIR}${ETCDIR}/
.else
LIB_DEPENDS= libjson-c.so:devel/json-c \
libyang.so.2:net/libyang2 \
libcares.so:dns/c-ares \
libpcre2-8.so:devel/pcre2
LIB_DEPENDS= libcares.so:dns/c-ares \
libjson-c.so:devel/json-c \
libpcre2-8.so:devel/pcre2 \
libyang.so.2:net/libyang2
USES= autoreconf bison compiler:c++11-lang gmake pkgconfig libtool \
makeinfo python:build readline shebangfix
USES= autoreconf bison compiler:c++11-lang gmake libtool makeinfo \
pkgconfig python:build readline shebangfix
BINARY_ALIAS= python=${PYTHON_VERSION}
CONFLICTS= openbgpd openospfd zebra quagga
CONFLICTS= frr[79] openbgpd openospfd quagga zebra
GNU_CONFIGURE= yes
INSTALL_TARGET= install-strip
@ -61,30 +62,29 @@ NO_BUILD= yes
NO_ARCH= yes
SHEBANG_FILES= tools/frr-reload.py \
tools/generate_support_bundle.py
PLIST= ${.CURDIR}/pkg-plist
tools/generate_support_bundle.py
PLIST= ${.CURDIR}/pkg-plist
PKGMESSAGE= ""
.else
INFO= frr
OPTIONS_DEFINE= BACKTRACE CONFIGROLLBACKS FPM DATACENTER LDPD PAM SHELLACCESS \
VTYSH MANPAGES MULTIPATH TCMALLOC RPKI SHARPD SNMP
OPTIONS_DEFAULT= BACKTRACE VTYSH RPKI FPM MANPAGES
OPTIONS_DEFINE= BACKTRACE CONFIGROLLBACKS DATACENTER FPM LDPD MANPAGES MULTIPATH \
PAM RPKI SHARPD SHELLACCESS SNMP TCMALLOC
OPTIONS_DEFAULT= BACKTRACE FPM MANPAGES RPKI
OPTIONS_SUB= yes
BACKTRACE_DESC= Enable backtrace
BACKTRACE_DESC= Enable backtrace
CONFIGROLLBACKS_DESC= Enable configuration rollback support
FPM_DESC= Enable Forwarding Plane Manager support
DATACENTER_DESC= Use reduced BGP timers
FPM_DESC= Enable Forwarding Plane Manager support
LDPD_DESC= Build ldpd
MULTIPATH_DESC= Allow 64 multipath routes (16 default)
PAM_DESC= Use libpam for PAM support in vtysh
RPKI_DESC= Add BGP RPKI (RFC 6810) support
SHARPD_DESC= Build sharpd
SHELLACCESS_DESC= Allow users to access shell/telnet/ssh
SNMP_DESC= SNMP support
SHARPD_DESC= Build sharpd
TCMALLOC_DESC= Use tcmalloc
VTYSH_DESC= Build integrated vty shell
USERS= frr
GROUPS= frr frrvty
@ -96,6 +96,7 @@ LDFLAGS+= -L${LOCALBASE}/lib
CONFIGURE_ARGS= --enable-user=frr \
--enable-group=frr \
--enable-vty-group=frrvty \
--enable-vtysh \
--disable-doc-html \
--sysconfdir=${ETCDIR} \
--localstatedir=/var/run/frr \
@ -106,29 +107,27 @@ CONFIGURE_ARGS= --enable-user=frr \
--disable-pbrd \
--with-vtysh-pager=cat
MANPAGES_BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}sphinx>=0,1:textproc/py-sphinx@${PY_FLAVOR}
MANPAGES_CONFIGURE_OFF= --disable-doc
BACKTRACE_LIB_DEPENDS= libunwind.so:devel/libunwind
BACKTRACE_LIB_DEPENDS= libunwind.so:devel/libunwind
BACKTRACE_CONFIGURE_ENABLE= backtrace
CONFIGROLLBACKS_LIB_DEPENDS= libsqlite3.so:databases/sqlite3
CONFIGROLLBACKS_CONFIGURE_ENABLE= config-rollbacks
DATACENTER_CONFIGURE_ENABLE= datacenter
SHELLACCESS_CONFIGURE_ENABLE= shell-access
FPM_CONFIGURE_ENABLE= fpm
PAM_CONFIGURE_WITH= libpam
LDPD_CONFIGURE_ENABLE= ldpd
MANPAGES_BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}sphinx>=0,1:textproc/py-sphinx@${PY_FLAVOR}
MANPAGES_CONFIGURE_OFF= --disable-doc
MULTIPATH_CONFIGURE_ON= --enable-multipath=64
PAM_CONFIGURE_WITH= libpam
RPKI_CONFIGURE_ENABLE= rpki
RPKI_LIB_DEPENDS= librtr.so:net-mgmt/rtrlib \
libssh.so:security/libssh
TCMALLOC_CONFIGURE_ENABLE= tcmalloc
TCMALLOC_LIB_DEPENDS= libtcmalloc.so:devel/google-perftools
SHARPD_CONFIGURE_ENABLE= sharpd
SHELLACCESS_CONFIGURE_ENABLE= shell-access
SNMP_CONFIGURE_ENABLE= snmp
SNMP_CFLAGS= "-std=gnu99"
SNMP_LIB_DEPENDS= libnetsnmp.so:net-mgmt/net-snmp
SNMP_USES= ssl
SHARPD_CONFIGURE_ENABLE= sharpd
VTYSH_CONFIGURE_ENABLE= vtysh
TCMALLOC_CONFIGURE_ENABLE= tcmalloc
TCMALLOC_LIB_DEPENDS= libtcmalloc.so:devel/google-perftools
USE_RC_SUBR= frr watchfrr

View File

@ -1,23 +1,11 @@
%%VTYSH%%bin/vtysh
%%SHARPD%%sbin/sharpd
@dir(frr,frr,750) /var/run/frr
bin/vtysh
include/frr/agg_table.h
include/frr/atomlist.h
include/frr/assert.h
include/frr/atomlist.h
include/frr/base64.h
include/frr/bfdd/bfddp_packet.h
include/frr/cspf.h
include/frr/libfrr_trace.h
include/frr/link_state.h
include/frr/resolver.h
include/frr/tc.h
include/frr/trace.h
include/frr/xref.h
include/frr/yang.h
include/frr/yang_translator.h
include/frr/yang_wrappers.h
include/frr/zlog_5424.h
include/frr/zlog_live.h
include/frr/bfd.h
include/frr/bfdd/bfddp_packet.h
include/frr/bitfield.h
include/frr/buffer.h
include/frr/checksum.h
@ -25,6 +13,7 @@ include/frr/command.h
include/frr/command_graph.h
include/frr/command_match.h
include/frr/compiler.h
include/frr/cspf.h
include/frr/csv.h
include/frr/db.h
include/frr/debug.h
@ -40,8 +29,8 @@ include/frr/frr_pthread.h
include/frr/frratomic.h
include/frr/frrcu.h
include/frr/frrlua.h
include/frr/frrstr.h
include/frr/frrscript.h
include/frr/frrstr.h
include/frr/getopt.h
include/frr/graph.h
include/frr/hash.h
@ -59,7 +48,9 @@ include/frr/ldp_sync.h
include/frr/lib_errors.h
include/frr/lib_vty.h
include/frr/libfrr.h
include/frr/libfrr_trace.h
include/frr/libospf.h
include/frr/link_state.h
include/frr/linklist.h
include/frr/log.h
include/frr/log_vty.h
@ -97,8 +88,9 @@ include/frr/privs.h
include/frr/ptm_lib.h
include/frr/pullwr.h
include/frr/pw.h
include/frr/queue.h
include/frr/qobj.h
include/frr/queue.h
include/frr/resolver.h
include/frr/ringbuf.h
include/frr/route_opaque.h
include/frr/route_types.h
@ -108,33 +100,41 @@ include/frr/sbuf.h
include/frr/seqlock.h
include/frr/sha256.h
include/frr/sigevent.h
include/frr/smux.h
include/frr/spf_backoff.h
include/frr/skiplist.h
include/frr/smux.h
include/frr/sockopt.h
include/frr/sockunion.h
include/frr/spf_backoff.h
include/frr/srcdest_table.h
include/frr/srte.h
include/frr/srv6.h
include/frr/stream.h
include/frr/systemd.h
include/frr/table.h
include/frr/tc.h
include/frr/termtable.h
include/frr/thread.h
include/frr/trace.h
include/frr/typerb.h
include/frr/typesafe.h
include/frr/vector.h
include/frr/version.h
include/frr/vlan.h
include/frr/vrf_int.h
include/frr/vrf.h
include/frr/vrf_int.h
include/frr/vty.h
include/frr/vxlan.h
include/frr/wheel.h
include/frr/workqueue.h
include/frr/xref.h
include/frr/yang.h
include/frr/yang_translator.h
include/frr/yang_wrappers.h
include/frr/zclient.h
include/frr/zebra.h
include/frr/zlog.h
include/frr/zlog_5424.h
include/frr/zlog_live.h
include/frr/zlog_targets.h
lib/libfrr.a
lib/libfrr.so
@ -144,48 +144,52 @@ lib/libfrrcares.a
lib/libfrrcares.so
lib/libfrrcares.so.0
lib/libfrrcares.so.0.0.0
%%SNMP%%lib/frr/modules/bgpd_snmp.so
%%SNMP%%lib/frr/modules/bgpd_bmp.so
%%SNMP%%lib/frr/modules/ospf6d_snmp.so
%%SNMP%%lib/frr/modules/ospfd_snmp.so
%%SNMP%%lib/frr/modules/ripd_snmp.so
%%SNMP%%lib/frr/modules/zebra_snmp.so
%%FPM%%lib/frr/modules/zebra_fpm.so
%%SNMP%%lib/libfrrsnmp.a
%%SNMP%%lib/libfrrsnmp.so
%%SNMP%%lib/libfrrsnmp.so.0
%%SNMP%%lib/libfrrsnmp.so.0.0.0
%%SNMP%%lib/frr/modules/bgpd_bmp.so
%%RPKI%%lib/frr/modules/bgpd_rpki.so
%%SNMP%%lib/frr/modules/bgpd_snmp.so
%%SNMP%%lib/frr/modules/isisd_snmp.so
%%SNMP%%%%LDPD%%lib/frr/modules/ldpd_snmp.so
%%SNMP%%lib/frr/modules/ospf6d_snmp.so
%%SNMP%%lib/frr/modules/ospfd_snmp.so
%%SNMP%%lib/frr/modules/ripd_snmp.so
%%FPM%%lib/frr/modules/zebra_fpm.so
%%SNMP%%lib/frr/modules/zebra_snmp.so
%%MANPAGES%%man/man1/frr.1.gz
%%MANPAGES%%man/man1/vtysh.1.gz
%%MANPAGES%%man/man8/frr-bfdd.8.gz
%%MANPAGES%%man/man8/frr-bgpd.8.gz
%%MANPAGES%%man/man8/frr-eigrpd.8.gz
%%MANPAGES%%man/man8/frr-isisd.8.gz
%%MANPAGES%%man/man8/frr-staticd.8.gz
%%MANPAGES%%man/man8/frr-watchfrr.8.gz
%%MANPAGES%%%%VTYSH%%man/man1/vtysh.1.gz
%%MANPAGES%%man/man8/frr-bgpd.8.gz
%%MANPAGES%%%%LDPD%%man/man8/frr-ldpd.8.gz
%%MANPAGES%%man/man8/frr-ospf6d.8.gz
%%MANPAGES%%man/man8/frr-ospfd.8.gz
%%MANPAGES%%man/man8/frr-ripd.8.gz
%%MANPAGES%%man/man8/frr-ripngd.8.gz
%%MANPAGES%%%%SHARPD%%man/man8/frr-sharpd.8.gz
%%MANPAGES%%man/man8/frr-staticd.8.gz
%%MANPAGES%%man/man8/frr-watchfrr.8.gz
%%MANPAGES%%man/man8/frr-zebra.8.gz
sbin/babeld
sbin/bfdd
sbin/bgpd
%%LDPD%%sbin/ldpd
sbin/eigrpd
sbin/fabricd
sbin/frr-reload
sbin/isisd
%%LDPD%%sbin/ldpd
sbin/ospf6d
sbin/ospfd
sbin/ripd
sbin/ripngd
%%SHARPD%%sbin/sharpd
sbin/staticd
sbin/zebra
sbin/isisd
sbin/watchfrr
share/yang/ietf-bgp-types.yang
sbin/zebra
share/yang/frr-bfdd.yang
share/yang/frr-bgp-bmp.yang
share/yang/frr-bgp-common-multiprotocol.yang
share/yang/frr-bgp-common-structure.yang
@ -198,26 +202,25 @@ share/yang/frr-bgp-rpki.yang
share/yang/frr-bgp-types.yang
share/yang/frr-bgp.yang
share/yang/frr-deviations-bgp-datacenter.yang
share/yang/frr-ospf-route-map.yang
share/yang/frr-ospf6-route-map.yang
share/yang/frr-ospfd.yang
share/yang/frr-bfdd.yang
share/yang/frr-eigrpd.yang
share/yang/frr-filter.yang
share/yang/frr-interface.yang
share/yang/frr-isisd.yang
share/yang/frr-module-translator.yang
share/yang/frr-nexthop.yang
share/yang/frr-ospf-route-map.yang
share/yang/frr-ospf6-route-map.yang
share/yang/frr-ospfd.yang
share/yang/frr-ripd.yang
share/yang/frr-ripngd.yang
share/yang/frr-route-types.yang
share/yang/frr-test-module.yang
share/yang/frr-filter.yang
share/yang/frr-nexthop.yang
share/yang/frr-route-map.yang
share/yang/frr-route-types.yang
share/yang/frr-routing.yang
share/yang/frr-staticd.yang
share/yang/frr-test-module.yang
share/yang/frr-vrf.yang
share/yang/frr-zebra.yang
share/yang/frr-zebra-route-map.yang
share/yang/frr-zebra.yang
share/yang/ietf-bgp-types.yang
share/yang/ietf-interfaces.yang
share/yang/ietf-routing-types.yang
@dir(frr,frr,750) /var/run/frr