diff options
author | Masahiro Yamada <masahiroy@kernel.org> | 2022-12-11 14:04:07 +0100 |
---|---|---|
committer | Masahiro Yamada <masahiroy@kernel.org> | 2022-12-14 07:42:40 +0100 |
commit | f65a486821cfd363833079b2a7b0769250ee21c9 (patch) | |
tree | e80172fa864beca08f6ca876eff2f523128782a0 /scripts/clang-tools | |
parent | kbuild: use .NOTINTERMEDIATE for future GNU Make versions (diff) | |
download | linux-f65a486821cfd363833079b2a7b0769250ee21c9.tar.xz linux-f65a486821cfd363833079b2a7b0769250ee21c9.zip |
kbuild: change module.order to list *.o instead of *.ko
scripts/Makefile.build replaces the suffix .o with .ko, then
scripts/Makefile.modpost calls the sed command to change .ko back
to the original .o suffix.
Instead of converting the suffixes back-and-forth, store the .o paths
in modules.order, and replace it with .ko in 'make modules_install'.
This avoids the unneeded sed command.
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Diffstat (limited to 'scripts/clang-tools')
-rwxr-xr-x | scripts/clang-tools/gen_compile_commands.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/clang-tools/gen_compile_commands.py b/scripts/clang-tools/gen_compile_commands.py index d800b2c0af97..0227522959a4 100755 --- a/scripts/clang-tools/gen_compile_commands.py +++ b/scripts/clang-tools/gen_compile_commands.py @@ -138,10 +138,10 @@ def cmdfiles_for_modorder(modorder): """ with open(modorder) as f: for line in f: - ko = line.rstrip() - base, ext = os.path.splitext(ko) - if ext != '.ko': - sys.exit('{}: module path must end with .ko'.format(ko)) + obj = line.rstrip() + base, ext = os.path.splitext(obj) + if ext != '.o': + sys.exit('{}: module path must end with .o'.format(obj)) mod = base + '.mod' # Read from *.mod, to get a list of objects that compose the module. with open(mod) as m: |