ip: Path MTU
[vpp.git] / src / vnet / CMakeLists.txt
1 # Copyright (c) 2018-2020 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 add_definitions (-DWITH_LIBSSL=1)
15 include_directories(${OPENSSL_INCLUDE_DIR})
16
17 unset(VNET_SOURCES)
18 unset(VNET_HEADERS)
19 unset(VNET_API_FILES)
20 unset(VNET_MULTIARCH_SOURCES)
21
22 ##############################################################################
23 # Generic stuff
24 ##############################################################################
25 list(APPEND VNET_SOURCES
26   buffer.c
27   config.c
28   devices/devices.c
29   devices/netlink.c
30   flow/flow.c
31   flow/flow_cli.c
32   flow/flow_api.c
33   handoff.c
34   interface.c
35   interface_api.c
36   interface_cli.c
37   interface_format.c
38   interface_output.c
39   interface/rx_queue.c
40   interface/runtime.c
41   interface_stats.c
42   misc.c
43 )
44
45 list(APPEND VNET_MULTIARCH_SOURCES
46   interface_output.c
47   interface_stats.c
48   handoff.c
49 )
50
51 list(APPEND VNET_HEADERS
52   api_errno.h
53   buffer.h
54   config.h
55   devices/devices.h
56   devices/netlink.h
57   flow/flow.h
58   global_funcs.h
59   handoff.h
60   interface/rx_queue_funcs.h
61   interface.h
62   interface_funcs.h
63   interface_output.h
64   ip/ip4_to_ip6.h
65   ip/ip6_to_ip4.h
66   ip/ip_types_api.h
67   l3_types.h
68   plugin/plugin.h
69   pipeline.h
70   vnet.h
71   vnet_all_api_h.h
72   vnet_msg_enum.h
73   util/radix.h
74   util/refcount.h
75   format_fns.h
76   ip/ip_format_fns.h
77   ethernet/ethernet_format_fns.h
78 )
79
80 list(APPEND VNET_API_FILES
81   interface.api
82   interface_types.api
83   ip/ip_types.api
84   flow/flow_types.api
85   flow/flow.api
86 )
87
88 ##############################################################################
89 # Policer infra
90 ##############################################################################
91 list(APPEND VNET_SOURCES
92   policer/node_funcs.c
93   policer/policer.c
94   policer/xlate.c
95   policer/policer_api.c
96 )
97
98 list(APPEND VNET_MULTIARCH_SOURCES
99   policer/node_funcs.c
100 )
101
102 list(APPEND VNET_HEADERS
103   policer/police.h
104   policer/policer.h
105   policer/xlate.h
106 )
107
108 list(APPEND VNET_API_FILES
109   policer/policer.api
110   policer/policer_types.api
111 )
112
113 ##############################################################################
114 # Binary API compatibility until vpp 20.12, see the ADL plugin...
115 ##############################################################################
116
117 list(APPEND VNET_SOURCES
118   cop/cop_api.c
119 )
120
121 list(APPEND VNET_API_FILES cop/cop.api)
122
123 ##############################################################################
124 # Layer 2 protocols go here
125 ##############################################################################
126
127 ##############################################################################
128 # Layer 2 protocol: Ethernet
129 ##############################################################################
130 list(APPEND VNET_SOURCES
131   ethernet/arp_packet.c
132   ethernet/ethernet_types_api.c
133   ethernet/format.c
134   ethernet/init.c
135   ethernet/interface.c
136   ethernet/mac_address.c
137   ethernet/node.c
138   ethernet/pg.c
139   ethernet/sfp.c
140   ethernet/p2p_ethernet.c
141   ethernet/p2p_ethernet_input.c
142   ethernet/p2p_ethernet_api.c
143 )
144
145 list(APPEND VNET_MULTIARCH_SOURCES
146   ethernet/node.c
147   ethernet/p2p_ethernet_input.c
148 )
149
150 list(APPEND VNET_HEADERS
151   ethernet/error.def
152   ethernet/ethernet.h
153   ethernet/mac_address.h
154   ethernet/packet.h
155   ethernet/types.def
156   ethernet/sfp.h
157   ethernet/p2p_ethernet.h
158   ethernet/arp_packet.h
159 )
160
161 list(APPEND VNET_API_FILES
162   ethernet/p2p_ethernet.api
163   ethernet/ethernet_types.api)
164
165 ##############################################################################
166 # Layer 2 protocol: Ethernet bridging
167 ##############################################################################
168 list(APPEND VNET_SOURCES
169   l2/feat_bitmap.c
170   l2/l2_api.c
171   l2/l2_arp_term.c
172   l2/l2_bd.c
173   l2/l2_bvi.c
174   l2/l2_bvi_node.c
175   l2/l2_input_classify.c
176   l2/l2_output_classify.c
177   l2/l2_efp_filter.c
178   l2/l2_fib.c
179   l2/l2_flood.c
180   l2/l2_fwd.c
181   l2/l2_input.c
182   l2/l2_input_node.c
183   l2/l2_input_vtr.c
184   l2/l2_learn.c
185   l2/l2_output.c
186   l2/l2_in_out_acl.c
187   l2/l2_in_out_feat_arc.c
188   l2/l2_patch.c
189   l2/l2_rw.c
190   l2/l2_uu_fwd.c
191   l2/l2_vtr.c
192   l2/l2_xcrw.c
193 )
194
195 list(APPEND VNET_MULTIARCH_SOURCES
196   l2/l2_bvi_node.c
197   l2/l2_fwd.c
198   l2/l2_learn.c
199   l2/l2_output.c
200   l2/l2_patch.c
201   l2/l2_in_out_feat_arc.c
202   l2/l2_input_classify.c
203   l2/l2_input_node.c
204   l2/l2_output_classify.c
205   l2/l2_flood.c
206   l2/l2_uu_fwd.c
207   l2/l2_efp_filter.c
208   l2/l2_rw.c
209   l2/l2_xcrw.c
210   l2/l2_in_out_acl.c
211   l2/l2_input_vtr.c
212 )
213
214 list(APPEND VNET_HEADERS
215   l2/feat_bitmap.h
216   l2/l2_input.h
217   l2/l2_output.h
218   l2/l2_vtr.h
219   l2/l2_input_vtr.h
220   l2/l2_efp_filter.h
221   l2/l2_fwd.h
222   l2/l2_bd.h
223   l2/l2_bvi.h
224   l2/l2_flood.h
225   l2/l2_fib.h
226   l2/l2_rw.h
227   l2/l2_xcrw.h
228   l2/l2_classify.h
229 )
230
231 list(APPEND VNET_API_FILES l2/l2.api)
232
233 ##############################################################################
234 # Layer 2 protocol: SRP
235 ##############################################################################
236 list(APPEND VNET_SOURCES
237   srp/format.c
238   srp/interface.c
239   srp/node.c
240   srp/pg.c
241 )
242
243 list(APPEND VNET_HEADERS
244   srp/packet.h
245   srp/srp.h
246 )
247
248 ##############################################################################
249 # Layer 2 protocol: PPP
250 ##############################################################################
251 list(APPEND VNET_SOURCES
252   ppp/node.c
253   ppp/pg.c
254   ppp/ppp.c
255 )
256
257 list(APPEND VNET_HEADERS
258   ppp/error.def
259   ppp/ppp.h
260   ppp/packet.h
261 )
262
263 ##############################################################################
264 # Layer 2 protocol: HDLC
265 ##############################################################################
266 list(APPEND VNET_SOURCES
267   hdlc/node.c
268   hdlc/pg.c
269   hdlc/hdlc.c
270 )
271
272 list(APPEND VNET_HEADERS
273   hdlc/error.def
274   hdlc/hdlc.h
275   hdlc/packet.h
276 )
277
278 ##############################################################################
279 # Layer 2 protocol: LLC
280 ##############################################################################
281 list(APPEND VNET_SOURCES
282   llc/llc.c
283   llc/node.c
284   llc/pg.c
285 )
286
287 list(APPEND VNET_HEADERS
288   llc/llc.h
289 )
290
291 ##############################################################################
292 # Layer 2 protocol: SNAP
293 ##############################################################################
294 list(APPEND VNET_SOURCES
295   snap/snap.c
296   snap/node.c
297   snap/pg.c
298 )
299
300 list(APPEND VNET_HEADERS
301   snap/snap.h
302 )
303
304 ##############################################################################
305 # Layer 2 / vxlan
306 ##############################################################################
307 list(APPEND VNET_SOURCES
308   vxlan/vxlan.c
309   vxlan/encap.c
310   vxlan/decap.c
311   vxlan/vxlan_api.c
312 )
313
314 list(APPEND VNET_MULTIARCH_SOURCES
315   vxlan/encap.c
316 )
317
318 list(APPEND VNET_HEADERS
319   vxlan/vxlan.h
320   vxlan/vxlan_packet.h
321   vxlan/vxlan_error.def
322 )
323
324 list(APPEND VNET_MULTIARCH_SOURCES vxlan/decap.c)
325
326 list(APPEND VNET_API_FILES vxlan/vxlan.api)
327
328 ##############################################################################
329 # Layer 2 / Bonding
330 ##############################################################################
331 list(APPEND VNET_SOURCES
332   bonding/cli.c
333   bonding/node.c
334   bonding/device.c
335   bonding/bond_api.c
336 )
337
338 list(APPEND VNET_HEADERS
339   bonding/node.h
340 )
341
342 list(APPEND VNET_MULTIARCH_SOURCES bonding/node.c bonding/device.c)
343 list(APPEND VNET_API_FILES bonding/bond.api)
344
345 ##############################################################################
346 # Layer 2/3 "classify"
347 ##############################################################################
348 list(APPEND VNET_SOURCES
349   classify/vnet_classify.c
350   classify/trace_classify.h
351   classify/ip_classify.c
352   classify/in_out_acl.c
353   classify/policer_classify.c
354   classify/flow_classify.c
355   classify/flow_classify_node.c
356   classify/vnet_classify.h
357   classify/classify_api.c
358 )
359
360 list(APPEND VNET_MULTIARCH_SOURCES
361   classify/ip_classify.c
362   classify/flow_classify_node.c
363 )
364
365 list(APPEND VNET_HEADERS
366   classify/vnet_classify.h
367   classify/trace_classify.h
368   classify/in_out_acl.h
369   classify/policer_classify.h
370   classify/flow_classify.h
371 )
372
373 list(APPEND VNET_API_FILES classify/classify.api)
374
375 ##############################################################################
376 # Layer 3 protocols go here
377 ##############################################################################
378
379 ##############################################################################
380 # Layer 3 protocol: IP v4/v6
381 ##############################################################################
382 list(APPEND VNET_SOURCES
383   ip/format.c
384   ip/icmp4.c
385   ip/icmp6.c
386   ip/ip46_cli.c
387   ip/ip_types_api.c
388   ip/ip46_address.c
389   ip/ip4_format.c
390   ip/ip4_forward.c
391   ip/ip4_punt_drop.c
392   ip/ip4_input.c
393   ip/ip4_options.c
394   ip/ip4_mtrie.c
395   ip/ip4_pg.c
396   ip/ip4_source_and_port_range_check.c
397   ip/reass/ip4_full_reass.c
398   ip/reass/ip4_sv_reass.c
399   ip/ip6_format.c
400   ip/ip6_forward.c
401   ip/ip6_ll_table.c
402   ip/ip6_ll_types.c
403   ip/ip6_punt_drop.c
404   ip/ip6_hop_by_hop.c
405   ip/ip6_input.c
406   ip/ip6_link.c
407   ip/ip6_pg.c
408   ip/reass/ip6_full_reass.c
409   ip/reass/ip6_sv_reass.c
410   ip/ip_api.c
411   ip/ip_checksum.c
412   ip/ip_container_proxy.c
413   ip/ip_frag.c
414   ip/ip.c
415   ip/ip_interface.c
416   ip/ip_init.c
417   ip/ip_in_out_acl.c
418   ip/ip_path_mtu.c
419   ip/ip_path_mtu_node.c
420   ip/ip_punt_drop.c
421   ip/ip_types.c
422   ip/lookup.c
423   ip/punt_api.c
424   ip/punt.c
425   ip/punt_node.c
426   ip/vtep.c
427 )
428
429 list(APPEND VNET_MULTIARCH_SOURCES
430   ip/ip4_punt_drop.c
431   ip/reass/ip4_full_reass.c
432   ip/ip6_hop_by_hop.c
433   ip/reass/ip6_full_reass.c
434   ip/reass/ip4_sv_reass.c
435   ip/ip6_hop_by_hop.c
436   ip/reass/ip6_full_reass.c
437   ip/reass/ip6_sv_reass.c
438   ip/ip6_input.c
439   ip/ip6_punt_drop.c
440   ip/punt_node.c
441   ip/ip_in_out_acl.c
442   ip/ip_path_mtu_node.c
443 )
444
445 list(APPEND VNET_HEADERS
446   ip/format.h
447   ip/icmp46_packet.h
448   ip/icmp4.h
449   ip/icmp6.h
450   ip/igmp_packet.h
451   ip/ip4_error.h
452   ip/ip4.h
453   ip/ip4_mtrie.h
454   ip/ip4_inlines.h
455   ip/ip4_packet.h
456   ip/ip46_address.h
457   ip/ip6_error.h
458   ip/ip6.h
459   ip/ip6_hop_by_hop.h
460   ip/ip6_hop_by_hop_packet.h
461   ip/ip6_inlines.h
462   ip/ip6_packet.h
463   ip/ip.h
464   ip/ip_container_proxy.h
465   ip/ip_flow_hash.h
466   ip/ip_table.h
467   ip/ip_interface.h
468   ip/ip_packet.h
469   ip/ip_source_and_port_range_check.h
470   ip/ip_types.h
471   ip/lookup.h
472   ip/ports.def
473   ip/protocols.def
474   ip/punt_error.def
475   ip/punt.h
476 )
477
478 list(APPEND VNET_API_FILES
479   ip/ip.api
480   ip/punt.api
481 )
482
483 list(APPEND VNET_MULTIARCH_SOURCES
484   ip/ip4_forward.c
485   ip/ip6_forward.c
486   ip/ip4_input.c
487 )
488
489 ##############################################################################
490 # Layer 3 neighbours
491 ##############################################################################
492 list(APPEND VNET_SOURCES
493   ip-neighbor/ip_neighbor.c
494   ip-neighbor/ip_neighbor_api.c
495   ip-neighbor/ip_neighbor_dp.c
496   ip-neighbor/ip_neighbor_types.c
497   ip-neighbor/ip_neighbor_watch.c
498   ip-neighbor/ip4_neighbor.c
499   ip-neighbor/ip6_neighbor.c
500 )
501
502 list(APPEND VNET_HEADERS
503   ip-neighbor/ip_neighbor.h
504   ip-neighbor/ip_neighbor_types.h
505 )
506
507 list(APPEND VNET_API_FILES
508   ip-neighbor/ip_neighbor.api
509 )
510
511 ##############################################################################
512 # Bidirectional Forwarding Detection
513 ##############################################################################
514
515 list(APPEND VNET_HEADERS
516   bfd/bfd_protocol.h
517   bfd/bfd_main.h
518   bfd/bfd_api.h
519   bfd/bfd_udp.h
520 )
521
522 list(APPEND VNET_SOURCES
523   bfd/bfd_api.h
524   bfd/bfd_udp.c
525   bfd/bfd_main.c
526   bfd/bfd_protocol.c
527   bfd/bfd_cli.c
528   bfd/bfd_api.c
529 )
530
531 list(APPEND VNET_API_FILES bfd/bfd.api)
532
533 ##############################################################################
534 # Crypto
535 ##############################################################################
536
537 list(APPEND VNET_SOURCES
538   crypto/cli.c
539   crypto/crypto.c
540   crypto/format.c
541   crypto/node.c
542   crypto/crypto_api.c
543 )
544
545 list(APPEND VNET_HEADERS
546   crypto/crypto.h
547 )
548
549 list(APPEND VNET_MULTIARCH_SOURCES crypto/node.c)
550
551 list(APPEND VNET_API_FILES crypto/crypto.api)
552
553 ##############################################################################
554 # Layer 3 protocol: IPSec
555 ##############################################################################
556 list(APPEND VNET_SOURCES
557   ipsec/ipsec.c
558   ipsec/ipsec_cli.c
559   ipsec/ipsec_format.c
560   ipsec/ipsec_handoff.c
561   ipsec/ipsec_input.c
562   ipsec/ipsec_itf.c
563   ipsec/ipsec_punt.c
564   ipsec/ipsec_sa.c
565   ipsec/ipsec_spd.c
566   ipsec/ipsec_spd_policy.c
567   ipsec/ipsec_tun.c
568   ipsec/ipsec_tun_in.c
569   ipsec/esp_format.c
570   ipsec/esp_encrypt.c
571   ipsec/esp_decrypt.c
572   ipsec/ah_decrypt.c
573   ipsec/ah_encrypt.c
574   ipsec/ipsec_api.c
575   ipsec/ipsec_types_api.c
576 )
577
578 list(APPEND VNET_MULTIARCH_SOURCES
579   ipsec/esp_encrypt.c
580   ipsec/esp_decrypt.c
581   ipsec/ah_decrypt.c
582   ipsec/ah_encrypt.c
583   ipsec/ipsec_handoff.c
584   ipsec/ipsec_output.c
585   ipsec/ipsec_input.c
586   ipsec/ipsec_tun_in.c
587 )
588
589 list(APPEND VNET_API_FILES ipsec/ipsec_types.api)
590 list(APPEND VNET_API_FILES ipsec/ipsec.api)
591
592 list(APPEND VNET_SOURCES
593   ipsec/ipsec_output.c
594 )
595
596 list(APPEND VNET_HEADERS
597   ipsec/ipsec.h
598   ipsec/ipsec_spd.h
599   ipsec/ipsec_spd_policy.h
600   ipsec/ipsec_sa.h
601   ipsec/ipsec_tun.h
602   ipsec/ipsec_types_api.h
603   ipsec/ipsec_punt.h
604   ipsec/esp.h
605   ipsec/ah.h
606 )
607
608 ##############################################################################
609 # Layer 3 protocol: osi
610 ##############################################################################
611 list(APPEND VNET_SOURCES
612   osi/node.c
613   osi/osi.c
614   osi/pg.c
615 )
616
617 list(APPEND VNET_HEADERS
618   osi/osi.h
619 )
620
621 ##############################################################################
622 # Layer 4 protocol: tcp
623 ##############################################################################
624 list(APPEND VNET_SOURCES
625   tcp/tcp_api.c
626   tcp/tcp_format.c
627   tcp/tcp_pg.c
628   tcp/tcp_syn_filter4.c
629   tcp/tcp_output.c
630   tcp/tcp_input.c
631   tcp/tcp_newreno.c
632   tcp/tcp_bt.c
633   tcp/tcp_cli.c
634   tcp/tcp_cubic.c
635   tcp/tcp_debug.c
636   tcp/tcp_sack.c
637   tcp/tcp_timer.c
638   tcp/tcp.c
639 )
640
641 list(APPEND VNET_MULTIARCH_SOURCES
642   tcp/tcp_input.c
643   tcp/tcp_output.c
644   tcp/tcp_syn_filter4.c
645 )
646
647 list(APPEND VNET_HEADERS
648   tcp/tcp_packet.h
649   tcp/tcp_timer.h
650   tcp/tcp_bt.h
651   tcp/tcp_cc.h
652   tcp/tcp_debug.h
653   tcp/tcp_inlines.h
654   tcp/tcp_sack.h
655   tcp/tcp_types.h
656   tcp/tcp.h
657   tcp/tcp_error.def
658 )
659
660 list(APPEND VNET_API_FILES tcp/tcp.api)
661
662 ##############################################################################
663 # Layer 4 protocol: udp
664 ##############################################################################
665 list(APPEND VNET_SOURCES
666   udp/udp.c
667   udp/udp_cli.c
668   udp/udp_input.c
669   udp/udp_format.c
670   udp/udp_local.c
671   udp/udp_pg.c
672   udp/udp_encap_node.c
673   udp/udp_encap.c
674   udp/udp_api.c
675 )
676
677 list(APPEND VNET_MULTIARCH_SOURCES
678   udp/udp_local.c
679   udp/udp_encap_node.c
680 )
681
682 list(APPEND VNET_HEADERS
683   udp/udp_error.def
684   udp/udp.h
685   udp/udp_packet.h
686   udp/udp_inlines.h
687   udp/udp_local.h
688 )
689
690 list(APPEND VNET_API_FILES udp/udp.api)
691
692 ##############################################################################
693 # Tunnel protocol: gre
694 ##############################################################################
695 list(APPEND VNET_SOURCES
696   gre/gre.c
697   gre/node.c
698   gre/interface.c
699   gre/pg.c
700   gre/gre_api.c
701 )
702
703 list(APPEND VNET_MULTIARCH_SOURCES
704   gre/node.c
705   gre/gre.c
706 )
707
708 list(APPEND VNET_HEADERS
709   gre/gre.h
710   gre/packet.h
711   gre/error.def
712 )
713
714 list(APPEND VNET_API_FILES gre/gre.api)
715
716 ##############################################################################
717 # Tunnel protocol: ipip
718 ##############################################################################
719 list(APPEND VNET_SOURCES
720   ipip/ipip.c
721   ipip/node.c
722   ipip/sixrd.c
723   ipip/ipip_api.c
724   ipip/ipip_cli.c
725 )
726
727 list(APPEND VNET_MULTIARCH_SOURCES
728   ipip/node.c
729 )
730
731 list(APPEND VNET_HEADERS
732   ipip/ipip.h
733 )
734
735 list(APPEND VNET_API_FILES
736   ipip/ipip.api
737 )
738
739 ##############################################################################
740 # Tunnel infra
741 ##############################################################################
742 list(APPEND VNET_SOURCES
743   tunnel/tunnel.c
744   tunnel/tunnel_types_api.c
745 )
746
747 list(APPEND VNET_API_FILES
748   tunnel/tunnel_types.api
749 )
750
751 list(APPEND VNET_HEADERS
752   tunnel/tunnel.h
753   tunnel/tunnel_dp.h
754 )
755
756 ##############################################################################
757 # Tunnel protocol: gre+mpls
758 ##############################################################################
759 list(APPEND VNET_SOURCES
760   mpls/mpls.c
761   mpls/mpls_lookup.c
762   mpls/mpls_output.c
763   mpls/mpls_features.c
764   mpls/mpls_input.c
765   mpls/interface.c
766   mpls/mpls_tunnel.c
767   mpls/pg.c
768   mpls/mpls_api.c
769 )
770
771 list(APPEND VNET_MULTIARCH_SOURCES
772   mpls/mpls_output.c
773   mpls/mpls_input.c
774   mpls/mpls_lookup.c
775   mpls/mpls_features.c
776 )
777
778 list(APPEND VNET_HEADERS
779   mpls/mpls.h
780   mpls/mpls_types.h
781   mpls/mpls_tunnel.h
782   mpls/packet.h
783   mpls/error.def
784 )
785
786 list(APPEND VNET_API_FILES mpls/mpls.api)
787
788 ##############################################################################
789 # Tunnel protocol: vxlan-gbp
790 ##############################################################################
791 list(APPEND VNET_SOURCES
792   vxlan-gbp/decap.c
793   vxlan-gbp/encap.c
794   vxlan-gbp/vxlan_gbp_api.c
795   vxlan-gbp/vxlan_gbp.c
796   vxlan-gbp/vxlan_gbp_packet.c
797 )
798
799 list (APPEND VNET_MULTIARCH_SOURCES
800   vxlan-gbp/decap.c
801   vxlan-gbp/encap.c
802 )
803
804 list(APPEND VNET_HEADERS
805   vxlan-gbp/vxlan_gbp.h
806   vxlan-gbp/vxlan_gbp_packet.h
807   vxlan-gbp/vxlan_gbp_error.def
808 )
809
810 list(APPEND VNET_API_FILES vxlan-gbp/vxlan_gbp.api)
811
812 ##############################################################################
813 # Tunnel protocol: vxlan-gpe
814 ##############################################################################
815
816 list(APPEND VNET_SOURCES
817   vxlan-gpe/vxlan_gpe.c
818   vxlan-gpe/encap.c
819   vxlan-gpe/decap.c
820   vxlan-gpe/vxlan_gpe_api.c
821 )
822
823 list (APPEND VNET_MULTIARCH_SOURCES
824   vxlan-gpe/decap.c
825 )
826
827 list(APPEND VNET_HEADERS
828   vxlan-gpe/vxlan_gpe.h
829   vxlan-gpe/vxlan_gpe_packet.h
830   vxlan-gpe/vxlan_gpe_error.def
831 )
832
833 list(APPEND VNET_API_FILES vxlan-gpe/vxlan_gpe.api)
834
835 ##############################################################################
836 # ipv6 segment routing
837 ##############################################################################
838
839 list(APPEND VNET_SOURCES
840   srv6/sr.c
841   srv6/sr_localsid.c
842   srv6/sr_policy_rewrite.c
843   srv6/sr_steering.c
844   srv6/sr_api.c
845 )
846
847 list(APPEND VNET_HEADERS
848   srv6/sr_packet.h
849   srv6/sr.h
850 )
851
852 list(APPEND VNET_API_FILES
853   srv6/sr.api
854   srv6/sr_types.api
855 )
856
857 ##############################################################################
858 # mpls segment routing
859 ##############################################################################
860
861 list(APPEND VNET_SOURCES
862   srmpls/sr_mpls_policy.c
863   srmpls/sr_mpls_steering.c
864   srmpls/sr_mpls_api.c
865 )
866
867 list(APPEND VNET_HEADERS
868   srmpls/sr_mpls.h
869 )
870
871 list(APPEND VNET_API_FILES
872   srmpls/sr_mpls.api
873 )
874
875 ##############################################################################
876 # IPFIX / netflow v10
877 ##############################################################################
878 list(APPEND VNET_SOURCES
879   ipfix-export/flow_report.c
880   ipfix-export/flow_api.c
881 )
882
883 list(APPEND VNET_HEADERS
884   ipfix-export/flow_report.h
885   ipfix-export/ipfix_info_elements.h
886   ipfix-export/ipfix_packet.h
887 )
888
889 list(APPEND VNET_API_FILES ipfix-export/ipfix_export.api)
890
891 ##############################################################################
892 # GSO
893 ##############################################################################
894 list(APPEND VNET_SOURCES
895   gso/cli.c
896   gso/gso.c
897   gso/gso_api.c
898   gso/node.c
899 )
900
901 list(APPEND VNET_HEADERS
902   gso/gro.h
903   gso/gro_func.h
904   gso/hdr_offset_parser.h
905   gso/gso.h
906 )
907
908 list(APPEND VNET_API_FILES
909   gso/gso.api
910 )
911
912 ##############################################################################
913 # IPFIX classify code
914 ##############################################################################
915
916 list(APPEND VNET_SOURCES
917   ipfix-export/flow_report_classify.c
918 )
919
920 list(APPEND VNET_HEADERS
921   ipfix-export/flow_report_classify.h
922 )
923
924 ##############################################################################
925 # lawful intercept
926 ##############################################################################
927
928 list(APPEND VNET_SOURCES
929   lawful-intercept/lawful_intercept.c
930   lawful-intercept/node.c
931 )
932
933 list(APPEND VNET_MULTIARCH_SOURCES
934   lawful-intercept/node.c
935 )
936
937 list(APPEND VNET_HEADERS
938   lawful-intercept/lawful_intercept.h
939 )
940
941 ##############################################################################
942 # SPAN (port mirroring)
943 ##############################################################################
944
945 list(APPEND VNET_SOURCES
946   span/span_api.c
947   span/span.c
948   span/node.c
949 )
950
951 list(APPEND VNET_MULTIARCH_SOURCES
952   span/node.c
953 )
954
955 list(APPEND VNET_HEADERS
956   span/span.h
957 )
958
959 list(APPEND VNET_API_FILES span/span.api)
960
961 ##############################################################################
962 # Packet generator
963 ##############################################################################
964
965 list(APPEND VNET_SOURCES
966   pg/cli.c
967   pg/edit.c
968   pg/init.c
969   pg/input.c
970   pg/output.c
971   pg/stream.c
972   pg/pg_api.c
973 )
974
975 list(APPEND VNET_HEADERS
976   pg/pg.h
977   pg/edit.h
978 )
979
980 list(APPEND VNET_API_FILES pg/pg.api)
981
982 ##############################################################################
983 # virtio
984 ##############################################################################
985
986 list(APPEND VNET_SOURCES
987   devices/virtio/cli.c
988   devices/virtio/device.c
989   devices/virtio/format.c
990   devices/virtio/node.c
991   devices/virtio/pci.c
992   devices/virtio/vhost_user.c
993   devices/virtio/vhost_user_input.c
994   devices/virtio/vhost_user_output.c
995   devices/virtio/vhost_user_api.c
996   devices/virtio/virtio.c
997   devices/virtio/virtio_api.c
998   devices/virtio/virtio_pci_legacy.c
999   devices/virtio/virtio_pci_modern.c
1000   devices/virtio/virtio_process.c
1001   devices/virtio/virtio_types_api.c
1002 )
1003
1004 list(APPEND VNET_HEADERS
1005   devices/virtio/pci.h
1006   devices/virtio/virtio.h
1007   devices/virtio/virtio_buffering.h
1008   devices/virtio/virtio_std.h
1009   devices/virtio/virtio_pci_legacy.h
1010   devices/virtio/virtio_pci_modern.h
1011   devices/virtio/vhost_std.h
1012   devices/virtio/vhost_user.h
1013   devices/virtio/virtio_types_api.h
1014 )
1015
1016 list(APPEND VNET_MULTIARCH_SOURCES
1017   devices/virtio/vhost_user_input.c
1018   devices/virtio/vhost_user_output.c
1019   devices/virtio/node.c
1020   devices/af_packet/node.c
1021   devices/virtio/device.c
1022 )
1023
1024 list(APPEND VNET_API_FILES
1025   devices/virtio/vhost_user.api
1026   devices/virtio/virtio.api
1027   devices/virtio/virtio_types.api
1028 )
1029
1030 ##############################################################################
1031 # tap interface (with virtio backend)
1032 ##############################################################################
1033
1034 list(APPEND VNET_SOURCES
1035   devices/tap/cli.c
1036   devices/tap/tap.c
1037   devices/tap/tapv2_api.c
1038 )
1039
1040 list(APPEND VNET_HEADERS
1041   devices/tap/tap.h
1042 )
1043
1044 list(APPEND VNET_API_FILES
1045   devices/tap/tapv2.api
1046 )
1047
1048 ##############################################################################
1049 # tap interface (with virtio backend)
1050 ##############################################################################
1051
1052 list(APPEND VNET_SOURCES
1053   devices/pipe/pipe_api.c
1054   devices/pipe/pipe.c
1055 )
1056
1057 list(APPEND VNET_HEADERS
1058   devices/pipe/pipe.h
1059 )
1060
1061 list(APPEND VNET_API_FILES devices/pipe/pipe.api)
1062
1063 ##############################################################################
1064 # session managmeent
1065 ##############################################################################
1066
1067 list(APPEND VNET_SOURCES
1068   session/session.c
1069   session/session_debug.c
1070   session/session_table.c
1071   session/session_rules_table.c
1072   session/session_lookup.c
1073   session/session_node.c
1074   session/transport.c
1075   session/application.c
1076   session/application_worker.c
1077   session/session_cli.c
1078   session/application_interface.c
1079   session/application_local.c
1080   session/application_namespace.c
1081   session/segment_manager.c
1082   session/session_api.c
1083 )
1084
1085 list(APPEND VNET_HEADERS
1086   session/session.h
1087   session/session_table.h
1088   session/session_rules_table.h
1089   session/session_types.h
1090   session/session_lookup.h
1091   session/application.h
1092   session/transport.h
1093   session/transport_types.h
1094   session/application_interface.h
1095   session/application_local.h
1096   session/application_namespace.h
1097   session/session_debug.h
1098   session/segment_manager.h
1099   session/mma_template.h
1100   session/mma_template.c
1101   session/mma_16.h
1102   session/mma_40.h
1103 )
1104
1105 list(APPEND VNET_API_FILES session/session.api)
1106
1107 ##############################################################################
1108 # TLS protocol
1109 ##############################################################################
1110
1111 list(APPEND VNET_SOURCES
1112   tls/tls.c
1113 )
1114
1115 list(APPEND VNET_HEADERS
1116   tls/tls.h
1117   tls/tls_test.h
1118 )
1119
1120 ##############################################################################
1121 # Linux packet interface
1122 ##############################################################################
1123
1124 list(APPEND VNET_SOURCES
1125   devices/af_packet/af_packet.c
1126   devices/af_packet/device.c
1127   devices/af_packet/node.c
1128   devices/af_packet/cli.c
1129   devices/af_packet/af_packet_api.c
1130 )
1131
1132 list(APPEND VNET_MULTIARCH_SOURCES
1133   devices/af_packet/device.c
1134 )
1135
1136 list(APPEND VNET_HEADERS
1137   devices/af_packet/af_packet.h
1138 )
1139
1140 list(APPEND VNET_API_FILES devices/af_packet/af_packet.api)
1141
1142 ##############################################################################
1143 # Driver feature graph arc support
1144 ##############################################################################
1145
1146 list(APPEND VNET_SOURCES
1147   feature/feature.c
1148   feature/feature_api.c
1149   feature/registration.c
1150 )
1151
1152 list(APPEND VNET_HEADERS
1153   feature/feature.h
1154 )
1155
1156 list(APPEND VNET_API_FILES feature/feature.api)
1157
1158 ##############################################################################
1159 # Unix kernel related
1160 ##############################################################################
1161
1162 # FIXME: unix/hgshm.c
1163
1164 list(APPEND VNET_SOURCES
1165   unix/gdb_funcs.c
1166   unix/tuntap.c
1167 )
1168
1169 list(APPEND VNET_HEADERS
1170   unix/tuntap.h
1171 )
1172
1173 ##############################################################################
1174 # FIB
1175 ##############################################################################
1176
1177 list(APPEND VNET_SOURCES
1178   fib/fib.c
1179   fib/ip4_fib.c
1180   fib/ip6_fib.c
1181   fib/mpls_fib.c
1182   fib/fib_table.c
1183   fib/fib_walk.c
1184   fib/fib_types.c
1185   fib/fib_node.c
1186   fib/fib_node_list.c
1187   fib/fib_entry.c
1188   fib/fib_entry_src.c
1189   fib/fib_entry_src_adj.c
1190   fib/fib_entry_src_api.c
1191   fib/fib_entry_src_drop.c
1192   fib/fib_entry_src_interface.c
1193   fib/fib_entry_src_interpose.c
1194   fib/fib_entry_src_lisp.c
1195   fib/fib_entry_src_mpls.c
1196   fib/fib_entry_src_simple.c
1197   fib/fib_entry_src_rr.c
1198   fib/fib_entry_cover.c
1199   fib/fib_entry_delegate.c
1200   fib/fib_entry_track.c
1201   fib/fib_path_list.c
1202   fib/fib_path.c
1203   fib/fib_path_ext.c
1204   fib/fib_sas.c
1205   fib/fib_source.c
1206   fib/fib_urpf_list.c
1207   fib/fib_attached_export.c
1208   fib/fib_api.c
1209   fib/fib_bfd.c
1210 )
1211
1212 list(APPEND VNET_HEADERS
1213   fib/fib.h
1214   fib/fib_api.h
1215   fib/ip4_fib.h
1216   fib/ip6_fib.h
1217   fib/fib_types.h
1218   fib/fib_table.h
1219   fib/fib_node.h
1220   fib/fib_node_list.h
1221   fib/fib_entry.h
1222   fib/fib_entry_delegate.h
1223   fib/fib_sas.h
1224   fib/fib_source.h
1225 )
1226
1227 list(APPEND VNET_API_FILES fib/fib_types.api)
1228
1229 ##############################################################################
1230 # ADJ
1231 ##############################################################################
1232
1233 list(APPEND VNET_SOURCES
1234   adj/adj_nbr.c
1235   adj/adj_glean.c
1236   adj/adj_midchain.c
1237   adj/adj_midchain_delegate.c
1238   adj/adj_mcast.c
1239   adj/adj_l2.c
1240   adj/adj_nsh.c
1241   adj/adj.c
1242   adj/rewrite.c
1243   adj/adj_bfd.c
1244   adj/adj_delegate.c
1245 )
1246
1247 list(APPEND VNET_MULTIARCH_SOURCES
1248   adj/adj_nsh.c
1249   adj/adj_l2.c
1250   adj/adj_midchain.c
1251 )
1252
1253 list(APPEND VNET_HEADERS
1254   adj/adj.h
1255   adj/adj_types.h
1256   adj/adj_glean.h
1257   adj/adj_nsh.h
1258   adj/adj_nbr.h
1259   adj/adj_midchain.h
1260   adj/rewrite.h
1261 )
1262
1263 ##############################################################################
1264 # Data-Plane Objects
1265 ##############################################################################
1266
1267 list(APPEND VNET_SOURCES
1268   dpo/dpo.c
1269   dpo/drop_dpo.c
1270   dpo/ip_null_dpo.c
1271   dpo/ip6_ll_dpo.c
1272   dpo/punt_dpo.c
1273   dpo/receive_dpo.c
1274   dpo/load_balance.c
1275   dpo/load_balance_map.c
1276   dpo/lookup_dpo.c
1277   dpo/classify_dpo.c
1278   dpo/replicate_dpo.c
1279   dpo/interface_rx_dpo.c
1280   dpo/interface_tx_dpo.c
1281   dpo/mpls_disposition.c
1282   dpo/mpls_label_dpo.c
1283   dpo/l3_proxy_dpo.c
1284   dpo/dvr_dpo.c
1285   dpo/pw_cw.c
1286 )
1287
1288 list(APPEND VNET_MULTIARCH_SOURCES
1289   dpo/lookup_dpo.h
1290   dpo/mpls_disposition.c
1291   dpo/dvr_dpo.c
1292   dpo/mpls_label_dpo.c
1293   dpo/interface_rx_dpo.c
1294 )
1295
1296 list(APPEND VNET_HEADERS
1297   dpo/load_balance.h
1298   dpo/drop_dpo.h
1299   dpo/lookup_dpo.h
1300   dpo/punt_dpo.h
1301   dpo/classify_dpo.h
1302   dpo/receive_dpo.h
1303   dpo/ip_null_dpo.h
1304   dpo/replicate_dpo.h
1305   dpo/dpo.h
1306 )
1307
1308 ##############################################################################
1309 # Multicast FIB
1310 ##############################################################################
1311
1312 list(APPEND VNET_SOURCES
1313   mfib/mfib_forward.c
1314   mfib/ip4_mfib.c
1315   mfib/ip6_mfib.c
1316   mfib/mfib_api.c
1317   mfib/mfib_types.c
1318   mfib/mfib_signal.c
1319   mfib/mfib_itf.c
1320   mfib/mfib_entry.c
1321   mfib/mfib_entry.c
1322   mfib/mfib_entry_cover.c
1323   mfib/mfib_entry_delegate.c
1324   mfib/mfib_entry_src.c
1325   mfib/mfib_entry_src_rr.c
1326   mfib/mfib_table.c
1327 )
1328
1329 list(APPEND VNET_MULTIARCH_SOURCES
1330   mfib/mfib_forward.c
1331 )
1332
1333 list(APPEND VNET_HEADERS
1334   mfib/ip4_mfib.h
1335   mfib/mfib_types.h
1336   mfib/mfib_table.h
1337 )
1338
1339 list(APPEND VNET_API_FILES mfib/mfib_types.api)
1340
1341 ##############################################################################
1342 # Utilities
1343 ##############################################################################
1344
1345 list(APPEND VNET_SOURCES
1346   util/radix.c
1347   util/refcount.c
1348   util/throttle.c
1349   util/trajectory.c
1350 )
1351
1352 list(APPEND VNET_HEADERS
1353   util/throttle.h
1354 )
1355
1356 ##############################################################################
1357 # QoS
1358 ##############################################################################
1359
1360 list(APPEND VNET_SOURCES
1361   qos/qos_types.c
1362   qos/qos_api.c
1363   qos/qos_egress_map.c
1364   qos/qos_record.c
1365   qos/qos_record_node.c
1366   qos/qos_store.c
1367   qos/qos_store_node.c
1368   qos/qos_mark.c
1369   qos/qos_mark_node.c
1370 )
1371
1372 list(APPEND VNET_MULTIARCH_SOURCES
1373   qos/qos_record_node.c
1374   qos/qos_mark_node.c
1375 )
1376
1377 list(APPEND VNET_API_FILES qos/qos.api)
1378
1379 ##############################################################################
1380 # BIER
1381 ##############################################################################
1382
1383 list(APPEND VNET_SOURCES
1384   bier/bier_bit_string.c
1385   bier/bier_entry.c
1386   bier/bier_fmask.c
1387   bier/bier_fmask_db.c
1388   bier/bier_input.c
1389   bier/bier_lookup.c
1390   bier/bier_output.c
1391   bier/bier_table.c
1392   bier/bier_types.c
1393   bier/bier_api.c
1394   bier/bier_drop.c
1395   bier/bier_update.c
1396   bier/bier_imp_node.c
1397   bier/bier_imp.c
1398   bier/bier_disp_entry.c
1399   bier/bier_disp_lookup_node.c
1400   bier/bier_disp_dispatch_node.c
1401   bier/bier_disp_table.c
1402   bier/bier_bift_table.c
1403 )
1404
1405 list(APPEND VNET_MULTIARCH_SOURCES
1406   bier/bier_disp_dispatch_node.c
1407   bier/bier_disp_lookup_node.c
1408   bier/bier_imp_node.c
1409 )
1410
1411 list(APPEND VNET_HEADERS
1412   bier/bier_types.h
1413   bier/bier_entry.h
1414   bier/bier_update.h
1415   bier/bier_table.h
1416 )
1417
1418 list(APPEND VNET_API_FILES bier/bier.api)
1419
1420 ##############################################################################
1421 # SYSLOG
1422 ##############################################################################
1423
1424 list (APPEND VNET_SOURCES
1425   syslog/syslog_api.c
1426   syslog/syslog_udp.c
1427   syslog/syslog.c
1428 )
1429
1430 list(APPEND VNET_HEADERS
1431   syslog/syslog_udp.h
1432   syslog/syslog.h
1433 )
1434
1435 list(APPEND VNET_API_FILES syslog/syslog.api)
1436
1437 ##############################################################################
1438 # Tunnel Endpoint Information Base
1439 ##############################################################################
1440
1441 list (APPEND VNET_SOURCES
1442   teib/teib_api.c
1443   teib/teib_cli.c
1444   teib/teib.c
1445 )
1446
1447 list(APPEND VNET_HEADERS
1448   teib/teib.h
1449 )
1450
1451 list(APPEND VNET_API_FILES teib/teib.api)
1452
1453 ##############################################################################
1454 # ARP/ND
1455 ##############################################################################
1456
1457 list (APPEND VNET_SOURCES
1458   arp/arp_api.c
1459   arp/arp.c
1460   arp/arp_proxy.c
1461 )
1462
1463 list(APPEND VNET_HEADERS
1464   arp/arp.h
1465 )
1466
1467 list(APPEND VNET_API_FILES arp/arp.api)
1468
1469 list (APPEND VNET_SOURCES
1470   ip6-nd/ip6_mld.c
1471   ip6-nd/ip6_nd.c
1472   ip6-nd/ip6_nd_api.c
1473   ip6-nd/ip6_nd_proxy.c
1474   ip6-nd/ip6_ra.c
1475   ip6-nd/rd_cp.c
1476   ip6-nd/rd_cp_api.c
1477 )
1478
1479 list(APPEND VNET_HEADERS
1480   ip6-nd/ip6_nd.h
1481 )
1482
1483 list(APPEND VNET_API_FILES
1484   ip6-nd/ip6_nd.api
1485   ip6-nd/rd_cp.api
1486 )
1487
1488 ##############################################################################
1489 # VNET Library
1490 ##############################################################################
1491
1492 add_vpp_library(vnet
1493   SOURCES ${VNET_SOURCES}
1494   MULTIARCH_SOURCES ${VNET_MULTIARCH_SOURCES}
1495   INSTALL_HEADERS ${VNET_HEADERS}
1496   API_FILES ${VNET_API_FILES}
1497   LINK_LIBRARIES vppinfra svm vlib ${OPENSSL_LIBRARIES}
1498   DEPENDS vpp_version_h api_headers
1499 )
1500
1501 ##############################################################################
1502 # vpp api test client library
1503 ##############################################################################
1504
1505 add_vpp_library (vatclient
1506   SOURCES ip/ip_types_api.c
1507   DEPENDS api_headers
1508 )
1509
1510 ##############################################################################
1511 # VAT2 plugins
1512 ##############################################################################
1513 add_vpp_test_library(vnet
1514   ${VNET_API_FILES}
1515 )
1516
1517 ##############################################################################