blob: c751c100b7157f71293dc17983459972bf5fe8aa [file] [log] [blame]
Damjan Marion7cd468a2016-12-19 23:05:39 +01001# Copyright (c) 2015 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
Damjan Marion724f64c2017-01-11 11:11:00 +010014lib_LTLIBRARIES += libvnet.la
15
Damjan Marion7cd468a2016-12-19 23:05:39 +010016libvnet_la_SOURCES =
Damjan Marionc74a86a2017-01-16 14:00:03 +010017libvnet_la_DEPENDENCIES = \
18 libvppinfra.la \
19 libvlib.la \
20 libsvmdb.la \
21 libsvm.la \
22 libvlibapi.la \
23 libvlibmemory.la \
24 libvlibmemoryclient.la
Damjan Marion7cd468a2016-12-19 23:05:39 +010025
Damjan Marionc74a86a2017-01-16 14:00:03 +010026libvnet_la_LIBADD = $(libvnet_la_DEPENDENCIES) -lm -lpthread -ldl -lrt $(DPDK_LD_ADD)
27libvnet_la_LDFLAGS = $(DPDK_LD_FLAGS)
Damjan Marion45a00c42017-01-08 15:34:50 +010028
Damjan Mariona9a951f2017-01-16 22:06:10 +010029if WITH_LIBSSL
Damjan Marion45a00c42017-01-08 15:34:50 +010030libvnet_la_LIBADD += -lcrypto
31endif
Damjan Marion7cd468a2016-12-19 23:05:39 +010032
33########################################
34# Generic stuff
35########################################
36libvnet_la_SOURCES += \
37 vnet/config.c \
38 vnet/devices/devices.c \
39 vnet/handoff.c \
40 vnet/interface.c \
41 vnet/interface_api.c \
42 vnet/interface_cli.c \
43 vnet/interface_format.c \
44 vnet/interface_output.c \
45 vnet/misc.c \
46 vnet/replication.c \
47 vnet/rewrite.c
48
49nobase_include_HEADERS += \
50 vnet/api_errno.h \
51 vnet/buffer.h \
52 vnet/config.h \
53 vnet/devices/devices.h \
54 vnet/global_funcs.h \
55 vnet/handoff.h \
56 vnet/interface.h \
57 vnet/interface.api.h \
58 vnet/interface_funcs.h \
59 vnet/l3_types.h \
60 vnet/pipeline.h \
61 vnet/replication.h \
62 vnet/rewrite.h \
63 vnet/vnet.h \
64 vnet/vnet_all_api_h.h \
65 vnet/vnet_msg_enum.h
66
67API_FILES += vnet/interface.api
68
69########################################
70# Policer infra
71########################################
72
73libvnet_la_SOURCES += \
74 vnet/policer/node_funcs.c \
75 vnet/policer/policer.c \
76 vnet/policer/xlate.c
77
78nobase_include_HEADERS += \
79 vnet/policer/police.h \
80 vnet/policer/policer.h \
81 vnet/policer/xlate.h
82
83########################################
84# Cop - junk filter
85########################################
86
87libvnet_la_SOURCES += \
88 vnet/cop/cop.c \
89 vnet/cop/node1.c \
90 vnet/cop/ip4_whitelist.c \
91 vnet/cop/ip6_whitelist.c
92
93nobase_include_HEADERS += \
94 vnet/cop/cop.h
95
96########################################
97# Layer 2 protocols go here
98########################################
99
100########################################
101# Layer 2 protocol: Ethernet
102########################################
103libvnet_la_SOURCES += \
104 vnet/ethernet/arp.c \
105 vnet/ethernet/format.c \
106 vnet/ethernet/init.c \
107 vnet/ethernet/interface.c \
108 vnet/ethernet/node.c \
109 vnet/ethernet/pg.c
110
111nobase_include_HEADERS += \
112 vnet/ethernet/arp_packet.h \
113 vnet/ethernet/error.def \
114 vnet/ethernet/ethernet.h \
115 vnet/ethernet/packet.h \
116 vnet/ethernet/types.def
117
118########################################
119# Layer 2 protocol: Ethernet bridging
120########################################
121libvnet_la_SOURCES += \
122 vnet/l2/feat_bitmap.c \
123 vnet/l2/l2_api.c \
124 vnet/l2/l2_bd.c \
125 vnet/l2/l2_bvi.c \
126 vnet/l2/l2_input_classify.c \
127 vnet/l2/l2_output_classify.c \
128 vnet/l2/l2_efp_filter.c \
129 vnet/l2/l2_fib.c \
130 vnet/l2/l2_flood.c \
131 vnet/l2/l2_fwd.c \
132 vnet/l2/l2_input_acl.c \
133 vnet/l2/l2_input.c \
134 vnet/l2/l2_input_vtr.c \
135 vnet/l2/l2_learn.c \
136 vnet/l2/l2_output_acl.c \
137 vnet/l2/l2_output.c \
138 vnet/l2/l2_patch.c \
139 vnet/l2/l2_rw.c \
140 vnet/l2/l2_vtr.c \
141 vnet/l2/l2_xcrw.c
142
143nobase_include_HEADERS += \
144 vnet/l2/feat_bitmap.h \
145 vnet/l2/l2_input.h \
146 vnet/l2/l2_output.h \
147 vnet/l2/l2_vtr.h \
148 vnet/l2/l2_input_vtr.h \
149 vnet/l2/l2_efp_filter.h \
150 vnet/l2/l2_fwd.h \
151 vnet/l2/l2_bd.h \
152 vnet/l2/l2_bvi.h \
153 vnet/l2/l2_flood.h \
154 vnet/l2/l2_fib.h \
155 vnet/l2/l2_rw.h \
156 vnet/l2/l2_xcrw.h \
157 vnet/l2/l2_classify.h \
158 vnet/l2/l2.api.h
159
160API_FILES += vnet/l2/l2.api
161
162########################################
163# Layer 2 protocol: SRP
164########################################
165libvnet_la_SOURCES += \
166 vnet/srp/format.c \
167 vnet/srp/interface.c \
168 vnet/srp/node.c \
169 vnet/srp/pg.c
170
171nobase_include_HEADERS += \
172 vnet/srp/packet.h \
173 vnet/srp/srp.h
174
175########################################
176# Layer 2 protocol: PPP
177########################################
178libvnet_la_SOURCES += \
179 vnet/ppp/node.c \
180 vnet/ppp/pg.c \
181 vnet/ppp/ppp.c
182
183nobase_include_HEADERS += \
184 vnet/ppp/error.def \
185 vnet/ppp/ppp.h \
186 vnet/ppp/packet.h
187
188########################################
189# Layer 2 protocol: HDLC
190########################################
191libvnet_la_SOURCES += \
192 vnet/hdlc/node.c \
193 vnet/hdlc/pg.c \
194 vnet/hdlc/hdlc.c
195
196nobase_include_HEADERS += \
197 vnet/hdlc/error.def \
198 vnet/hdlc/hdlc.h \
199 vnet/hdlc/packet.h
200
201########################################
202# Layer 2 protocol: LLC
203########################################
204libvnet_la_SOURCES += \
205 vnet/llc/llc.c \
206 vnet/llc/node.c \
207 vnet/llc/pg.c
208
209nobase_include_HEADERS += \
210 vnet/llc/llc.h
211
212########################################
213# Layer 2 protocol: SNAP
214########################################
215libvnet_la_SOURCES += \
216 vnet/snap/snap.c \
217 vnet/snap/node.c \
218 vnet/snap/pg.c
219
220nobase_include_HEADERS += \
221 vnet/snap/snap.h
222
223########################################
224# Layer 2 / vxlan
225########################################
226libvnet_la_SOURCES += \
227 vnet/vxlan/vxlan.c \
228 vnet/vxlan/encap.c \
229 vnet/vxlan/decap.c \
230 vnet/vxlan/vxlan_api.c
231
232nobase_include_HEADERS += \
233 vnet/vxlan/vxlan.h \
234 vnet/vxlan/vxlan_packet.h \
235 vnet/vxlan/vxlan_error.def \
236 vnet/vxlan/vxlan.api.h
237
238API_FILES += vnet/vxlan/vxlan.api
239
240########################################
241# Layer 2 / CDP
242########################################
243libvnet_la_SOURCES += \
244 vnet/cdp/cdp_input.c \
245 vnet/cdp/cdp_node.c \
246 vnet/cdp/cdp_periodic.c
247
248nobase_include_HEADERS += \
249 vnet/cdp/cdp_protocol.h
250
251########################################
252# Layer 2 / LLDP
253########################################
254libvnet_la_SOURCES += \
255 vnet/lldp/lldp_input.c \
256 vnet/lldp/lldp_node.c \
257 vnet/lldp/lldp_output.c \
258 vnet/lldp/lldp_cli.c
259
260nobase_include_HEADERS += \
261 vnet/lldp/lldp_protocol.h
262
263########################################
264# Layer 2/3 "classify"
265########################################
266libvnet_la_SOURCES += \
267 vnet/classify/vnet_classify.c \
268 vnet/classify/ip_classify.c \
269 vnet/classify/input_acl.c \
270 vnet/classify/policer_classify.c \
271 vnet/classify/flow_classify.c \
272 vnet/classify/flow_classify_node.c \
Pavel Kotucekd2c97d92017-01-24 10:58:12 +0100273 vnet/classify/vnet_classify.h \
274 vnet/classify/classify_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100275
276nobase_include_HEADERS += \
277 vnet/classify/vnet_classify.h \
278 vnet/classify/input_acl.h \
279 vnet/classify/policer_classify.h \
Pavel Kotucekd2c97d92017-01-24 10:58:12 +0100280 vnet/classify/flow_classify.h \
281 vnet/classify/classify.api.h
282
283API_FILES += vnet/classify/classify.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100284
285########################################
286# Layer 3 protocols go here
287########################################
288
289########################################
290# Layer 3 protocol: IP v4/v6
291########################################
292libvnet_la_SOURCES += \
293 vnet/ip/format.c \
294 vnet/ip/icmp4.c \
295 vnet/ip/icmp6.c \
296 vnet/ip/ip46_cli.c \
297 vnet/ip/ip4_format.c \
298 vnet/ip/ip4_forward.c \
299 vnet/ip/ip4_input.c \
300 vnet/ip/ip4_mtrie.c \
301 vnet/ip/ip4_pg.c \
302 vnet/ip/ip4_source_and_port_range_check.c \
303 vnet/ip/ip4_source_check.c \
304 vnet/ip/ip6_format.c \
305 vnet/ip/ip6_forward.c \
306 vnet/ip/ip6_hop_by_hop.c \
307 vnet/ip/ip6_input.c \
308 vnet/ip/ip6_neighbor.c \
309 vnet/ip/ip6_pg.c \
310 vnet/ip/ip_api.c \
311 vnet/ip/ip_checksum.c \
312 vnet/ip/ip_frag.c \
313 vnet/ip/ip.h \
314 vnet/ip/ip_init.c \
315 vnet/ip/ip_input_acl.c \
316 vnet/ip/lookup.c \
317 vnet/ip/ping.c \
318 vnet/ip/punt.c \
319 vnet/ip/udp_format.c \
320 vnet/ip/udp_init.c \
321 vnet/ip/udp_local.c \
322 vnet/ip/udp_pg.c
323
324nobase_include_HEADERS += \
325 vnet/ip/format.h \
326 vnet/ip/icmp46_packet.h \
327 vnet/ip/icmp4.h \
328 vnet/ip/icmp6.h \
329 vnet/ip/igmp_packet.h \
330 vnet/ip/ip.api.h \
331 vnet/ip/ip4_error.h \
332 vnet/ip/ip4.h \
333 vnet/ip/ip4_mtrie.h \
334 vnet/ip/ip4_packet.h \
335 vnet/ip/ip6_error.h \
336 vnet/ip/ip6.h \
337 vnet/ip/ip6_hop_by_hop.h \
338 vnet/ip/ip6_hop_by_hop_packet.h \
339 vnet/ip/ip6_packet.h \
340 vnet/ip/ip6_neighbor.h \
341 vnet/ip/ip.h \
342 vnet/ip/ip_packet.h \
343 vnet/ip/ip_source_and_port_range_check.h \
344 vnet/ip/lookup.h \
345 vnet/ip/ports.def \
346 vnet/ip/protocols.def \
347 vnet/ip/punt_error.def \
348 vnet/ip/punt.h \
349 vnet/ip/tcp_packet.h \
350 vnet/ip/udp_error.def \
351 vnet/ip/udp.h \
352 vnet/ip/udp_packet.h
353
354API_FILES += vnet/ip/ip.api
355
356########################################
357# Bidirectional Forwarding Detection
358########################################
359
360nobase_include_HEADERS += \
361 vnet/bfd/bfd_protocol.h \
362 vnet/bfd/bfd_main.h \
363 vnet/bfd/bfd_api.h \
364 vnet/bfd/bfd_udp.h \
365 vnet/bfd/bfd.api.h
366
367libvnet_la_SOURCES += \
368 vnet/bfd/bfd_api.h \
369 vnet/bfd/bfd_udp.c \
370 vnet/bfd/bfd_main.c \
371 vnet/bfd/bfd_protocol.c \
372 vnet/bfd/bfd_api.c
373
374API_FILES += vnet/bfd/bfd.api
375
376########################################
377# Layer 3 protocol: IPSec
378########################################
Damjan Mariona9a951f2017-01-16 22:06:10 +0100379if WITH_LIBSSL
Damjan Marion7cd468a2016-12-19 23:05:39 +0100380libvnet_la_SOURCES += \
381 vnet/ipsec/ipsec.c \
382 vnet/ipsec/ipsec_cli.c \
383 vnet/ipsec/ipsec_format.c \
384 vnet/ipsec/ipsec_input.c \
385 vnet/ipsec/ipsec_if.c \
386 vnet/ipsec/ipsec_if_in.c \
387 vnet/ipsec/ipsec_if_out.c \
388 vnet/ipsec/esp_encrypt.c \
389 vnet/ipsec/esp_decrypt.c \
390 vnet/ipsec/ikev2.c \
391 vnet/ipsec/ikev2_crypto.c \
392 vnet/ipsec/ikev2_cli.c \
393 vnet/ipsec/ikev2_payload.c \
394 vnet/ipsec/ikev2_format.c \
395 vnet/ipsec/ipsec_api.c
396
397API_FILES += vnet/ipsec/ipsec.api
398
399if WITH_DPDK_CRYPTO
400libvnet_la_SOURCES += \
401 vnet/devices/dpdk/ipsec/esp_encrypt.c \
402 vnet/devices/dpdk/ipsec/esp_decrypt.c \
403 vnet/devices/dpdk/ipsec/crypto_node.c \
404 vnet/devices/dpdk/ipsec/cli.c \
405 vnet/devices/dpdk/ipsec/ipsec.c
406endif
407endif
408
409libvnet_la_SOURCES += \
410 vnet/ipsec/ipsec_output.c
411
412nobase_include_HEADERS += \
413 vnet/ipsec/ipsec.h \
414 vnet/ipsec/esp.h \
415 vnet/ipsec/ikev2.h \
416 vnet/ipsec/ikev2_priv.h \
417 vnet/ipsec/ipsec.api.h
418if WITH_DPDK_CRYPTO
419nobase_include_HEADERS += \
420 vnet/devices/dpdk/ipsec/ipsec.h \
421 vnet/devices/dpdk/ipsec/esp.h
422endif
423
424########################################
425# Layer 3 protocol: osi
426########################################
427libvnet_la_SOURCES += \
428 vnet/osi/node.c \
429 vnet/osi/osi.c \
430 vnet/osi/pg.c
431
432nobase_include_HEADERS += \
433 vnet/osi/osi.h
434
435########################################
436# Layer 3 protocol: MAP
437########################################
438libvnet_la_SOURCES += \
439 vnet/map/map.c \
440 vnet/map/map_dpo.c \
441 vnet/map/ip4_map.c \
442 vnet/map/ip6_map.c \
443 vnet/map/ip4_map_t.c \
444 vnet/map/ip6_map_t.c \
445 vnet/map/map_api.c
446
447nobase_include_HEADERS += \
448 vnet/map/map.h \
449 vnet/map/map_dpo.h \
450 vnet/map/map.api.h
451
452API_FILES += vnet/map/map.api
453
454if ENABLE_TESTS
455TESTS += test_map
456test_map_SOURCES = \
457 vnet/map/test.c
458test_map_CPPFLAGS = $(AM_CPPFLAGS) -DCLIB_DEBUG
459
460test_map_LDADD = libvnet.la libvppinfra.la libvlib.la \
Damjan Marion0eca04d2017-01-03 20:11:35 +0100461 -lpthread -lvlibmemory -lvlibapi \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100462 -ldl -lsvm -lrt
463
464test_map_LDFLAGS = -static
465endif
466
467
468########################################
469# Tunnel protocol: gre
470########################################
471libvnet_la_SOURCES += \
472 vnet/gre/gre.c \
473 vnet/gre/node.c \
474 vnet/gre/interface.c \
475 vnet/gre/pg.c \
476 vnet/gre/gre_api.c
477
478nobase_include_HEADERS += \
479 vnet/gre/gre.h \
480 vnet/gre/packet.h \
481 vnet/gre/error.def \
482 vnet/gre/gre.api.h
483
484API_FILES += vnet/gre/gre.api
485
486########################################
487# Tunnel protocol: l2tpv3
488########################################
489libvnet_la_SOURCES += \
490 vnet/l2tp/l2tp.c \
491 vnet/l2tp/encap.c \
492 vnet/l2tp/decap.c \
493 vnet/l2tp/pg.c \
494 vnet/l2tp/l2tp_api.c
495
496nobase_include_HEADERS += \
497 vnet/l2tp/l2tp.h \
498 vnet/l2tp/packet.h \
499 vnet/l2tp/l2tp.api.h
500
501API_FILES += vnet/l2tp/l2tp.api
502
503########################################
504# Tunnel protocol: gre+mpls
505########################################
506libvnet_la_SOURCES += \
507 vnet/mpls/mpls.c \
508 vnet/mpls/mpls_lookup.c \
509 vnet/mpls/mpls_output.c \
510 vnet/mpls/mpls_features.c \
511 vnet/mpls/node.c \
512 vnet/mpls/interface.c \
513 vnet/mpls/mpls_tunnel.c \
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100514 vnet/mpls/pg.c \
515 vnet/mpls/mpls_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100516
517nobase_include_HEADERS += \
518 vnet/mpls/mpls.h \
519 vnet/mpls/mpls_types.h \
520 vnet/mpls/mpls_tunnel.h \
521 vnet/mpls/packet.h \
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100522 vnet/mpls/error.def \
523 vnet/mpls/mpls.api.h
Damjan Marion7cd468a2016-12-19 23:05:39 +0100524
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100525API_FILES += vnet/mpls/mpls.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100526
527########################################
528# Tunnel protocol: vxlan-gpe
529########################################
530
531libvnet_la_SOURCES += \
532 vnet/vxlan-gpe/vxlan_gpe.c \
533 vnet/vxlan-gpe/encap.c \
534 vnet/vxlan-gpe/decap.c \
535 vnet/vxlan-gpe/vxlan_gpe_api.c
536
537nobase_include_HEADERS += \
538 vnet/vxlan-gpe/vxlan_gpe.h \
539 vnet/vxlan-gpe/vxlan_gpe_packet.h \
540 vnet/vxlan-gpe/vxlan_gpe_error.def \
541 vnet/vxlan-gpe/vxlan_gpe.api.h
542
543API_FILES += vnet/vxlan-gpe/vxlan_gpe.api
544
545########################################
546# Tunnel protocol: ipsec+gre
547########################################
548libvnet_la_SOURCES += \
549 vnet/ipsec-gre/ipsec_gre.c \
550 vnet/ipsec-gre/node.c \
551 vnet/ipsec-gre/interface.c \
552 vnet/ipsec-gre/ipsec_gre_api.c
553
554nobase_include_HEADERS += \
555 vnet/ipsec-gre/ipsec_gre.h \
556 vnet/ipsec-gre/error.def \
557 vnet/ipsec-gre/ipsec_gre.api.h
558
559API_FILES += vnet/ipsec-gre/ipsec_gre.api
560
561########################################
562# LISP control plane: lisp-cp
563########################################
564
565libvnet_la_SOURCES += \
566 vnet/lisp-cp/lisp_types.c \
567 vnet/lisp-cp/lisp_cp_dpo.c \
568 vnet/lisp-cp/control.c \
569 vnet/lisp-cp/gid_dictionary.c \
570 vnet/lisp-cp/lisp_msg_serdes.c \
571 vnet/lisp-cp/packets.c \
572 vnet/lisp-cp/lisp_api.c
573
574nobase_include_HEADERS += \
575 vnet/lisp-cp/lisp_types.h \
576 vnet/lisp-cp/packets.h \
577 vnet/lisp-cp/gid_dictionary.h \
578 vnet/lisp-cp/lisp_cp_messages.h \
579 vnet/lisp-cp/lisp_msg_serdes.h \
580 vnet/lisp-cp/control.h \
581 vnet/lisp-cp/lisp.api.h
582
583API_FILES += vnet/lisp-cp/lisp.api
584
585if ENABLE_TESTS
586LDS = \
587 libvppinfra.la \
588 libvnet.la \
589 libvlib.la \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100590 libsvm.la \
591 libsvmdb.la \
592 libvlibapi.la \
593 libvlibmemory.la \
Damjan Marionc74a86a2017-01-16 14:00:03 +0100594 -lpthread -ldl -lrt -lm
Damjan Marion7cd468a2016-12-19 23:05:39 +0100595
596TESTS += test_cp_serdes test_lisp_types
597
598test_cp_serdes_SOURCES = \
599 tests/vnet/lisp-cp/test_cp_serdes.c \
600 vnet/lisp-cp/lisp_msg_serdes.c \
601 vnet/lisp-cp/lisp_types.c \
602 vnet/lisp-cp/packets.c \
603 vnet/ip/ip_checksum.c
604
605test_lisp_types_SOURCES = \
606 tests/vnet/lisp-cp/test_lisp_types.c \
607 vnet/lisp-cp/lisp_types.c
608
609test_cp_serdes_CPPFLAGS = $(AM_CPPFLAGS) -DCLIB_DEBUG
610test_lisp_types_CPPFLAGS = $(AM_CPPFLAGS) -DCLIB_DEBUG
611
Damjan Marionc74a86a2017-01-16 14:00:03 +0100612test_cp_serdes_LDADD = $(LDS)
613test_lisp_types_LDADD = $(LDS)
Damjan Marion7cd468a2016-12-19 23:05:39 +0100614endif
615
616########################################
617# Tunnel protocol: lisp-gpe
618########################################
619
620libvnet_la_SOURCES += \
621 vnet/lisp-gpe/lisp_gpe.c \
622 vnet/lisp-gpe/lisp_gpe_sub_interface.c \
623 vnet/lisp-gpe/lisp_gpe_adjacency.c \
624 vnet/lisp-gpe/lisp_gpe_tunnel.c \
625 vnet/lisp-gpe/lisp_gpe_fwd_entry.c \
626 vnet/lisp-gpe/lisp_gpe_tenant.c \
627 vnet/lisp-gpe/interface.c \
628 vnet/lisp-gpe/decap.c \
629 vnet/lisp-gpe/lisp_gpe_api.c
630
631nobase_include_HEADERS += \
632 vnet/lisp-gpe/lisp_gpe.h \
633 vnet/lisp-gpe/lisp_gpe_fwd_entry.h \
634 vnet/lisp-gpe/lisp_gpe_tenant.h \
635 vnet/lisp-gpe/lisp_gpe_packet.h \
636 vnet/lisp-gpe/lisp_gpe_error.def \
637 vnet/lisp-gpe/lisp_gpe.api.h
638
639API_FILES += vnet/lisp-gpe/lisp_gpe.api
640
641if ENABLE_TESTS
642TESTS += test_test
643
644test_test_SOURCES = tests/vnet/lisp-gpe/test.c
645
646test_test_CPPFLAGS = $(AM_CPPFLAGS) -DCLIB_DEBUG
647
648test_test_LDADD = $(LIBOBJS)
649
650noinst_PROGRAMS += $(TESTS)
651check_PROGRAMS += $(TESTS)
652endif
653
654########################################
655# DHCP client
656########################################
657libvnet_la_SOURCES += \
658 vnet/dhcp/client.c \
659 vnet/dhcp/client.h
660
661nobase_include_HEADERS += \
662 vnet/dhcp/client.h
663
664########################################
665# DHCP proxy
666########################################
667libvnet_la_SOURCES += \
668 vnet/dhcp/proxy_node.c \
669 vnet/dhcp/proxy.h
670
671nobase_include_HEADERS += \
672 vnet/dhcp/packet.h \
673 vnet/dhcp/proxy.h \
674 vnet/dhcp/proxy_error.def
675
676########################################
677# ipv6 segment routing
678########################################
679
Damjan Mariona9a951f2017-01-16 22:06:10 +0100680if WITH_LIBSSL
Damjan Marion7cd468a2016-12-19 23:05:39 +0100681libvnet_la_SOURCES += \
682 vnet/sr/sr.c \
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100683 vnet/sr/sr_replicate.c \
684 vnet/sr/sr_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100685endif
686
687nobase_include_HEADERS += \
688 vnet/sr/sr_packet.h \
689 vnet/sr/sr_error.def \
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100690 vnet/sr/sr.h \
691 vnet/sr/sr.api.h
692
693API_FILES += vnet/sr/sr.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100694
695########################################
696# DHCPv6 proxy
697########################################
698libvnet_la_SOURCES += \
699 vnet/dhcpv6/proxy_node.c
700
701nobase_include_HEADERS += \
702 vnet/dhcpv6/packet.h \
703 vnet/dhcpv6/proxy.h \
704 vnet/dhcpv6/proxy_error.def
705
706########################################
707# IPFIX / netflow v10
708########################################
709libvnet_la_SOURCES += \
Pavel Kotucekeb9e6662017-01-24 13:40:26 +0100710 vnet/flow/flow_report.c \
711 vnet/flow/flow_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100712
713nobase_include_HEADERS += \
714 vnet/flow/flow_report.h \
715 vnet/flow/ipfix_info_elements.h \
Pavel Kotucekeb9e6662017-01-24 13:40:26 +0100716 vnet/flow/ipfix_packet.h \
717 vnet/flow/flow.api.h
718
719API_FILES += vnet/flow/flow.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100720
721########################################
722# IPFIX classify code
723########################################
724
725libvnet_la_SOURCES += \
726 vnet/flow/flow_report_classify.c
727
728nobase_include_HEADERS += \
729 vnet/flow/flow_report_classify.h
730
731########################################
732# lawful intercept
733########################################
734
735libvnet_la_SOURCES += \
736 vnet/lawful-intercept/lawful_intercept.c \
737 vnet/lawful-intercept/node.c
738
739nobase_include_HEADERS += \
740 vnet/lawful-intercept/lawful_intercept.h
741
742########################################
743# SPAN (port mirroring)
744########################################
745
746libvnet_la_SOURCES += \
747 vnet/span/span_api.c \
748 vnet/span/span.c \
749 vnet/span/node.c
750
751nobase_include_HEADERS += \
752 vnet/span/span.api.h \
753 vnet/span/span.h
754
755API_FILES += vnet/span/span.api
756
757########################################
758# Packet generator
759########################################
760
761libvnet_la_SOURCES += \
762 vnet/pg/cli.c \
763 vnet/pg/edit.c \
764 vnet/pg/init.c \
765 vnet/pg/input.c \
766 vnet/pg/output.c \
767 vnet/pg/stream.c
768
769nobase_include_HEADERS += \
770 vnet/pg/pg.h \
771 vnet/pg/edit.h
772
773########################################
774# DPDK
775########################################
776if WITH_DPDK
777libvnet_la_SOURCES += \
Damjan Marion878c6092017-01-04 13:19:27 +0100778 vnet/devices/dpdk/buffer.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100779 vnet/devices/dpdk/dpdk_priv.h \
780 vnet/devices/dpdk/device.c \
781 vnet/devices/dpdk/format.c \
782 vnet/devices/dpdk/init.c \
Damjan Marionca800252017-01-16 21:29:39 +0100783 vnet/devices/dpdk/main.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100784 vnet/devices/dpdk/node.c \
Damjan Marion878c6092017-01-04 13:19:27 +0100785 vnet/devices/dpdk/thread.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100786 vnet/devices/dpdk/hqos.c \
Pavel Kotucek738f3f22017-01-09 15:11:03 +0100787 vnet/devices/dpdk/cli.c \
788 vnet/devices/dpdk/dpdk_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100789
790nobase_include_HEADERS += \
Pavel Kotucek738f3f22017-01-09 15:11:03 +0100791 vnet/devices/dpdk/dpdk.h \
792 vnet/devices/dpdk/dpdk.api.h
793
794API_FILES += vnet/devices/dpdk/dpdk.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100795else
796libvnet_la_SOURCES += \
797 vnet/devices/nic/ixge.c \
798 vnet/devices/nic/ixge.h \
799 vnet/devices/nic/sfp.c \
800 vnet/devices/nic/sfp.h
801endif
802
803########################################
804# virtio
805########################################
806
807libvnet_la_SOURCES += \
808 vnet/devices/virtio/vhost-user.c \
809 vnet/devices/virtio/vhost_user_api.c
810
811nobase_include_HEADERS += \
812 vnet/devices/virtio/vhost-user.h \
813 vnet/devices/virtio/vhost_user.api.h
814
815API_FILES += vnet/devices/virtio/vhost_user.api
816
817########################################
818# ssvm ethernet
819########################################
820libvnet_la_SOURCES += \
821 vnet/devices/ssvm/ssvm_eth.c \
822 vnet/devices/ssvm/node.c
823
824nobase_include_HEADERS += \
825 vnet/devices/ssvm/ssvm_eth.h
826
827########################################
828# Linux packet interface
829########################################
830
831libvnet_la_SOURCES += \
832 vnet/devices/af_packet/af_packet.c \
833 vnet/devices/af_packet/device.c \
834 vnet/devices/af_packet/node.c \
835 vnet/devices/af_packet/cli.c \
836 vnet/devices/af_packet/af_packet_api.c
837
838nobase_include_HEADERS += \
839 vnet/devices/af_packet/af_packet.h \
840 vnet/devices/af_packet/af_packet.api.h
841
842API_FILES += vnet/devices/af_packet/af_packet.api
843
844########################################
845# NETMAP interface
846########################################
847
848libvnet_la_SOURCES += \
849 vnet/devices/netmap/netmap.c \
850 vnet/devices/netmap/device.c \
851 vnet/devices/netmap/node.c \
852 vnet/devices/netmap/cli.c \
853 vnet/devices/netmap/netmap_api.c
854
855nobase_include_HEADERS += \
856 vnet/devices/netmap/netmap.h \
857 vnet/devices/netmap/netmap.api.h
858
859API_FILES += vnet/devices/netmap/netmap.api
860
861########################################
862# Driver feature graph arc support
863########################################
864
865libvnet_la_SOURCES += \
866 vnet/feature/feature.c \
867 vnet/feature/registration.c
868
869nobase_include_HEADERS += \
870 vnet/feature/feature.h
871
872########################################
873# Unix kernel related
874########################################
875
876# FIXME: vnet/unix/hgshm.c
877
878libvnet_la_SOURCES += \
879 vnet/unix/gdb_funcs.c \
880 vnet/unix/pcap.c \
881 vnet/unix/tap_api.c \
882 vnet/unix/tapcli.c \
883 vnet/unix/tuntap.c
884
885nobase_include_HEADERS += \
886 vnet/unix/pcap.h \
887 vnet/unix/tuntap.h \
888 vnet/unix/tap.api.h \
889 vnet/unix/tapcli.h
890
891API_FILES += vnet/unix/tap.api
892
893########################################
894# FIB
895########################################
896
897libvnet_la_SOURCES += \
898 vnet/fib/fib.c \
899 vnet/fib/fib_test.c \
900 vnet/fib/ip4_fib.c \
901 vnet/fib/ip6_fib.c \
902 vnet/fib/mpls_fib.c \
903 vnet/fib/fib_table.c \
904 vnet/fib/fib_walk.c \
905 vnet/fib/fib_types.c \
906 vnet/fib/fib_node.c \
907 vnet/fib/fib_node_list.c \
908 vnet/fib/fib_entry.c \
909 vnet/fib/fib_entry_src.c \
910 vnet/fib/fib_entry_src_rr.c \
911 vnet/fib/fib_entry_src_interface.c \
912 vnet/fib/fib_entry_src_default_route.c \
913 vnet/fib/fib_entry_src_special.c \
914 vnet/fib/fib_entry_src_api.c \
915 vnet/fib/fib_entry_src_adj.c \
916 vnet/fib/fib_entry_src_mpls.c \
917 vnet/fib/fib_entry_src_lisp.c \
918 vnet/fib/fib_entry_cover.c \
919 vnet/fib/fib_entry_delegate.c \
920 vnet/fib/fib_path_list.c \
921 vnet/fib/fib_path.c \
922 vnet/fib/fib_path_ext.c \
923 vnet/fib/fib_urpf_list.c \
924 vnet/fib/fib_attached_export.c
925
926nobase_include_HEADERS += \
927 vnet/fib/fib.h \
928 vnet/fib/fib_api.h \
929 vnet/fib/ip4_fib.h \
930 vnet/fib/ip6_fib.h \
931 vnet/fib/fib_types.h \
932 vnet/fib/fib_table.h \
933 vnet/fib/fib_node.h \
934 vnet/fib/fib_node_list.h \
935 vnet/fib/fib_entry.h \
936 vnet/fib/fib_entry_delegate.h
937
938########################################
939# ADJ
940########################################
941
942libvnet_la_SOURCES += \
943 vnet/adj/adj_nbr.c \
944 vnet/adj/adj_rewrite.c \
945 vnet/adj/adj_glean.c \
946 vnet/adj/adj_midchain.c \
947 vnet/adj/adj_l2.c \
948 vnet/adj/adj.c
949
950nobase_include_HEADERS += \
951 vnet/adj/adj.h \
952 vnet/adj/adj_types.h \
953 vnet/adj/adj_rewrite.h \
954 vnet/adj/adj_glean.h \
955 vnet/adj/adj_nbr.h
956
957########################################
958# Data-Plane Objects
959########################################
960
961libvnet_la_SOURCES += \
962 vnet/dpo/dpo.c \
963 vnet/dpo/drop_dpo.c \
964 vnet/dpo/ip_null_dpo.c \
965 vnet/dpo/punt_dpo.c \
966 vnet/dpo/receive_dpo.c \
967 vnet/dpo/load_balance.c \
968 vnet/dpo/load_balance_map.c \
969 vnet/dpo/lookup_dpo.c \
970 vnet/dpo/classify_dpo.c \
971 vnet/dpo/mpls_label_dpo.c
972
973nobase_include_HEADERS += \
974 vnet/dpo/load_balance.h \
975 vnet/dpo/drop_dpo.h \
976 vnet/dpo/lookup_dpo.h \
977 vnet/dpo/punt_dpo.h \
978 vnet/dpo/classify_dpo.h \
979 vnet/dpo/receive_dpo.h \
980 vnet/dpo/ip_null_dpo.h \
981 vnet/dpo/dpo.h
982
983########################################
984# Plugin client library
985########################################
986
Damjan Marion7cd468a2016-12-19 23:05:39 +0100987nobase_include_HEADERS += \
988 vnet/plugin/plugin.h
989
Damjan Marion7cd468a2016-12-19 23:05:39 +0100990pcap2pg_SOURCES = \
991 vnet/unix/pcap2pg.c \
992 vnet/unix/pcap.h
993
994pcap2pg_LDFLAGS = -static
995pcap2pg_LDADD = libvnet.la libvppinfra.la -lpthread libvlibmemory.la -lm -ldl
996
997noinst_PROGRAMS += pcap2pg
998
999# vi:syntax=automake