Skip to contentSkip to conversation

kconfig: show an error message when defconfig is not found

PATCH Superseded Masahiro Yamada 4 participants 5 messages Sep 4, 2014 – Oct 1, 2014

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 kconfig: show an error message when defconfig is not found

When a non-existing defconfig is specified,
display an easy-to-understand message
(fake the error message on Linux Kernel):

  $ make foo_defconfig
  ***
  *** Can't find default configuration "confis/foo_defconfig"!
  ***

---

Changes in v2:
- Echo the error message to stderr

 scripts/multiconfig.sh | 7 +++++++
 1 file changed, 7 insertions(+)
scripts/multiconfig.sh +7 -0
index a579042..49fcfad 100644
@@ -118,6 +118,13 @@ do_board_defconfig () {
 	defconfig_path=$srctree/configs/$1
 	tmp_defconfig_path=configs/.tmp_defconfig
 
+	if [ ! -r $defconfig_path ]; then
+		echo >&2 "***"
+		echo >&2 "*** Can't find default configuration \"confis/$1\"!"
+		echo >&2 "***"
+		exit 1
+	fi
+
 	mkdir -p arch configs
 	# defconfig for Normal:
 	#  pick lines without prefixes and lines starting '+' prefix
Signature · 1 line
1.9.1
#1 lore raw

PATCH v2 1/1 kconfig: show an error message when defconfig is not found

Quoted 8 lines · Masahiro Yamada

When a non-existing defconfig is specified,
display an easy-to-understand message
(fake the error message on Linux Kernel):

   $ make foo_defconfig
   ***
   *** Can't find default configuration "confis/foo_defconfig"!
   ***
#2 lore raw

PATCH v2 1/1 kconfig: show an error message when defconfig is not found

In reply to Masahiro Yamada
Quoted 11 lines · Masahiro Yamada

When a non-existing defconfig is specified,
display an easy-to-understand message
(fake the error message on Linux Kernel):

  $ make foo_defconfig
  ***
  *** Can't find default configuration "confis/foo_defconfig"!
  ***

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140916/faae78d9/attachment.pgp>
#3 lore raw

PATCH v2 1/1 kconfig: show an error message when defconfig is not found

In reply to Masahiro Yamada
Quoted 23 lines · Masahiro Yamada

When a non-existing defconfig is specified,
display an easy-to-understand message
(fake the error message on Linux Kernel):

  $ make foo_defconfig
  ***
  *** Can't find default configuration "confis/foo_defconfig"!
  ***

---

Changes in v2:
- Echo the error message to stderr

 scripts/multiconfig.sh | 7 +++++++
 1 file changed, 7 insertions(+)
scripts/multiconfig.sh +0 -0
index a579042..49fcfad 100644

scripts/multiconfig.sh do_board_defconfig () { · line 123

Quoted 6 lines
scripts/multiconfig.sh +3 -0
@@ -118,6 +118,13 @@ do_board_defconfig () {
 	defconfig_path=$srctree/configs/$1
 	tmp_defconfig_path=configs/.tmp_defconfig
 
+	if [ ! -r $defconfig_path ]; then
+		echo >&2 "***"
+		echo >&2 "*** Can't find default configuration \"confis/$1\"!"

s/confis/configs/

York

#4 lore raw

PATCH v2 1/1 kconfig: show an error message when defconfig is not found

Hi York.

2014-10-02 0:29 GMT+09:00 York Sun <[email protected]>:

Quoted 6 lines

scripts/multiconfig.sh do_board_defconfig () { · line 123

Quoted 3 lines
scripts/multiconfig.sh +3 -0
+     if [ ! -r $defconfig_path ]; then
+             echo >&2 "***"
+             echo >&2 "*** Can't find default configuration \"confis/$1\"!"

s/confis/configs/

Oops!
Thanks for spotting this.

Could send a patch, please?

Signature · 2 lines
Best Regards
Masahiro Yamada