diff options
author | Avneesh Sachdev <avneesh@sproute.com> | 2016-04-04 19:54:58 +0200 |
---|---|---|
committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2016-09-23 18:12:16 +0200 |
commit | fb0aa88623f72b7e4d0f35e8df3f96aa090fc5c8 (patch) | |
tree | 4958c96776674bd17f7bcd16a9272e4ac3c4b3df /zebra/Makefile.am | |
parent | Use only the ISC license for .proto files. (diff) | |
download | frr-fb0aa88623f72b7e4d0f35e8df3f96aa090fc5c8.tar.xz frr-fb0aa88623f72b7e4d0f35e8df3f96aa090fc5c8.zip |
zebra: optionally use protobuf with FPM
Change zebra so that it can optionally use protobuf serialization when
communicating with a Forwarding Plane Manager component.
* zebra/main.c
Add the --fpm-format/-F command line option. This allows the user
to control the format (protbuf|netlink) that is used to
communicate with the FPM.
* zebra/zebra_fpm.c
- zebra_init_msg_format(),
This new function is invoked on process startup to determine the
FPM format that should be used.
- zfpm_init()
Change to accept any 'FPM message format' specified by the user
(via the new command line flag).
- zebra_encode_route()
Tweak to use the selected FPM format.
* zebra_fpm_protobuf.c
New code to build protobuf messages to be sent to the FPM.
* zebra/Makefile.am
- Include common.am
- Build new file zebra_fpm_protobuf.c when protobuf is available.
- Link with the fpm_pb library.
Signed-off-by: Avneesh Sachdev <avneesh@sproute.com>
Diffstat (limited to 'zebra/Makefile.am')
-rw-r--r-- | zebra/Makefile.am | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/zebra/Makefile.am b/zebra/Makefile.am index 851e59779..26c283b9c 100644 --- a/zebra/Makefile.am +++ b/zebra/Makefile.am @@ -1,3 +1,5 @@ +include ../common.am + ## Process this file with automake to produce Makefile.in. AM_CPPFLAGS = -I.. -I$(top_srcdir) -I$(top_srcdir)/lib -I$(top_builddir)/lib @@ -21,6 +23,10 @@ if HAVE_NETLINK othersrc = zebra_fpm_netlink.c endif +if HAVE_PROTOBUF +protobuf_srcs = zebra_fpm_protobuf.c +endif + AM_CFLAGS = $(WERROR) sbin_PROGRAMS = zebra @@ -33,7 +39,8 @@ zebra_SOURCES = \ redistribute.c debug.c rtadv.c zebra_snmp.c zebra_vty.c \ irdp_main.c irdp_interface.c irdp_packet.c router-id.c zebra_fpm.c \ $(othersrc) zebra_ptm.c zebra_rnh.c zebra_ptm_redistribute.c \ - zebra_ns.c zebra_vrf.c zebra_static.c zebra_mpls.c zebra_mpls_vty.c + zebra_ns.c zebra_vrf.c zebra_static.c zebra_mpls.c zebra_mpls_vty.c \ + $(protobuf_srcs) testzebra_SOURCES = test_main.c zebra_rib.c interface.c connected.c debug.c \ zebra_vty.c zebra_ptm.c zebra_routemap.c zebra_ns.c zebra_vrf.c \ @@ -49,7 +56,7 @@ noinst_HEADERS = \ zebra_ptm_redistribute.h zebra_ptm.h zebra_routemap.h \ zebra_ns.h zebra_vrf.h ioctl_solaris.h zebra_static.h zebra_mpls.h -zebra_LDADD = $(otherobj) ../lib/libzebra.la $(LIBCAP) +zebra_LDADD = $(otherobj) ../lib/libzebra.la $(LIBCAP) $(Q_FPM_PB_CLIENT_LDOPTS) testzebra_LDADD = ../lib/libzebra.la $(LIBCAP) |