From c4ca3ef5e780100d5760766379721c1edadaa8b3 Mon Sep 17 00:00:00 2001 From: David Lamparter Date: Wed, 3 Jul 2019 14:53:32 +0200 Subject: clippy: find headers relative to source tree The current directory is in the build tree while running clippy; find ourselves so we can access headers from the source tree. Signed-off-by: David Lamparter --- python/clidef.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'python') diff --git a/python/clidef.py b/python/clidef.py index 85464a62d..bc2f5caeb 100644 --- a/python/clidef.py +++ b/python/clidef.py @@ -346,9 +346,11 @@ if __name__ == '__main__': if args.show: dumpfd = sys.stderr + basepath = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) + macros = Macros() macros.load('lib/route_types.h') - macros.load('lib/command.h') + macros.load(os.path.join(basepath, 'lib/command.h')) # sigh :( macros['PROTO_REDIST_STR'] = 'FRR_REDIST_STR_ISISD' -- cgit v1.2.3