From e8f84d205910f7ee5a20a6d44b4c702a9a23135e Mon Sep 17 00:00:00 2001 From: Kortan Date: Wed, 8 Sep 2021 11:28:48 +0800 Subject: [PATCH] gen_compile_commands: fix missing 'sys' package commit ec783c7cb2495c5a3b8ca10db8056d43c528f940 upstream. We need to import the 'sys' package since the script has called sys.exit() method. Fixes: 6ad7cbc01527 ("Makefile: Add clang-tidy and static analyzer support to makefile") Signed-off-by: Kortan Reviewed-by: Nathan Chancellor Signed-off-by: Masahiro Yamada Signed-off-by: Greg Kroah-Hartman --- scripts/clang-tools/gen_compile_commands.py | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/clang-tools/gen_compile_commands.py b/scripts/clang-tools/gen_compile_commands.py index b7e9ecf16e56..a70cd064bfc4 100755 --- a/scripts/clang-tools/gen_compile_commands.py +++ b/scripts/clang-tools/gen_compile_commands.py @@ -13,6 +13,7 @@ import logging import os import re import subprocess +import sys _DEFAULT_OUTPUT = 'compile_commands.json' _DEFAULT_LOG_LEVEL = 'WARNING'