1 # 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:
6 # http://www.apache.org/licenses/LICENSE-2.0
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.
14 AUTOMAKE_OPTIONS = foreign subdir-objects
16 AM_CFLAGS = -Wall @DPDK@ @IPSEC@ @VCGN@ @IPV6SR@
36 # comment out to disable stats upload to gmond
41 nobase_include_HEADERS = \
46 # install the API definition, so we can produce java bindings, etc.
48 apidir = $(prefix)/api
49 api_DATA = api/vpe.api
51 BUILT_SOURCES += api/vpe.api.h app/version.h
53 app/version.o: app/version.h
59 @echo "#define VPP_BUILD_DATE \"$$(date)\"" > $@
60 @echo "#define VPP_BUILD_USER \"$$(whoami)\"" >> $@
61 @echo "#define VPP_BUILD_HOST \"$$(hostname)\"" >> $@
62 @echo "#define VPP_BUILD_TOPDIR \"$$(git rev-parse --show-toplevel)\"" >> $@
63 @echo "#define VPP_BUILD_VER \"$$(../../scripts/version)\"" >> $@
65 vpp_LDADD = -lvlibapi -lvlibmemory -lvlib_unix -lvlib
69 vpp_LDADD += -lsvm -lsvmdb -lrt
71 vpp_LDADD += -lvnetplugin
74 vpp_LDFLAGS = -Wl,--whole-archive
78 vpp_LDFLAGS += -l:libdpdk.a
80 vpp_LDFLAGS += -Wl,--no-whole-archive
83 vpp_LDADD += -lvppinfra -lm -lpthread -ldl
89 SUFFIXES = .api.h .api
92 @echo " APIGEN " $@ ; \
93 mkdir -p `dirname $@` ; \
94 $(CC) $(CPPFLAGS) -E -P -C -x c $^ \
95 | vppapigen --input - --output $@ --show-name $@
98 noinst_PROGRAMS += test_client
100 test_client_SOURCES = api/test_client.c
101 test_client_LDADD = -lvlibmemoryclient -lvlibapi -lsvm -lvppinfra \
104 noinst_PROGRAMS += test_client test_ha
106 test_ha_SOURCES = api/test_ha.c
107 test_ha_LDADD = -lvlibmemoryclient -lvlibapi -lsvmdb -lsvm -lvppinfra \
112 noinst_PROGRAMS += summary_stats_client
114 summary_stats_client_SOURCES = api/summary_stats_client.c
115 summary_stats_client_LDADD = -lvlibmemoryclient -lvlibapi -lsvm -lvppinfra \