aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/acl-plugin/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/acl-plugin/Makefile.am')
-rw-r--r--plugins/acl-plugin/Makefile.am23
1 files changed, 12 insertions, 11 deletions
diff --git a/plugins/acl-plugin/Makefile.am b/plugins/acl-plugin/Makefile.am
index bab1ccb59f2..83852d0e6cc 100644
--- a/plugins/acl-plugin/Makefile.am
+++ b/plugins/acl-plugin/Makefile.am
@@ -31,20 +31,26 @@ acl_plugin_la_SOURCES = \
acl/l2sess.h \
acl/acl_plugin.api.h
-BUILT_SOURCES = acl/acl.api.h
+BUILT_SOURCES = acl/acl.api.h acl/acl.api.json
-SUFFIXES = .api.h .api
+SUFFIXES = .api.h .api .api.json
#
# ACL API
#
%.api.h: %.api
- mkdir -p $(dir $@) ; \
+ mkdir -p `dirname $@` ; \
$(CC) $(CPPFLAGS) -E -P -C -x c $^ \
| vppapigen --input - --output $@ --show-name $@
+%.api.json: %.api
+ @echo " JSON APIGEN " $@ ; \
+ mkdir -p `dirname $@` ; \
+ $(CC) $(CPPFLAGS) -E -P -C -x c $^ \
+ | vppapigen --input - --json $@
+
apidir = $(prefix)/acl
-api_DATA = acl/acl.api
+api_DATA = acl/acl.api.json
noinst_HEADERS = \
acl/acl_all_api_h.h \
@@ -68,7 +74,6 @@ jvpp_package_dir = io/fd/vpp/jvpp/acl
jvpp_root = acl/jvpp
jvpp_target_dir = target
jvpp_target = $(jvpp_root)/$(jvpp_target_dir)
-api_file=$(srcdir)/acl/acl.api
lib_LTLIBRARIES = libjvpp_acl.la
libjvpp_acl_la_SOURCES = acl/acl.api.h acl/jvpp_acl.c acl/jvpp/io_fd_vpp_jvpp_acl_JVppAclImpl.h
@@ -79,13 +84,13 @@ libjvpp_acl_la_CPPFLAGS = -I$(JAVA_HOME)/include -I$(JAVA_HOME)/include/linux -I
BUILT_SOURCES += $(jvpp_root)/io_fd_vpp_jvpp_acl_JVppAclImpl.h
-$(jvpp_root)/io_fd_vpp_jvpp_acl_JVppAclImpl.h: acl.api.json
+$(jvpp_root)/io_fd_vpp_jvpp_acl_JVppAclImpl.h: acl/acl.api.json
dir=`pwd`; \
mkdir -p $(jvpp_target); \
mkdir -p $(jvpp_root)/$(jvpp_package_dir); \
cd $(jvpp_root)/$(jvpp_package_dir); \
mkdir -p types dto future callfacade callback notification test; \
- @srcdir@/$(jvpp_registry_root)/jvpp/gen/jvpp_gen.py -i $${dir}/acl.api.json --plugin_name acl; \
+ @srcdir@/$(jvpp_registry_root)/jvpp/gen/jvpp_gen.py -i $${dir}/acl/acl.api.json --plugin_name acl; \
cd -; \
mv -f $(jvpp_root)/$(jvpp_package_dir)/jvpp_acl_gen.h $(jvpp_root)/jvpp_acl_gen.h; \
cp $(srcdir)/$(jvpp_root)/$(jvpp_package_dir)/test/*.java $(jvpp_root)/$(jvpp_package_dir)/test/; \
@@ -106,8 +111,4 @@ $(jacl_jarfile): libjvpp_acl.la
cd $(jvpp_target); \
$(JAR) cfv $(JARFLAGS) ../../../$@ libjvpp_acl.so.0.0.0 $(jvpp_package_dir)/* ; cd ..;
-acl.api.json:
- @echo " jAcl_sfc API"; \
- vppapigen --input $(api_file) --json acl.api.json;
-
all-local: $(jacl_jarfile)