Skip to content

Commit 0c33f12

Browse files
lucvoomasahir0y
authored andcommitted
kbuild: run the checker after the compiler
Since the pre-git time the checker is run first, before the compiler. But if the source file contains some syntax error, the warnings from the compiler are more useful than those from sparse (and other checker most probably too). So move the 'check' command to run after the compiler. Signed-off-by: Luc Van Oostenryck <[email protected]> Signed-off-by: Masahiro Yamada <[email protected]>
1 parent dcb7fd8 commit 0c33f12

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

scripts/Makefile.build

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -252,9 +252,9 @@ cmd_gen_ksymdeps = \
252252
endif
253253

254254
define rule_cc_o_c
255-
$(call cmd,checksrc)
256255
$(call cmd_and_fixdep,cc_o_c)
257256
$(call cmd,gen_ksymdeps)
257+
$(call cmd,checksrc)
258258
$(call cmd,checkdoc)
259259
$(call cmd,objtool)
260260
$(call cmd,modversions_c)
@@ -277,8 +277,8 @@ endif
277277

278278
# Built-in and composite module parts
279279
$(obj)/%.o: $(src)/%.c $(recordmcount_source) $(objtool_dep) FORCE
280-
$(call cmd,force_checksrc)
281280
$(call if_changed_rule,cc_o_c)
281+
$(call cmd,force_checksrc)
282282

283283
cmd_mod = { \
284284
echo $(if $($*-objs)$($*-y)$($*-m), $(addprefix $(obj)/, $($*-objs) $($*-y) $($*-m)), $(@:.mod=.o)); \

0 commit comments

Comments
 (0)