blob: 83dbbc0476b3c5e63648ad20c69c8ec125ee3e88 [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 \
Dave Barach654ceaf2017-03-29 16:59:02 -040022 libvlibmemory.la
Damjan Marion7cd468a2016-12-19 23:05:39 +010023
Damjan Marionc3a814b2017-02-28 19:22:22 +010024libvnet_la_LIBADD = $(libvnet_la_DEPENDENCIES) -lm -lpthread -ldl -lrt
Damjan Marion45a00c42017-01-08 15:34:50 +010025
Damjan Mariona9a951f2017-01-16 22:06:10 +010026if WITH_LIBSSL
Damjan Marion45a00c42017-01-08 15:34:50 +010027libvnet_la_LIBADD += -lcrypto
28endif
Damjan Marion7cd468a2016-12-19 23:05:39 +010029
30########################################
31# Generic stuff
32########################################
33libvnet_la_SOURCES += \
Damjan Marionbd846cd2017-11-21 13:12:41 +010034 vnet/buffer.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +010035 vnet/config.c \
36 vnet/devices/devices.c \
Damjan Marion17fdae72017-11-30 20:56:37 +010037 vnet/devices/netlink.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +010038 vnet/handoff.c \
39 vnet/interface.c \
40 vnet/interface_api.c \
41 vnet/interface_cli.c \
42 vnet/interface_format.c \
43 vnet/interface_output.c \
44 vnet/misc.c \
Neale Rannsfa5d1982017-02-20 14:19:51 -080045 vnet/replication.c
Damjan Marion7cd468a2016-12-19 23:05:39 +010046
47nobase_include_HEADERS += \
48 vnet/api_errno.h \
49 vnet/buffer.h \
50 vnet/config.h \
51 vnet/devices/devices.h \
Damjan Marion17fdae72017-11-30 20:56:37 +010052 vnet/devices/netlink.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +010053 vnet/global_funcs.h \
54 vnet/handoff.h \
55 vnet/interface.h \
56 vnet/interface.api.h \
57 vnet/interface_funcs.h \
Matus Fabiana774b532017-05-02 03:15:22 -070058 vnet/ip/ip4_to_ip6.h \
59 vnet/ip/ip6_to_ip4.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +010060 vnet/l3_types.h \
61 vnet/pipeline.h \
62 vnet/replication.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +010063 vnet/vnet.h \
64 vnet/vnet_all_api_h.h \
Gabriel Ganne5842c782017-01-30 13:44:04 +010065 vnet/vnet_msg_enum.h \
Hongjun Nibf4be572017-11-13 20:34:06 +080066 vnet/util/radix.h \
67 vnet/util/refcount.h
Damjan Marion7cd468a2016-12-19 23:05:39 +010068
69API_FILES += vnet/interface.api
70
71########################################
72# Policer infra
73########################################
74
75libvnet_la_SOURCES += \
76 vnet/policer/node_funcs.c \
77 vnet/policer/policer.c \
Pavel Kotucekd9aad292017-01-25 08:45:38 +010078 vnet/policer/xlate.c \
79 vnet/policer/policer_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +010080
81nobase_include_HEADERS += \
82 vnet/policer/police.h \
83 vnet/policer/policer.h \
Pavel Kotucekd9aad292017-01-25 08:45:38 +010084 vnet/policer/xlate.h \
85 vnet/policer/policer.api.h
86
87API_FILES += vnet/policer/policer.api
Damjan Marion7cd468a2016-12-19 23:05:39 +010088
89########################################
90# Cop - junk filter
91########################################
92
93libvnet_la_SOURCES += \
94 vnet/cop/cop.c \
95 vnet/cop/node1.c \
96 vnet/cop/ip4_whitelist.c \
Pavel Kotucek884cf262017-01-25 08:27:15 +010097 vnet/cop/ip6_whitelist.c \
98 vnet/cop/cop_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +010099
100nobase_include_HEADERS += \
Pavel Kotucek884cf262017-01-25 08:27:15 +0100101 vnet/cop/cop.h \
102 vnet/cop/cop.api.h
103
104API_FILES += vnet/cop/cop.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100105
106########################################
107# Layer 2 protocols go here
108########################################
109
110########################################
111# Layer 2 protocol: Ethernet
112########################################
113libvnet_la_SOURCES += \
114 vnet/ethernet/arp.c \
115 vnet/ethernet/format.c \
116 vnet/ethernet/init.c \
117 vnet/ethernet/interface.c \
118 vnet/ethernet/node.c \
Damjan Marion374e2c52017-03-09 20:38:15 +0100119 vnet/ethernet/pg.c \
Pavel Kotucek6899a302017-06-08 08:46:10 +0200120 vnet/ethernet/sfp.c \
121 vnet/ethernet/p2p_ethernet.c \
Pavel Kotucek15ac81c2017-06-20 14:00:26 +0200122 vnet/ethernet/p2p_ethernet_input.c \
Pavel Kotucek6899a302017-06-08 08:46:10 +0200123 vnet/ethernet/p2p_ethernet_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100124
125nobase_include_HEADERS += \
126 vnet/ethernet/arp_packet.h \
127 vnet/ethernet/error.def \
128 vnet/ethernet/ethernet.h \
129 vnet/ethernet/packet.h \
Damjan Marion374e2c52017-03-09 20:38:15 +0100130 vnet/ethernet/types.def \
Pavel Kotucek6899a302017-06-08 08:46:10 +0200131 vnet/ethernet/sfp.h \
132 vnet/ethernet/p2p_ethernet.api.h \
133 vnet/ethernet/p2p_ethernet.h
134
135API_FILES += vnet/ethernet/p2p_ethernet.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100136
137########################################
138# Layer 2 protocol: Ethernet bridging
139########################################
140libvnet_la_SOURCES += \
141 vnet/l2/feat_bitmap.c \
142 vnet/l2/l2_api.c \
143 vnet/l2/l2_bd.c \
144 vnet/l2/l2_bvi.c \
145 vnet/l2/l2_input_classify.c \
146 vnet/l2/l2_output_classify.c \
147 vnet/l2/l2_efp_filter.c \
148 vnet/l2/l2_fib.c \
149 vnet/l2/l2_flood.c \
150 vnet/l2/l2_fwd.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100151 vnet/l2/l2_input.c \
152 vnet/l2/l2_input_vtr.c \
153 vnet/l2/l2_learn.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100154 vnet/l2/l2_output.c \
Andrew Yourtchenko815d7d52018-02-07 11:37:02 +0100155 vnet/l2/l2_in_out_acl.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100156 vnet/l2/l2_patch.c \
157 vnet/l2/l2_rw.c \
158 vnet/l2/l2_vtr.c \
159 vnet/l2/l2_xcrw.c
160
161nobase_include_HEADERS += \
162 vnet/l2/feat_bitmap.h \
163 vnet/l2/l2_input.h \
164 vnet/l2/l2_output.h \
165 vnet/l2/l2_vtr.h \
166 vnet/l2/l2_input_vtr.h \
167 vnet/l2/l2_efp_filter.h \
168 vnet/l2/l2_fwd.h \
169 vnet/l2/l2_bd.h \
170 vnet/l2/l2_bvi.h \
171 vnet/l2/l2_flood.h \
172 vnet/l2/l2_fib.h \
173 vnet/l2/l2_rw.h \
174 vnet/l2/l2_xcrw.h \
175 vnet/l2/l2_classify.h \
176 vnet/l2/l2.api.h
177
178API_FILES += vnet/l2/l2.api
179
180########################################
181# Layer 2 protocol: SRP
182########################################
183libvnet_la_SOURCES += \
184 vnet/srp/format.c \
185 vnet/srp/interface.c \
186 vnet/srp/node.c \
187 vnet/srp/pg.c
188
189nobase_include_HEADERS += \
190 vnet/srp/packet.h \
191 vnet/srp/srp.h
192
193########################################
194# Layer 2 protocol: PPP
195########################################
196libvnet_la_SOURCES += \
197 vnet/ppp/node.c \
198 vnet/ppp/pg.c \
199 vnet/ppp/ppp.c
200
201nobase_include_HEADERS += \
202 vnet/ppp/error.def \
203 vnet/ppp/ppp.h \
204 vnet/ppp/packet.h
205
206########################################
207# Layer 2 protocol: HDLC
208########################################
209libvnet_la_SOURCES += \
210 vnet/hdlc/node.c \
211 vnet/hdlc/pg.c \
212 vnet/hdlc/hdlc.c
213
214nobase_include_HEADERS += \
215 vnet/hdlc/error.def \
216 vnet/hdlc/hdlc.h \
217 vnet/hdlc/packet.h
218
219########################################
220# Layer 2 protocol: LLC
221########################################
222libvnet_la_SOURCES += \
223 vnet/llc/llc.c \
224 vnet/llc/node.c \
225 vnet/llc/pg.c
226
227nobase_include_HEADERS += \
228 vnet/llc/llc.h
229
230########################################
231# Layer 2 protocol: SNAP
232########################################
233libvnet_la_SOURCES += \
234 vnet/snap/snap.c \
235 vnet/snap/node.c \
236 vnet/snap/pg.c
237
238nobase_include_HEADERS += \
239 vnet/snap/snap.h
240
241########################################
242# Layer 2 / vxlan
243########################################
244libvnet_la_SOURCES += \
245 vnet/vxlan/vxlan.c \
246 vnet/vxlan/encap.c \
247 vnet/vxlan/decap.c \
248 vnet/vxlan/vxlan_api.c
249
250nobase_include_HEADERS += \
251 vnet/vxlan/vxlan.h \
252 vnet/vxlan/vxlan_packet.h \
253 vnet/vxlan/vxlan_error.def \
254 vnet/vxlan/vxlan.api.h
255
256API_FILES += vnet/vxlan/vxlan.api
257
258########################################
Marco Varleseb598f1d2017-09-19 14:25:28 +0200259# Layer 2 / Geneve
260########################################
261libvnet_la_SOURCES += \
262 vnet/geneve/geneve.c \
263 vnet/geneve/encap.c \
264 vnet/geneve/decap.c \
265 vnet/geneve/geneve_api.c
266
267nobase_include_HEADERS += \
268 vnet/geneve/geneve.h \
269 vnet/geneve/geneve_packet.h \
270 vnet/geneve/geneve_error.def \
271 vnet/geneve/geneve.api.h
272
273API_FILES += vnet/geneve/geneve.api
274
275########################################
Damjan Marion7cd468a2016-12-19 23:05:39 +0100276# Layer 2 / LLDP
277########################################
278libvnet_la_SOURCES += \
279 vnet/lldp/lldp_input.c \
280 vnet/lldp/lldp_node.c \
281 vnet/lldp/lldp_output.c \
Steve Shin99a0e602017-07-01 04:16:20 +0000282 vnet/lldp/lldp_cli.c \
283 vnet/lldp/lldp_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100284
285nobase_include_HEADERS += \
Steve Shin99a0e602017-07-01 04:16:20 +0000286 vnet/lldp/lldp_protocol.h \
287 vnet/lldp/lldp.h \
288 vnet/lldp/lldp.api.h
289
290API_FILES += vnet/lldp/lldp.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100291
292########################################
293# Layer 2/3 "classify"
294########################################
295libvnet_la_SOURCES += \
296 vnet/classify/vnet_classify.c \
297 vnet/classify/ip_classify.c \
Andrew Yourtchenko815d7d52018-02-07 11:37:02 +0100298 vnet/classify/in_out_acl.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100299 vnet/classify/policer_classify.c \
300 vnet/classify/flow_classify.c \
301 vnet/classify/flow_classify_node.c \
Pavel Kotucekd2c97d92017-01-24 10:58:12 +0100302 vnet/classify/vnet_classify.h \
303 vnet/classify/classify_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100304
305nobase_include_HEADERS += \
306 vnet/classify/vnet_classify.h \
Andrew Yourtchenko815d7d52018-02-07 11:37:02 +0100307 vnet/classify/in_out_acl.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100308 vnet/classify/policer_classify.h \
Pavel Kotucekd2c97d92017-01-24 10:58:12 +0100309 vnet/classify/flow_classify.h \
310 vnet/classify/classify.api.h
311
312API_FILES += vnet/classify/classify.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100313
314########################################
315# Layer 3 protocols go here
316########################################
317
318########################################
319# Layer 3 protocol: IP v4/v6
320########################################
321libvnet_la_SOURCES += \
322 vnet/ip/format.c \
323 vnet/ip/icmp4.c \
324 vnet/ip/icmp6.c \
325 vnet/ip/ip46_cli.c \
326 vnet/ip/ip4_format.c \
327 vnet/ip/ip4_forward.c \
Neale Rannsd91c1db2017-07-31 02:30:50 -0700328 vnet/ip/ip4_punt_drop.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100329 vnet/ip/ip4_input.c \
330 vnet/ip/ip4_mtrie.c \
331 vnet/ip/ip4_pg.c \
332 vnet/ip/ip4_source_and_port_range_check.c \
333 vnet/ip/ip4_source_check.c \
Klement Sekera75e7d132017-09-20 08:26:30 +0200334 vnet/ip/ip4_reassembly.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100335 vnet/ip/ip6_format.c \
336 vnet/ip/ip6_forward.c \
Neale Ranns53da2212018-02-24 02:11:19 -0800337 vnet/ip/ip6_ll_table.c \
338 vnet/ip/ip6_ll_types.c \
Neale Rannsd91c1db2017-07-31 02:30:50 -0700339 vnet/ip/ip6_punt_drop.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100340 vnet/ip/ip6_hop_by_hop.c \
341 vnet/ip/ip6_input.c \
342 vnet/ip/ip6_neighbor.c \
343 vnet/ip/ip6_pg.c \
Klement Sekera75e7d132017-09-20 08:26:30 +0200344 vnet/ip/ip6_reassembly.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100345 vnet/ip/ip_api.c \
346 vnet/ip/ip_checksum.c \
347 vnet/ip/ip_frag.c \
Florin Corascea194d2017-10-02 00:18:51 -0700348 vnet/ip/ip.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100349 vnet/ip/ip_init.c \
Andrew Yourtchenko815d7d52018-02-07 11:37:02 +0100350 vnet/ip/ip_in_out_acl.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100351 vnet/ip/lookup.c \
352 vnet/ip/ping.c \
Neale Rannsb8d44812017-11-10 06:53:54 -0800353 vnet/ip/punt_api.c \
Dave Barach68b0fb02017-02-28 15:15:56 -0500354 vnet/ip/punt.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100355
356nobase_include_HEADERS += \
357 vnet/ip/format.h \
358 vnet/ip/icmp46_packet.h \
359 vnet/ip/icmp4.h \
360 vnet/ip/icmp6.h \
361 vnet/ip/igmp_packet.h \
362 vnet/ip/ip.api.h \
363 vnet/ip/ip4_error.h \
364 vnet/ip/ip4.h \
365 vnet/ip/ip4_mtrie.h \
366 vnet/ip/ip4_packet.h \
367 vnet/ip/ip6_error.h \
368 vnet/ip/ip6.h \
369 vnet/ip/ip6_hop_by_hop.h \
370 vnet/ip/ip6_hop_by_hop_packet.h \
371 vnet/ip/ip6_packet.h \
372 vnet/ip/ip6_neighbor.h \
373 vnet/ip/ip.h \
374 vnet/ip/ip_packet.h \
375 vnet/ip/ip_source_and_port_range_check.h \
376 vnet/ip/lookup.h \
377 vnet/ip/ports.def \
378 vnet/ip/protocols.def \
379 vnet/ip/punt_error.def \
Neale Rannsb8d44812017-11-10 06:53:54 -0800380 vnet/ip/punt.api.h \
Dave Barach68b0fb02017-02-28 15:15:56 -0500381 vnet/ip/punt.h
Damjan Marion7cd468a2016-12-19 23:05:39 +0100382
Neale Rannsb8d44812017-11-10 06:53:54 -0800383API_FILES += \
384 vnet/ip/ip.api \
385 vnet/ip/punt.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100386
387########################################
388# Bidirectional Forwarding Detection
389########################################
390
391nobase_include_HEADERS += \
392 vnet/bfd/bfd_protocol.h \
393 vnet/bfd/bfd_main.h \
394 vnet/bfd/bfd_api.h \
395 vnet/bfd/bfd_udp.h \
396 vnet/bfd/bfd.api.h
397
398libvnet_la_SOURCES += \
399 vnet/bfd/bfd_api.h \
400 vnet/bfd/bfd_udp.c \
401 vnet/bfd/bfd_main.c \
402 vnet/bfd/bfd_protocol.c \
Klement Sekera73884482017-02-23 09:26:30 +0100403 vnet/bfd/bfd_cli.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100404 vnet/bfd/bfd_api.c
405
406API_FILES += vnet/bfd/bfd.api
407
408########################################
409# Layer 3 protocol: IPSec
410########################################
Damjan Mariona9a951f2017-01-16 22:06:10 +0100411if WITH_LIBSSL
Damjan Marion7cd468a2016-12-19 23:05:39 +0100412libvnet_la_SOURCES += \
413 vnet/ipsec/ipsec.c \
414 vnet/ipsec/ipsec_cli.c \
415 vnet/ipsec/ipsec_format.c \
416 vnet/ipsec/ipsec_input.c \
417 vnet/ipsec/ipsec_if.c \
418 vnet/ipsec/ipsec_if_in.c \
419 vnet/ipsec/ipsec_if_out.c \
Sergio Gonzalez Monroydb93cd92017-08-26 15:22:05 +0100420 vnet/ipsec/esp_format.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100421 vnet/ipsec/esp_encrypt.c \
422 vnet/ipsec/esp_decrypt.c \
“mukeshyadav1984”430ac932017-11-23 02:39:33 -0800423 vnet/ipsec/ah_decrypt.c \
424 vnet/ipsec/ah_encrypt.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100425 vnet/ipsec/ikev2.c \
426 vnet/ipsec/ikev2_crypto.c \
427 vnet/ipsec/ikev2_cli.c \
428 vnet/ipsec/ikev2_payload.c \
429 vnet/ipsec/ikev2_format.c \
430 vnet/ipsec/ipsec_api.c
431
432API_FILES += vnet/ipsec/ipsec.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100433endif
434
435libvnet_la_SOURCES += \
436 vnet/ipsec/ipsec_output.c
437
438nobase_include_HEADERS += \
439 vnet/ipsec/ipsec.h \
440 vnet/ipsec/esp.h \
“mukeshyadav1984”430ac932017-11-23 02:39:33 -0800441 vnet/ipsec/ah.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100442 vnet/ipsec/ikev2.h \
443 vnet/ipsec/ikev2_priv.h \
444 vnet/ipsec/ipsec.api.h
Damjan Marion7cd468a2016-12-19 23:05:39 +0100445
446########################################
447# Layer 3 protocol: osi
448########################################
449libvnet_la_SOURCES += \
450 vnet/osi/node.c \
451 vnet/osi/osi.c \
452 vnet/osi/pg.c
453
454nobase_include_HEADERS += \
455 vnet/osi/osi.h
456
457########################################
458# Layer 3 protocol: MAP
459########################################
460libvnet_la_SOURCES += \
461 vnet/map/map.c \
462 vnet/map/map_dpo.c \
463 vnet/map/ip4_map.c \
464 vnet/map/ip6_map.c \
465 vnet/map/ip4_map_t.c \
466 vnet/map/ip6_map_t.c \
467 vnet/map/map_api.c
468
469nobase_include_HEADERS += \
470 vnet/map/map.h \
471 vnet/map/map_dpo.h \
472 vnet/map/map.api.h
473
474API_FILES += vnet/map/map.api
475
476if ENABLE_TESTS
477TESTS += test_map
478test_map_SOURCES = \
479 vnet/map/test.c
480test_map_CPPFLAGS = $(AM_CPPFLAGS) -DCLIB_DEBUG
481
482test_map_LDADD = libvnet.la libvppinfra.la libvlib.la \
Dave Barach654ceaf2017-03-29 16:59:02 -0400483 -lpthread -lvlibmemory -ldl -lsvm -lrt
Damjan Marion7cd468a2016-12-19 23:05:39 +0100484
485test_map_LDFLAGS = -static
486endif
487
Dave Barach68b0fb02017-02-28 15:15:56 -0500488########################################
489# Layer 4 protocol: tcp
490########################################
491libvnet_la_SOURCES += \
Dave Barach3bbcfab2017-08-15 19:03:44 -0400492 vnet/tcp/tcp_api.c \
Dave Barach68b0fb02017-02-28 15:15:56 -0500493 vnet/tcp/tcp_format.c \
494 vnet/tcp/tcp_pg.c \
495 vnet/tcp/tcp_syn_filter4.c \
496 vnet/tcp/tcp_output.c \
497 vnet/tcp/tcp_input.c \
498 vnet/tcp/tcp_newreno.c \
Florin Coras6792ec02017-03-13 03:49:51 -0700499 vnet/tcp/tcp_test.c \
Dave Barach68b0fb02017-02-28 15:15:56 -0500500 vnet/tcp/tcp.c
501
502nobase_include_HEADERS += \
503 vnet/tcp/tcp_packet.h \
504 vnet/tcp/tcp_timer.h \
Florin Corase69f4952017-03-07 10:06:24 -0800505 vnet/tcp/tcp_debug.h \
Florin Corasc940f092017-08-23 11:24:02 -0700506 vnet/tcp/tcp.h \
507 vnet/tcp/tcp.api.h
Dave Barach68b0fb02017-02-28 15:15:56 -0500508
Dave Barach3bbcfab2017-08-15 19:03:44 -0400509API_FILES += vnet/tcp/tcp.api
510
Dave Barach68b0fb02017-02-28 15:15:56 -0500511########################################
512# Layer 4 protocol: udp
513########################################
514libvnet_la_SOURCES += \
515 vnet/udp/udp.c \
516 vnet/udp/udp_input.c \
Dave Barach68b0fb02017-02-28 15:15:56 -0500517 vnet/udp/udp_format.c \
518 vnet/udp/udp_local.c \
Neale Ranns810086d2017-11-05 16:26:46 -0800519 vnet/udp/udp_pg.c \
520 vnet/udp/udp_encap_node.c \
521 vnet/udp/udp_encap.c \
522 vnet/udp/udp_api.c
Dave Barach68b0fb02017-02-28 15:15:56 -0500523
524nobase_include_HEADERS += \
525 vnet/udp/udp_error.def \
526 vnet/udp/udp.h \
Florin Corasf1493142017-11-09 14:17:27 -0800527 vnet/udp/udp_packet.h \
528 vnet/udp/udp.api.h
Damjan Marion7cd468a2016-12-19 23:05:39 +0100529
Neale Ranns810086d2017-11-05 16:26:46 -0800530API_FILES += vnet/udp/udp.api
531
Damjan Marion7cd468a2016-12-19 23:05:39 +0100532########################################
Marco Varlese191a5942017-10-30 18:17:21 +0100533# Layer 4 protocol: sctp
534########################################
535libvnet_la_SOURCES += \
Marco Varlese3c6a9762018-03-01 11:19:59 +0100536 vnet/sctp/sctp_api.c \
Marco Varlese191a5942017-10-30 18:17:21 +0100537 vnet/sctp/sctp.c \
538 vnet/sctp/sctp_pg.c \
539 vnet/sctp/sctp_input.c \
540 vnet/sctp/sctp_output.c \
Florin Coras4399c2e2018-01-25 06:34:42 -0800541 vnet/sctp/sctp_format.c
Marco Varlese191a5942017-10-30 18:17:21 +0100542
543nobase_include_HEADERS += \
544 vnet/sctp/sctp_error.def \
545 vnet/sctp/sctp_packet.h \
546 vnet/sctp/sctp_timer.h \
Marco Varlese3c6a9762018-03-01 11:19:59 +0100547 vnet/sctp/sctp.h \
548 vnet/sctp/sctp.api.h
549
550API_FILES += vnet/sctp/sctp.api
Marco Varlese191a5942017-10-30 18:17:21 +0100551
552########################################
Damjan Marion7cd468a2016-12-19 23:05:39 +0100553# Tunnel protocol: gre
554########################################
555libvnet_la_SOURCES += \
556 vnet/gre/gre.c \
557 vnet/gre/node.c \
558 vnet/gre/interface.c \
559 vnet/gre/pg.c \
560 vnet/gre/gre_api.c
561
562nobase_include_HEADERS += \
563 vnet/gre/gre.h \
564 vnet/gre/packet.h \
565 vnet/gre/error.def \
566 vnet/gre/gre.api.h
567
568API_FILES += vnet/gre/gre.api
569
570########################################
Ole Troan298c6952018-03-08 12:30:43 +0100571# Tunnel protocol: ipip
572########################################
573libvnet_la_SOURCES += \
574 vnet/ipip/ipip.c \
575 vnet/ipip/node.c \
576 vnet/ipip/sixrd.c \
577 vnet/ipip/ipip_api.c \
578 vnet/ipip/ipip_cli.c
579
580nobase_include_HEADERS += \
Jon Loeliger1fcbd722018-03-14 14:08:43 -0500581 vnet/ipip/ipip.api.h \
Ole Troan298c6952018-03-08 12:30:43 +0100582 vnet/ipip/ipip.h
583
584API_FILES += vnet/ipip/ipip.api
585
586########################################
Damjan Marion7cd468a2016-12-19 23:05:39 +0100587# Tunnel protocol: l2tpv3
588########################################
589libvnet_la_SOURCES += \
590 vnet/l2tp/l2tp.c \
591 vnet/l2tp/encap.c \
592 vnet/l2tp/decap.c \
593 vnet/l2tp/pg.c \
594 vnet/l2tp/l2tp_api.c
595
596nobase_include_HEADERS += \
597 vnet/l2tp/l2tp.h \
598 vnet/l2tp/packet.h \
599 vnet/l2tp/l2tp.api.h
600
601API_FILES += vnet/l2tp/l2tp.api
602
603########################################
604# Tunnel protocol: gre+mpls
605########################################
606libvnet_la_SOURCES += \
607 vnet/mpls/mpls.c \
608 vnet/mpls/mpls_lookup.c \
609 vnet/mpls/mpls_output.c \
610 vnet/mpls/mpls_features.c \
Neale Ranns696e88d2017-03-16 07:34:55 -0400611 vnet/mpls/mpls_input.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100612 vnet/mpls/interface.c \
613 vnet/mpls/mpls_tunnel.c \
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100614 vnet/mpls/pg.c \
615 vnet/mpls/mpls_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100616
617nobase_include_HEADERS += \
618 vnet/mpls/mpls.h \
619 vnet/mpls/mpls_types.h \
620 vnet/mpls/mpls_tunnel.h \
621 vnet/mpls/packet.h \
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100622 vnet/mpls/error.def \
623 vnet/mpls/mpls.api.h
Damjan Marion7cd468a2016-12-19 23:05:39 +0100624
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100625API_FILES += vnet/mpls/mpls.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100626
627########################################
628# Tunnel protocol: vxlan-gpe
629########################################
630
631libvnet_la_SOURCES += \
632 vnet/vxlan-gpe/vxlan_gpe.c \
633 vnet/vxlan-gpe/encap.c \
634 vnet/vxlan-gpe/decap.c \
635 vnet/vxlan-gpe/vxlan_gpe_api.c
636
637nobase_include_HEADERS += \
638 vnet/vxlan-gpe/vxlan_gpe.h \
639 vnet/vxlan-gpe/vxlan_gpe_packet.h \
640 vnet/vxlan-gpe/vxlan_gpe_error.def \
641 vnet/vxlan-gpe/vxlan_gpe.api.h
642
643API_FILES += vnet/vxlan-gpe/vxlan_gpe.api
644
645########################################
646# Tunnel protocol: ipsec+gre
647########################################
648libvnet_la_SOURCES += \
649 vnet/ipsec-gre/ipsec_gre.c \
650 vnet/ipsec-gre/node.c \
651 vnet/ipsec-gre/interface.c \
652 vnet/ipsec-gre/ipsec_gre_api.c
653
654nobase_include_HEADERS += \
655 vnet/ipsec-gre/ipsec_gre.h \
656 vnet/ipsec-gre/error.def \
657 vnet/ipsec-gre/ipsec_gre.api.h
658
659API_FILES += vnet/ipsec-gre/ipsec_gre.api
660
661########################################
662# LISP control plane: lisp-cp
663########################################
664
665libvnet_la_SOURCES += \
666 vnet/lisp-cp/lisp_types.c \
667 vnet/lisp-cp/lisp_cp_dpo.c \
668 vnet/lisp-cp/control.c \
669 vnet/lisp-cp/gid_dictionary.c \
670 vnet/lisp-cp/lisp_msg_serdes.c \
671 vnet/lisp-cp/packets.c \
Filip Tehlar694396d2017-02-17 14:29:11 +0100672 vnet/lisp-cp/one_cli.c \
Florin Corasf3dc11a2017-01-24 03:13:43 -0800673 vnet/lisp-cp/lisp_cli.c \
Filip Tehlar694396d2017-02-17 14:29:11 +0100674 vnet/lisp-cp/one_api.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100675 vnet/lisp-cp/lisp_api.c
676
677nobase_include_HEADERS += \
678 vnet/lisp-cp/lisp_types.h \
679 vnet/lisp-cp/packets.h \
680 vnet/lisp-cp/gid_dictionary.h \
681 vnet/lisp-cp/lisp_cp_messages.h \
682 vnet/lisp-cp/lisp_msg_serdes.h \
683 vnet/lisp-cp/control.h \
Filip Tehlar694396d2017-02-17 14:29:11 +0100684 vnet/lisp-cp/one.api.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100685 vnet/lisp-cp/lisp.api.h
686
687API_FILES += vnet/lisp-cp/lisp.api
Filip Tehlar694396d2017-02-17 14:29:11 +0100688API_FILES += vnet/lisp-cp/one.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100689
690if ENABLE_TESTS
691LDS = \
692 libvppinfra.la \
693 libvnet.la \
694 libvlib.la \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100695 libsvm.la \
696 libsvmdb.la \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100697 libvlibmemory.la \
Damjan Marionc74a86a2017-01-16 14:00:03 +0100698 -lpthread -ldl -lrt -lm
Damjan Marion7cd468a2016-12-19 23:05:39 +0100699
700TESTS += test_cp_serdes test_lisp_types
701
702test_cp_serdes_SOURCES = \
703 tests/vnet/lisp-cp/test_cp_serdes.c \
704 vnet/lisp-cp/lisp_msg_serdes.c \
705 vnet/lisp-cp/lisp_types.c \
706 vnet/lisp-cp/packets.c \
707 vnet/ip/ip_checksum.c
708
709test_lisp_types_SOURCES = \
710 tests/vnet/lisp-cp/test_lisp_types.c \
711 vnet/lisp-cp/lisp_types.c
712
713test_cp_serdes_CPPFLAGS = $(AM_CPPFLAGS) -DCLIB_DEBUG
714test_lisp_types_CPPFLAGS = $(AM_CPPFLAGS) -DCLIB_DEBUG
715
Damjan Marionc74a86a2017-01-16 14:00:03 +0100716test_cp_serdes_LDADD = $(LDS)
717test_lisp_types_LDADD = $(LDS)
Damjan Marion7cd468a2016-12-19 23:05:39 +0100718endif
719
720########################################
721# Tunnel protocol: lisp-gpe
722########################################
723
724libvnet_la_SOURCES += \
725 vnet/lisp-gpe/lisp_gpe.c \
726 vnet/lisp-gpe/lisp_gpe_sub_interface.c \
727 vnet/lisp-gpe/lisp_gpe_adjacency.c \
728 vnet/lisp-gpe/lisp_gpe_tunnel.c \
729 vnet/lisp-gpe/lisp_gpe_fwd_entry.c \
730 vnet/lisp-gpe/lisp_gpe_tenant.c \
731 vnet/lisp-gpe/interface.c \
732 vnet/lisp-gpe/decap.c \
733 vnet/lisp-gpe/lisp_gpe_api.c
734
735nobase_include_HEADERS += \
736 vnet/lisp-gpe/lisp_gpe.h \
737 vnet/lisp-gpe/lisp_gpe_fwd_entry.h \
738 vnet/lisp-gpe/lisp_gpe_tenant.h \
739 vnet/lisp-gpe/lisp_gpe_packet.h \
740 vnet/lisp-gpe/lisp_gpe_error.def \
741 vnet/lisp-gpe/lisp_gpe.api.h
742
743API_FILES += vnet/lisp-gpe/lisp_gpe.api
744
Damjan Marion7cd468a2016-12-19 23:05:39 +0100745########################################
746# DHCP client
747########################################
748libvnet_la_SOURCES += \
749 vnet/dhcp/client.c \
Neale Ranns54c6dc42018-01-17 10:29:10 -0800750 vnet/dhcp/dhcp_client_detect.c \
Pavel Kotucekc8d87702017-01-25 07:25:32 +0100751 vnet/dhcp/dhcp_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100752
753nobase_include_HEADERS += \
Neale Ranns2dd68522017-02-16 03:38:59 -0800754 vnet/dhcp/client.h \
Pavel Kotucekc8d87702017-01-25 07:25:32 +0100755 vnet/dhcp/dhcp.api.h
756
757API_FILES += vnet/dhcp/dhcp.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100758
759########################################
760# DHCP proxy
761########################################
762libvnet_la_SOURCES += \
Neale Ranns2dd68522017-02-16 03:38:59 -0800763 vnet/dhcp/dhcp6_proxy_node.c \
764 vnet/dhcp/dhcp4_proxy_node.c \
765 vnet/dhcp/dhcp_proxy.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100766
767nobase_include_HEADERS += \
Neale Ranns2dd68522017-02-16 03:38:59 -0800768 vnet/dhcp/dhcp4_packet.h \
769 vnet/dhcp/dhcp6_packet.h \
770 vnet/dhcp/dhcp_proxy.h \
771 vnet/dhcp/dhcp6_proxy_error.def \
772 vnet/dhcp/dhcp4_proxy_error.def
Damjan Marion7cd468a2016-12-19 23:05:39 +0100773
774########################################
775# ipv6 segment routing
776########################################
777
Damjan Marion7cd468a2016-12-19 23:05:39 +0100778libvnet_la_SOURCES += \
Pablo Camarillo5d73eec2017-04-24 17:51:56 +0200779 vnet/srv6/sr.c \
780 vnet/srv6/sr_localsid.c \
781 vnet/srv6/sr_policy_rewrite.c \
782 vnet/srv6/sr_steering.c \
783 vnet/srv6/sr_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100784
785nobase_include_HEADERS += \
Pablo Camarillo5d73eec2017-04-24 17:51:56 +0200786 vnet/srv6/sr_packet.h \
787 vnet/srv6/sr.h \
788 vnet/srv6/sr.api.h
Pavel Kotucek0f971d82017-01-03 10:48:54 +0100789
Pablo Camarillo5d73eec2017-04-24 17:51:56 +0200790API_FILES += vnet/srv6/sr.api
791
792########################################
793# mpls segment routing
794########################################
795
796libvnet_la_SOURCES += \
797 vnet/srmpls/sr_mpls_policy.c \
Pablo Camarillo42998822017-07-13 09:41:32 +0200798 vnet/srmpls/sr_mpls_steering.c \
799 vnet/srmpls/sr_mpls_api.c
Pablo Camarillo5d73eec2017-04-24 17:51:56 +0200800
801
802nobase_include_HEADERS += \
Pablo Camarillo42998822017-07-13 09:41:32 +0200803 vnet/srmpls/sr_mpls.h \
804 vnet/srmpls/sr_mpls.api.h
805
806API_FILES += vnet/srmpls/sr_mpls.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100807
808########################################
Damjan Marion7cd468a2016-12-19 23:05:39 +0100809# IPFIX / netflow v10
810########################################
811libvnet_la_SOURCES += \
Pavel Kotucekeb9e6662017-01-24 13:40:26 +0100812 vnet/flow/flow_report.c \
813 vnet/flow/flow_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100814
815nobase_include_HEADERS += \
816 vnet/flow/flow_report.h \
817 vnet/flow/ipfix_info_elements.h \
Pavel Kotucekeb9e6662017-01-24 13:40:26 +0100818 vnet/flow/ipfix_packet.h \
819 vnet/flow/flow.api.h
820
821API_FILES += vnet/flow/flow.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100822
823########################################
824# IPFIX classify code
825########################################
826
827libvnet_la_SOURCES += \
828 vnet/flow/flow_report_classify.c
829
830nobase_include_HEADERS += \
831 vnet/flow/flow_report_classify.h
832
833########################################
834# lawful intercept
835########################################
836
837libvnet_la_SOURCES += \
838 vnet/lawful-intercept/lawful_intercept.c \
839 vnet/lawful-intercept/node.c
840
841nobase_include_HEADERS += \
842 vnet/lawful-intercept/lawful_intercept.h
843
844########################################
845# SPAN (port mirroring)
846########################################
847
848libvnet_la_SOURCES += \
849 vnet/span/span_api.c \
850 vnet/span/span.c \
851 vnet/span/node.c
852
853nobase_include_HEADERS += \
854 vnet/span/span.api.h \
855 vnet/span/span.h
856
857API_FILES += vnet/span/span.api
858
859########################################
Dave Barach65457162017-10-10 17:53:14 -0400860# DNS proxy, API
861########################################
862libvnet_la_SOURCES += \
863 vnet/dns/dns.c \
864 vnet/dns/dns.h \
865 vnet/dns/dns_packet.h \
866 vnet/dns/reply_node.c \
Dave Barach97494502017-11-04 09:44:38 -0400867 vnet/dns/request_node.c \
Dave Barach65457162017-10-10 17:53:14 -0400868 vnet/dns/resolver_process.c
869
870nobase_include_HEADERS += \
871 vnet/dns/dns.api.h \
872 vnet/dns/dns.h
873
874API_FILES += vnet/dns/dns.api
875
876########################################
Damjan Marion7cd468a2016-12-19 23:05:39 +0100877# Packet generator
878########################################
879
880libvnet_la_SOURCES += \
881 vnet/pg/cli.c \
882 vnet/pg/edit.c \
883 vnet/pg/init.c \
884 vnet/pg/input.c \
885 vnet/pg/output.c \
Neale Rannsb8d44812017-11-10 06:53:54 -0800886 vnet/pg/stream.c \
887 vnet/pg/pg_api.c
Damjan Marion7cd468a2016-12-19 23:05:39 +0100888
889nobase_include_HEADERS += \
890 vnet/pg/pg.h \
Neale Rannsb8d44812017-11-10 06:53:54 -0800891 vnet/pg/edit.h \
892 vnet/pg/pg.api.h
893
894API_FILES += vnet/pg/pg.api
Damjan Marion7cd468a2016-12-19 23:05:39 +0100895
Damjan Marion7cd468a2016-12-19 23:05:39 +0100896########################################
897# virtio
898########################################
899
Damjan Marionc99b4cd2017-12-04 15:25:58 +0100900libvnet_la_SOURCES += \
901 vnet/devices/virtio/device.c \
902 vnet/devices/virtio/node.c \
903 vnet/devices/virtio/vhost-user.c \
904 vnet/devices/virtio/vhost_user_api.c \
Damjan Marion8389fb92017-10-13 18:29:53 +0200905 vnet/devices/virtio/virtio.c
906
Damjan Marion7cd468a2016-12-19 23:05:39 +0100907
Damjan Marionc99b4cd2017-12-04 15:25:58 +0100908nobase_include_HEADERS += \
909 vnet/devices/virtio/virtio.h \
910 vnet/devices/virtio/vhost-user.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +0100911 vnet/devices/virtio/vhost_user.api.h
912
913API_FILES += vnet/devices/virtio/vhost_user.api
914
915########################################
Damjan Marionc99b4cd2017-12-04 15:25:58 +0100916# tap interface (with virtio backend)
917########################################
918
919libvnet_la_SOURCES += \
920 vnet/devices/tap/cli.c \
921 vnet/devices/tap/tap.c \
922 vnet/devices/tap/tapv2_api.c
923
924nobase_include_HEADERS += \
925 vnet/devices/tap/tap.h \
926 vnet/devices/tap/tapv2.api.h
927
928API_FILES += vnet/devices/tap/tapv2.api
929
930########################################
Dave Barach68b0fb02017-02-28 15:15:56 -0500931# session managmeent
932########################################
933
934libvnet_la_SOURCES += \
935 vnet/session/session.c \
Florin Corascea194d2017-10-02 00:18:51 -0700936 vnet/session/session_table.c \
Florin Coras1c710452017-10-17 00:03:13 -0700937 vnet/session/session_rules_table.c \
Florin Coras04e53442017-07-16 17:12:15 -0700938 vnet/session/session_lookup.c \
939 vnet/session/session_node.c \
Florin Coras3cbc04b2017-10-02 00:18:51 -0700940 vnet/session/transport.c \
Dave Barach68b0fb02017-02-28 15:15:56 -0500941 vnet/session/application.c \
942 vnet/session/session_cli.c \
Dave Barach68b0fb02017-02-28 15:15:56 -0500943 vnet/session/application_interface.c \
Florin Corascea194d2017-10-02 00:18:51 -0700944 vnet/session/application_namespace.c \
Florin Coras6cf30ad2017-04-04 23:08:23 -0700945 vnet/session/segment_manager.c \
Florin Corascea194d2017-10-02 00:18:51 -0700946 vnet/session/session_test.c \
Dave Barach68b0fb02017-02-28 15:15:56 -0500947 vnet/session/session_api.c
948
949nobase_include_HEADERS += \
950 vnet/session/session.h \
Florin Corascea194d2017-10-02 00:18:51 -0700951 vnet/session/session_table.h \
Florin Coras1c710452017-10-17 00:03:13 -0700952 vnet/session/session_rules_table.h \
Florin Coras04e53442017-07-16 17:12:15 -0700953 vnet/session/stream_session.h \
954 vnet/session/session_lookup.h \
Dave Barach68b0fb02017-02-28 15:15:56 -0500955 vnet/session/application.h \
956 vnet/session/transport.h \
Florin Coras04e53442017-07-16 17:12:15 -0700957 vnet/session/transport_interface.h \
Alexander Popovsky (apopovsk)6f6f52a2017-03-03 16:06:26 -0800958 vnet/session/application_interface.h \
Florin Corascea194d2017-10-02 00:18:51 -0700959 vnet/session/application_namespace.h \
Florin Corase69f4952017-03-07 10:06:24 -0800960 vnet/session/session_debug.h \
Florin Coras6cf30ad2017-04-04 23:08:23 -0700961 vnet/session/segment_manager.h \
Florin Coras1c710452017-10-17 00:03:13 -0700962 vnet/session/mma_template.h \
963 vnet/session/mma_template.c \
964 vnet/session/mma_16.h \
965 vnet/session/mma_40.h \
Alexander Popovsky (apopovsk)6f6f52a2017-03-03 16:06:26 -0800966 vnet/session/session.api.h
Dave Barach68b0fb02017-02-28 15:15:56 -0500967
968API_FILES += vnet/session/session.api
969
970########################################
Florin Coras4399c2e2018-01-25 06:34:42 -0800971# session layer applications
972########################################
973
974libvnet_la_SOURCES += \
975 vnet/session-apps/echo_client.c \
976 vnet/session-apps/echo_server.c \
977 vnet/session-apps/http_server.c \
978 vnet/session-apps/proxy.c
979
980nobase_include_HEADERS += \
981 vnet/session-apps/echo_client.h \
982 vnet/session-apps/proxy.h
983
984########################################
Florin Corasd77eee62018-03-07 08:49:27 -0800985# TLS protocol
986########################################
987
988libvnet_la_SOURCES += vnet/tls/tls.c
989
990nobase_include_HEADERS += \
991 vnet/tls/tls.h
992
993########################################
Damjan Marion7cd468a2016-12-19 23:05:39 +0100994# Linux packet interface
995########################################
996
997libvnet_la_SOURCES += \
998 vnet/devices/af_packet/af_packet.c \
999 vnet/devices/af_packet/device.c \
1000 vnet/devices/af_packet/node.c \
1001 vnet/devices/af_packet/cli.c \
1002 vnet/devices/af_packet/af_packet_api.c
1003
1004nobase_include_HEADERS += \
1005 vnet/devices/af_packet/af_packet.h \
1006 vnet/devices/af_packet/af_packet.api.h
1007
1008API_FILES += vnet/devices/af_packet/af_packet.api
1009
1010########################################
1011# NETMAP interface
1012########################################
1013
1014libvnet_la_SOURCES += \
1015 vnet/devices/netmap/netmap.c \
1016 vnet/devices/netmap/device.c \
1017 vnet/devices/netmap/node.c \
1018 vnet/devices/netmap/cli.c \
1019 vnet/devices/netmap/netmap_api.c
1020
1021nobase_include_HEADERS += \
1022 vnet/devices/netmap/netmap.h \
1023 vnet/devices/netmap/netmap.api.h
1024
1025API_FILES += vnet/devices/netmap/netmap.api
1026
1027########################################
1028# Driver feature graph arc support
1029########################################
1030
1031libvnet_la_SOURCES += \
1032 vnet/feature/feature.c \
Neale Rannsb8d44812017-11-10 06:53:54 -08001033 vnet/feature/feature_api.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +01001034 vnet/feature/registration.c
1035
1036nobase_include_HEADERS += \
Neale Rannsb8d44812017-11-10 06:53:54 -08001037 vnet/feature/feature.h \
1038 vnet/feature/feature.api.h
1039
1040API_FILES += vnet/feature/feature.api
Damjan Marion7cd468a2016-12-19 23:05:39 +01001041
1042########################################
1043# Unix kernel related
1044########################################
1045
1046# FIXME: vnet/unix/hgshm.c
1047
1048libvnet_la_SOURCES += \
1049 vnet/unix/gdb_funcs.c \
1050 vnet/unix/pcap.c \
1051 vnet/unix/tap_api.c \
1052 vnet/unix/tapcli.c \
1053 vnet/unix/tuntap.c
1054
1055nobase_include_HEADERS += \
1056 vnet/unix/pcap.h \
1057 vnet/unix/tuntap.h \
1058 vnet/unix/tap.api.h \
1059 vnet/unix/tapcli.h
1060
1061API_FILES += vnet/unix/tap.api
1062
1063########################################
1064# FIB
1065########################################
1066
1067libvnet_la_SOURCES += \
1068 vnet/fib/fib.c \
1069 vnet/fib/fib_test.c \
1070 vnet/fib/ip4_fib.c \
1071 vnet/fib/ip6_fib.c \
1072 vnet/fib/mpls_fib.c \
1073 vnet/fib/fib_table.c \
1074 vnet/fib/fib_walk.c \
1075 vnet/fib/fib_types.c \
1076 vnet/fib/fib_node.c \
1077 vnet/fib/fib_node_list.c \
1078 vnet/fib/fib_entry.c \
1079 vnet/fib/fib_entry_src.c \
1080 vnet/fib/fib_entry_src_rr.c \
1081 vnet/fib/fib_entry_src_interface.c \
1082 vnet/fib/fib_entry_src_default_route.c \
1083 vnet/fib/fib_entry_src_special.c \
1084 vnet/fib/fib_entry_src_api.c \
1085 vnet/fib/fib_entry_src_adj.c \
1086 vnet/fib/fib_entry_src_mpls.c \
1087 vnet/fib/fib_entry_src_lisp.c \
1088 vnet/fib/fib_entry_cover.c \
1089 vnet/fib/fib_entry_delegate.c \
1090 vnet/fib/fib_path_list.c \
1091 vnet/fib/fib_path.c \
1092 vnet/fib/fib_path_ext.c \
1093 vnet/fib/fib_urpf_list.c \
Neale Ranns88fc83e2017-04-05 08:11:14 -07001094 vnet/fib/fib_attached_export.c \
Neale Ranns81458422018-03-12 06:59:36 -07001095 vnet/fib/fib_api.c \
Neale Ranns88fc83e2017-04-05 08:11:14 -07001096 vnet/fib/fib_bfd.c
Damjan Marion7cd468a2016-12-19 23:05:39 +01001097
1098nobase_include_HEADERS += \
1099 vnet/fib/fib.h \
1100 vnet/fib/fib_api.h \
1101 vnet/fib/ip4_fib.h \
1102 vnet/fib/ip6_fib.h \
1103 vnet/fib/fib_types.h \
1104 vnet/fib/fib_table.h \
1105 vnet/fib/fib_node.h \
1106 vnet/fib/fib_node_list.h \
1107 vnet/fib/fib_entry.h \
1108 vnet/fib/fib_entry_delegate.h
1109
1110########################################
1111# ADJ
1112########################################
1113
1114libvnet_la_SOURCES += \
1115 vnet/adj/adj_nbr.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +01001116 vnet/adj/adj_glean.c \
1117 vnet/adj/adj_midchain.c \
Neale Ranns32e1c012016-11-22 17:07:28 +00001118 vnet/adj/adj_mcast.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +01001119 vnet/adj/adj_l2.c \
Florin Corasce1b4c72017-01-26 14:25:34 -08001120 vnet/adj/adj_nsh.c \
Neale Rannsfa5d1982017-02-20 14:19:51 -08001121 vnet/adj/adj.c \
Neale Ranns88fc83e2017-04-05 08:11:14 -07001122 vnet/adj/rewrite.c \
1123 vnet/adj/adj_bfd.c \
1124 vnet/adj/adj_delegate.c
Damjan Marion7cd468a2016-12-19 23:05:39 +01001125
1126nobase_include_HEADERS += \
1127 vnet/adj/adj.h \
1128 vnet/adj/adj_types.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +01001129 vnet/adj/adj_glean.h \
Florin Corasce1b4c72017-01-26 14:25:34 -08001130 vnet/adj/adj_nsh.h \
Neale Rannsfa5d1982017-02-20 14:19:51 -08001131 vnet/adj/adj_nbr.h \
1132 vnet/adj/rewrite.h
Damjan Marion7cd468a2016-12-19 23:05:39 +01001133
1134########################################
1135# Data-Plane Objects
1136########################################
1137
1138libvnet_la_SOURCES += \
1139 vnet/dpo/dpo.c \
1140 vnet/dpo/drop_dpo.c \
1141 vnet/dpo/ip_null_dpo.c \
Neale Ranns53da2212018-02-24 02:11:19 -08001142 vnet/dpo/ip6_ll_dpo.c \
Damjan Marion7cd468a2016-12-19 23:05:39 +01001143 vnet/dpo/punt_dpo.c \
1144 vnet/dpo/receive_dpo.c \
1145 vnet/dpo/load_balance.c \
1146 vnet/dpo/load_balance_map.c \
Neale Ranns32e1c012016-11-22 17:07:28 +00001147 vnet/dpo/lookup_dpo.c \
1148 vnet/dpo/classify_dpo.c \
1149 vnet/dpo/replicate_dpo.c \
Neale Ranns43161a82017-08-12 02:12:00 -07001150 vnet/dpo/interface_rx_dpo.c \
1151 vnet/dpo/interface_tx_dpo.c \
Neale Ranns0f26c5a2017-03-01 15:12:11 -08001152 vnet/dpo/mpls_disposition.c \
Neale Ranns6f631152017-10-03 08:20:21 -07001153 vnet/dpo/mpls_label_dpo.c \
Andrew Yourtchenko5f3fcb92017-10-25 05:50:37 -07001154 vnet/dpo/l3_proxy_dpo.c \
Neale Rannsf068c3e2018-01-03 04:18:48 -08001155 vnet/dpo/dvr_dpo.c
Damjan Marion7cd468a2016-12-19 23:05:39 +01001156
1157nobase_include_HEADERS += \
1158 vnet/dpo/load_balance.h \
1159 vnet/dpo/drop_dpo.h \
1160 vnet/dpo/lookup_dpo.h \
1161 vnet/dpo/punt_dpo.h \
1162 vnet/dpo/classify_dpo.h \
1163 vnet/dpo/receive_dpo.h \
1164 vnet/dpo/ip_null_dpo.h \
Neale Ranns60c1c7c2017-11-02 07:39:24 -07001165 vnet/dpo/replicate_dpo.h \
Damjan Marion7cd468a2016-12-19 23:05:39 +01001166 vnet/dpo/dpo.h
1167
1168########################################
Neale Ranns32e1c012016-11-22 17:07:28 +00001169# Multicast FIB
1170########################################
1171
1172libvnet_la_SOURCES += \
1173 vnet/mfib/mfib_test.c \
1174 vnet/mfib/mfib_forward.c \
1175 vnet/mfib/ip4_mfib.c \
1176 vnet/mfib/ip6_mfib.c \
1177 vnet/mfib/mfib_types.c \
1178 vnet/mfib/mfib_signal.c \
1179 vnet/mfib/mfib_itf.c \
1180 vnet/mfib/mfib_entry.c \
1181 vnet/mfib/mfib_table.c
1182
1183nobase_include_HEADERS += \
1184 vnet/mfib/ip4_mfib.h \
1185 vnet/mfib/mfib_types.h \
1186 vnet/mfib/mfib_table.h
1187
1188########################################
1189# Utilities
1190########################################
1191
1192libvnet_la_SOURCES += \
Hongjun Nibf4be572017-11-13 20:34:06 +08001193 vnet/util/radix.c \
1194 vnet/util/refcount.c \
Dave Barach7bee7732017-10-18 18:48:11 -04001195 vnet/util/trajectory.c
Neale Ranns32e1c012016-11-22 17:07:28 +00001196
1197########################################
Neale Rannsd792d9c2017-10-21 10:53:20 -07001198# BIER
1199########################################
1200
1201libvnet_la_SOURCES += \
1202 vnet/bier/bier_bit_string.c \
1203 vnet/bier/bier_entry.c \
1204 vnet/bier/bier_fmask.c \
1205 vnet/bier/bier_fmask_db.c \
1206 vnet/bier/bier_input.c \
1207 vnet/bier/bier_lookup.c \
1208 vnet/bier/bier_output.c \
1209 vnet/bier/bier_table.c \
1210 vnet/bier/bier_types.c \
1211 vnet/bier/bier_test.c \
1212 vnet/bier/bier_api.c \
1213 vnet/bier/bier_drop.c \
1214 vnet/bier/bier_update.c \
1215 vnet/bier/bier_imp_node.c \
1216 vnet/bier/bier_imp.c \
1217 vnet/bier/bier_disp_entry.c \
1218 vnet/bier/bier_disp_lookup_node.c \
1219 vnet/bier/bier_disp_dispatch_node.c \
Neale Ranns91286372017-12-05 13:24:04 -08001220 vnet/bier/bier_disp_table.c \
1221 vnet/bier/bier_bift_table.c
Neale Rannsd792d9c2017-10-21 10:53:20 -07001222
1223nobase_include_HEADERS += \
1224 vnet/bier/bier_types.h \
1225 vnet/bier/bier_entry.h \
1226 vnet/bier/bier_update.h \
1227 vnet/bier/bier.api.h \
1228 vnet/bier/bier_table.h
1229
1230API_FILES += vnet/bier/bier.api
1231
1232########################################
Florin Coras891f0a12017-12-11 11:49:26 -08001233# Test apps
1234########################################
1235
1236noinst_PROGRAMS += tcp_echo udp_echo
1237
1238TEST_APPS_LDADD = libvlibmemoryclient.la libsvm.la libvppinfra.la
1239TEST_APPS_LDADD += -lpthread -lm -lrt
1240
1241tcp_echo_SOURCES = tests/vnet/session/tcp_echo.c
1242tcp_echo_LDADD = $(TEST_APPS_LDADD)
1243
1244udp_echo_SOURCES = tests/vnet/session/udp_echo.c
1245udp_echo_LDADD = $(TEST_APPS_LDADD)
1246
1247########################################
Damjan Marion7cd468a2016-12-19 23:05:39 +01001248# Plugin client library
1249########################################
1250
Damjan Marion7cd468a2016-12-19 23:05:39 +01001251nobase_include_HEADERS += \
1252 vnet/plugin/plugin.h
1253
Damjan Marion7cd468a2016-12-19 23:05:39 +01001254pcap2pg_SOURCES = \
1255 vnet/unix/pcap2pg.c \
1256 vnet/unix/pcap.h
1257
1258pcap2pg_LDFLAGS = -static
1259pcap2pg_LDADD = libvnet.la libvppinfra.la -lpthread libvlibmemory.la -lm -ldl
1260
Dave Baracha0cc5ab2018-02-23 12:09:41 -05001261pcap2cinit_SOURCES = \
1262 vnet/unix/pcap2cinit.c \
1263 vnet/unix/pcap.h
1264
1265pcap2cinit_LDFLAGS = -static
1266pcap2cinit_LDADD = libvnet.la libvppinfra.la -lpthread libvlibmemory.la -lm -ldl
1267
1268noinst_PROGRAMS += pcap2pg pcap2cinit
Damjan Marion7cd468a2016-12-19 23:05:39 +01001269
1270# vi:syntax=automake