From b1e7ead54babc5db656b5200684b743520d6b51f Mon Sep 17 00:00:00 2001 From: Ole Troan Date: Mon, 12 Dec 2016 15:02:59 +0000 Subject: ACL: Install ACL JSON in install directory. Change-Id: I3f7dbd23114acf37322f97da80be746616a9d95d Signed-off-by: Ole Troan --- plugins/acl-plugin/Makefile.am | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) (limited to 'plugins/acl-plugin/Makefile.am') diff --git a/plugins/acl-plugin/Makefile.am b/plugins/acl-plugin/Makefile.am index bab1ccb5..83852d0e 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) -- cgit 1.2.3-korg