Merge "Add support for nop mode with l3 submode"
[samplevnf.git] / VNFs / UDP_Replay / Makefile
1 # Copyright (c) 2017 Intel Corporation
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #      http:#www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 ifeq ($(RTE_SDK),)
16 $(error "Please define RTE_SDK environment variable")
17 endif
18
19 # Default target, can be overriden by command line or environment
20 RTE_TARGET ?= x86_64-native-linuxapp-gcc
21 DIRS-y += pipeline
22
23 include $(RTE_SDK)/mk/rte.vars.mk
24
25 # binary name
26 APP = UDP_Replay
27
28 VPATH += $(VNF_CORE)/common/vnf_common
29 VPATH += $(VNF_CORE)/common/VIL/pipeline_arpicmp
30 VPATH += $(VNF_CORE)/common/VIL/conntrack
31 VPATH += $(VNF_CORE)/common/VIL/pipeline_common
32 VPATH += $(VNF_CORE)/common/VIL/pipeline_loadb
33 VPATH += $(VNF_CORE)/common/VIL/pipeline_master
34 VPATH += $(VNF_CORE)/common/VIL/pipeline_passthrough
35 VPATH += $(SRCDIR)/pipeline
36 VPATH += $(VNF_CORE)/common/VIL/pipeline_txrx
37 VPATH += $(VNF_CORE)/common/VIL/l2l3_stack
38 VPATH += $(VNF_CORE)/common/VIL/gateway
39
40 INC += $(wildcard *.h)
41 INC += $(wildcard pipeline/*.h)
42 INC += $(wildcard $(VNF_CORE)/common/vnf_common/*.h)
43 INC += $(wildcard $(VNF_CORE)/common/VIL/pipeline_arpicmp/*.h)
44 INC += $(wildcard $(VNF_CORE)/common/VIL/conntrack/*.h)
45 INC += $(wildcard $(VNF_CORE)/common/VIL/pipeline_loadb/*.h)
46 INC += $(wildcard $(VNF_CORE)/common/VIL/pipeline_common/*.h)
47 INC += $(wildcard $(VNF_CORE)/common/VIL/pipeline_master/*.h)
48 INC += $(wildcard $(VNF_CORE)/common/VIL/pipeline_passthrough/*.h)
49 INC += $(wildcard $(VNF_CORE)/common/VIL/pipeline_txrx/*.h)
50 INC += $(wildcard $(VNF_CORE)/common/VIL/l2l3_stack/*.h)
51 INC += $(wildcard $(VNF_CORE)/common/VIL/gateway/*.h)
52
53 CFLAGS += -I$(SRCDIR) -mrtm -mhle -I$(SRCDIR)/pipeline -I$(VNF_CORE)/common/vnf_common
54 CFLAGS += -I$(VNF_CORE)/common/VIL/conntrack -I$(VNF_CORE)/common/VIL/l2l3_stack
55 CFLAGS += -I$(VNF_CORE)/common/VIL/pipeline_common -I$(VNF_CORE)/common/VIL/pipeline_loadb
56 CFLAGS += -I$(VNF_CORE)/common/VIL/pipeline_master -I$(VNF_CORE)/common/VIL/pipeline_passthrough
57 CFLAGS += -I$(VNF_CORE)/common/VIL/pipeline_txrx
58 CFLAGS += -I$(VNF_CORE)/common/VIL/pipeline_arpicmp
59 CFLAGS += -I$(VNF_CORE)/common/VIL/gateway
60
61 # all source are stored in SRCS-y
62 SRCS-y := main.c
63 SRCS-y += config_parse.c
64 SRCS-y += config_parse_tm.c
65 SRCS-y += config_check.c
66
67 SRCS-y += lib_arp.c
68 SRCS-y += lib_icmpv6.c
69 SRCS-y += interface.c
70 SRCS-y += hle.c
71 SRCS-y += tsx.c
72 SRCS-y += l2_proto.c
73 SRCS-y += l3fwd_main.c
74 SRCS-y += l3fwd_lpm4.c
75 SRCS-y += l3fwd_lpm6.c
76 SRCS-y += bond.c
77
78 SRCS-y += pipeline_common_be.c
79 SRCS-y += pipeline_common_fe.c
80 SRCS-y += pipeline_master_be.c
81 SRCS-y += pipeline_master.c
82 SRCS-y += pipeline_passthrough_be.c
83 SRCS-y += pipeline_passthrough.c
84 SRCS-y += pipeline_arpicmp.c
85 SRCS-y += pipeline_loadb.c
86 SRCS-y += pipeline_loadb_be.c
87 SRCS-y += vnf_common.c
88 SRCS-y += pipeline_arpicmp_be.c
89 SRCS-y += gateway.c
90
91 CFLAGS += -O3 $(USER_FLAGS)
92 CFLAGS += $(WERROR_FLAGS)
93
94 # workaround for a gcc bug with noreturn attribute
95 # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12603
96 ifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y)
97 CFLAGS_main.o += -Wno-return-type
98 endif
99
100 include $(RTE_SDK)/mk/rte.extapp.mk