blob: b96ff3d9201ab2bbf64a0327edd680efa2d1157c [file] [log] [blame]
Ole Troan6855f6c2016-04-09 03:16:30 +02001# Copyright (c) 2016 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
14AUTOMAKE_OPTIONS = foreign subdir-objects
15ACLOCAL_AMFLAGS = -I m4
16AM_CFLAGS = -Wall
17
18BUILT_SOURCES =
19bin_PROGRAMS =
20CLEANFILES =
21lib_LTLIBRARIES =
22noinst_PROGRAMS = test_pneum
23nobase_include_HEADERS = pneum/pneum.h
24
25#
26# Python binding
27#
28lib_LTLIBRARIES += libpneum.la
29libpneum_la_SOURCES = pneum/pneum.c
30libpneum_la_LIBADD = -lvlibmemoryclient -lvlibapi -lsvm -lvppinfra -lpthread -lm -lrt
31libpneum_la_LDFLAGS = -module
32libpneum_la_CPPFLAGS =
33
34BUILT_SOURCES += vpp_papi.py
35
36vpp_papi.py: $(prefix)/../vpp/api/vpe.api pneum/api-gen.py
37 @echo " PYTHON API"; \
38 $(CC) $(CPPFLAGS) -E -P -C -x c $< \
39 | vppapigen --input - --python defs_$@; \
40 echo "#include <api/vpe_msg_enum.h>" \
41 | $(CC) $(CPPFLAGS) -E -P -x c - | grep VL_API \
42 | @srcdir@/pneum/api-gen.py -i defs_$@ > @srcdir@/vpp_papi/$@
43
44#
45# Test client
46#
47noinst_PROGRAMS += test_pneum
48test_pneum_SOURCES = pneum/pneum.c pneum/test_pneum.c
49test_pneum_LDADD = -lvlibmemoryclient -lvlibapi -lsvm -lvppinfra -lpthread -lm -lrt