kbuild: allow "make" targets 'versioncheck' and 'includecheck' withoug .config file
PATCH 1/1 kbuild: allow "make" targets 'versioncheck' and 'includecheck' withoug .config file
Top-level Makefile targets 'versioncheck' and 'includecheck' don't need a configured kernel (i.e., don't need a .config file), so add them the the list of "no-dot-config-targets".
This eliminates the 'make' error:
***
*** Configuration file ".config" not found!
***
*** Please run some configurator (e.g. "make oldconfig" or *** "make menuconfig" or "make xconfig").
***
Makefile:759: include/config/auto.conf.cmd: No such file or directory
---
Fixes: I couldn't determine this.
Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Makefile +2 -1
@@ -274,7 +274,8 @@ no-dot-config-targets := $(clean-targets cscope gtags TAGS tags help% %docs check% coccicheck \ $(version_h) headers headers_% archheaders archscripts \ %asm-generic kernelversion %src-pkg dt_binding_check \ - outputmakefile rustfmt rustfmtcheck + outputmakefile rustfmt rustfmtcheck \ + versioncheck includecheck # Installation targets should not require compiler. Unfortunately, vdso_install # is an exception where build artifacts may be updated. This must be fixed. no-compiler-targets := $(no-dot-config-targets) install dtbs_install \
Quoted 27 lines · Randy Dunlap
Top-level
Makefiletargets 'versioncheck' and 'includecheck' don't need a configured kernel (i.e., don't need a .config file), so add them the the list of "no-dot-config-targets".
This eliminates the 'make' error:***
*** Configuration file ".config" not found!
***
*** Please run some configurator (e.g. "make oldconfig" or *** "make menuconfig" or "make xconfig").
***
Makefile:759:include/config/auto.conf.cmd: No such file or directorySigned-off-by Randy Dunlap <[email protected]>Cc Masahiro Yamada <[email protected]>Cc Michal Marek <[email protected]>---
Fixes: I couldn't determine this.Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Makefile no-dot-config-targets := $(clean-targets · line 281
Quoted 9 lines
Makefile +2
-1@@ -274,7 +274,8 @@ no-dot-config-targets := $(clean-targets cscope gtags TAGS tags help% %docs check% coccicheck \ $(version_h) headers headers_% archheaders archscripts \ %asm-generic kernelversion %src-pkg dt_binding_check \ - outputmakefile rustfmt rustfmtcheck + outputmakefile rustfmt rustfmtcheck \ + versioncheck includecheck # Installation targets should not require compiler. Unfortunately, vdso_install # is an exception where build artifacts may be updated. This must be fixed. no-compiler-targets := $(no-dot-config-targets) install dtbs_install \
There is no good reason to invoke checkincludes.pl via GNU Make in the first place.
A better solution is to do it by a shell script
or to make checkincludes.pl traverse the
subdirectories by itself.
[1] An easy solution
Add scripts/checkincludes-all:
#!/bin/sh
find . -name '*.[hcS]' -type f -print | sort \
| xargs $(dirname $0)/checkincludes.pl
Then, remove the 'includecheck' target from the Makefile.
You can do 'scripts/checkincludes-all'
instead of 'make includecheck'.
[2] A better solution
Extend scripts/checkincludes.pl so that it checks
all *.[hcS] files under the current directory
when no argument is passed.
You can simply do 'scripts/checkincludes.py'
Signature · 2 lines
Best Regards Masahiro Yamada
Quoted 13 lines · Randy Dunlap
Top-level
Makefiletargets 'versioncheck' and 'includecheck' don't need a configured kernel (i.e., don't need a .config file), so add them the the list of "no-dot-config-targets".
This eliminates the 'make' error:***
*** Configuration file ".config" not found!
***
*** Please run some configurator (e.g. "make oldconfig" or *** "make menuconfig" or "make xconfig").
***
Makefile:759:include/config/auto.conf.cmd: No such file or directory
Quoted 5 lines
Signed-off-by Randy Dunlap <[email protected]>Cc Masahiro Yamada <[email protected]>Cc Michal Marek <[email protected]>---
I like that change, works for me as expected. Possibly you might want to fix the commit subject typo (withoug -> without).
Regards,
Nicolas
Quoted 17 lines
Fixes I couldn't determine this.Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)Makefile +2
-1@@ -274,7 +274,8 @@ no-dot-config-targets := $(clean-targets cscope gtags TAGS tags help% %docs check% coccicheck \ $(version_h) headers headers_% archheaders archscripts \ %asm-generic kernelversion %src-pkg dt_binding_check \ - outputmakefile rustfmt rustfmtcheck + outputmakefile rustfmt rustfmtcheck \ + versioncheck includecheck # Installation targets should not require compiler. Unfortunately, vdso_install # is an exception where build artifacts may be updated. This must be fixed. no-compiler-targets := $(no-dot-config-targets) install dtbs_install \
Quoted 14 lines · Nicolas Schier
Quoted 13 lines · Randy Dunlap
Top-level
Makefiletargets 'versioncheck' and 'includecheck' don't need a configured kernel (i.e., don't need a .config file), so add them the the list of "no-dot-config-targets".
This eliminates the 'make' error:***
*** Configuration file ".config" not found!
***
*** Please run some configurator (e.g. "make oldconfig" or *** "make menuconfig" or "make xconfig").
***
Makefile:759:include/config/auto.conf.cmd: No such file or directory
Quoted 9 lines
Quoted 5 lines
Signed-off-by Randy Dunlap <[email protected]>Cc Masahiro Yamada <[email protected]>Cc Michal Marek <[email protected]>---
I like that change, works for me as expected. Possibly you might want to fix the commit subject typo (withoug -> without).
Yes, I noticed that a few minutes after I sent it, but I guess that this patch isn't going anywhere.
Thanks.
Quoted 19 lines
Quoted 19 lines
Fixes I couldn't determine this.Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)Makefile +2
-1@@ -274,7 +274,8 @@ no-dot-config-targets := $(clean-targets cscope gtags TAGS tags help% %docs check% coccicheck \ $(version_h) headers headers_% archheaders archscripts \ %asm-generic kernelversion %src-pkg dt_binding_check \ - outputmakefile rustfmt rustfmtcheck + outputmakefile rustfmt rustfmtcheck \ + versioncheck includecheck # Installation targets should not require compiler. Unfortunately, vdso_install # is an exception where build artifacts may be updated. This must be fixed. no-compiler-targets := $(no-dot-config-targets) install dtbs_install \
Signature · 1 line
~Randy