aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/configure.ac5
-rw-r--r--src/suffix-rules.mk7
-rwxr-xr-xsrc/tools/vppapigen/vppapigen.py5
3 files changed, 8 insertions, 9 deletions
diff --git a/src/configure.ac b/src/configure.ac
index d9c8a47b582..1ee55e7ba68 100644
--- a/src/configure.ac
+++ b/src/configure.ac
@@ -297,11 +297,6 @@ AM_COND_IF([WITH_MBEDTLS],
], [])
])
-AC_PATH_PROG([VPPAPIGEN], [vppapigen], [no])
-if test "$VPPAPIGEN" = "no"; then
- VPPAPIGEN=\$\(top_srcdir\)/tools/vppapigen/vppapigen
-fi
-
###############################################################################
# JAVA
###############################################################################
diff --git a/src/suffix-rules.mk b/src/suffix-rules.mk
index 495d828f348..8b1ab83b28b 100644
--- a/src/suffix-rules.mk
+++ b/src/suffix-rules.mk
@@ -14,12 +14,13 @@
# Shared suffix rules
# Please do not set "SUFFIXES = .api.h .api" here
-%.api.h: %.api @VPPAPIGEN@
+VPPAPIGEN = $(top_srcdir)/tools/vppapigen/vppapigen
+%.api.h: %.api
@echo " APIGEN " $@ ; \
mkdir -p `dirname $@` ; \
- @VPPAPIGEN@ --includedir $(top_srcdir) --input $< --output $@
+ $(VPPAPIGEN) --includedir $(top_srcdir) --input $< --output $@
%.api.json: %.api
@echo " JSON API" $@ ; \
mkdir -p `dirname $@` ; \
- @VPPAPIGEN@ --includedir $(top_srcdir) --input $< JSON --output $@
+ $(VPPAPIGEN) --includedir $(top_srcdir) --input $< JSON --output $@
diff --git a/src/tools/vppapigen/vppapigen.py b/src/tools/vppapigen/vppapigen.py
index e6237a753f9..628bb09def7 100755
--- a/src/tools/vppapigen/vppapigen.py
+++ b/src/tools/vppapigen/vppapigen.py
@@ -9,6 +9,9 @@ import logging
import binascii
import os
+# Ensure we don't leave temporary files around
+sys.dont_write_bytecode = True
+
#
# VPP API language
#
@@ -527,7 +530,7 @@ class VPPAPI(object):
def __init__(self, debug=False, filename='', logger=None):
self.lexer = lex.lex(module=VPPAPILexer(filename), debug=debug)
self.parser = yacc.yacc(module=VPPAPIParser(filename, logger),
- tabmodule='vppapigentab', debug=debug)
+ write_tables=False, debug=debug)
self.logger = logger
def parse_string(self, code, debug=0, lineno=1):