All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] merge_config.sh: Fix finding redundant config mechanism
@ 2018-10-19 22:58 Nasser
  2018-10-20 14:56 ` Matthew Weber
  0 siblings, 1 reply; 51+ messages in thread
From: Nasser @ 2018-10-19 22:58 UTC (permalink / raw)
  To: buildroot

We use BR2_* style for configuration variables in buildroot so we should
use this style when extracting configuration options. Otherwise CFG_LIST
will almost always be empty.

The CONFIG_* style has been taken form the Linux kernel and is not
appropriate in this context.

Signed-off-by: Nasser <Afshin.Nasser@gmail.com>
---

If you add 'set -x' in the beginning of the script you can see that $CFG_LIST
is always empty.

When having redundancy in the configuration fragments, you can see that the
$TMP_FILE file has redundant configuration options when calling 'make'. Note
that after applying this patch, calling 'make' in this script, will not produce
any warnings due to redundancy issues anymore. This is because now repeated
options are all properly omitted before calling 'make'. After applying this
patch '-r -m' options work as expected.

Further more, note that without this patch, any inconsistent re-assignment is
not reported by this script. Although there are some warnings if you did not
specify -m option. They are all 'make' reports.

 support/kconfig/merge_config.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/support/kconfig/merge_config.sh b/support/kconfig/merge_config.sh
index 67d1314..87a8d02 100755
--- a/support/kconfig/merge_config.sh
+++ b/support/kconfig/merge_config.sh
@@ -99,7 +99,7 @@ if [ ! -r "$INITFILE" ]; then
 fi
 
 MERGE_LIST=$*
-SED_CONFIG_EXP="s/^\(# \)\{0,1\}\(CONFIG_[a-zA-Z0-9_]*\)[= ].*/\2/p"
+SED_CONFIG_EXP="s/^\(# \)\{0,1\}\(BR2_[a-zA-Z0-9_]*\)[= ].*/\2/p"
 TMP_FILE=$(mktemp ./.tmp.config.XXXXXXXXXX)
 
 echo "Using $INITFILE as base"
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 51+ messages in thread

end of thread, other threads:[~2018-11-14  7:18 UTC | newest]

Thread overview: 51+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-19 22:58 [Buildroot] [PATCH] merge_config.sh: Fix finding redundant config mechanism Nasser
2018-10-20 14:56 ` Matthew Weber
2018-10-20 16:01   ` Arnout Vandecappelle
2018-10-21 17:27     ` Petr Vorel
2018-10-21 17:35       ` Matthew Weber
2018-10-21 17:46         ` Petr Vorel
2018-10-23 15:19     ` Nasser Afshin
2018-10-23 18:20       ` Arnout Vandecappelle
2018-10-24 19:15         ` Petr Vorel
2018-10-24 23:00           ` Nasser
2018-10-25  1:13         ` [Buildroot] [PATCH v2] merge_config.sh: merge also buildroot config files Nasser Afshin
2018-10-25  1:19           ` Nasser
2018-10-25  2:20           ` [Buildroot] [PATCH v3] " Nasser Afshin
2018-10-25  6:02             ` [Buildroot] Antwort: " Marcel Patzlaff
2018-10-25  7:43             ` [Buildroot] " Petr Vorel
2018-10-25  9:43               ` [Buildroot] Antwort: " Marcel Patzlaff
2018-10-25 21:43                 ` Petr Vorel
2018-10-26  6:03                   ` [Buildroot] Antwort: " Marcel Patzlaff
2018-10-26 23:05                     ` Nasser
2018-10-27  4:46                       ` Petr Vorel
2018-10-27 10:48                         ` Nasser Afshin
2018-10-31 19:35                           ` [Buildroot] " Petr Vorel
2018-10-31 20:38                             ` Nasser
2018-10-31 20:56                               ` Petr Vorel
2018-11-01  1:09                                 ` [Buildroot] [PATCH] merge_config.sh: Fix merging " Nasser Afshin
2018-11-01  3:51                                   ` yamada.masahiro at socionext.com
2018-11-01  5:49                                     ` Petr Vorel
2018-11-01  8:12                                       ` Nasser
2018-11-01  6:24                                   ` Petr Vorel
2018-11-01 10:55                                     ` Nasser
2018-11-01 12:05                                       ` Arnout Vandecappelle
2018-11-01 16:19                                         ` Petr Vorel
2018-11-02  2:12                                           ` Nasser
2018-11-02  7:55                                             ` yamada.masahiro at socionext.com
2018-11-02 10:05                                               ` Arnout Vandecappelle
2018-11-02 22:50                                                 ` Petr Vorel
2018-11-03 21:32                                                   ` Nasser
2018-11-05  8:23                                                     ` yamada.masahiro at socionext.com
2018-11-05  8:35                                                       ` Petr Vorel
2018-11-13 13:44                                                         ` [Buildroot] [PATCH v3 0/3] Fix merging configuration fragments Nasser Afshin
2018-11-13 13:44                                                           ` [Buildroot] [PATCH v3 1/3] merge_config.sh: Fix merging buildroot config files Nasser Afshin
2018-11-13 18:35                                                             ` Petr Vorel
2018-11-14  7:16                                                               ` Nasser Afshin
2018-11-13 13:44                                                           ` [Buildroot] [PATCH v3 2/3] test-pkg: Use the correct config prefix when merging Nasser Afshin
2018-11-13 18:26                                                             ` Petr Vorel
2018-11-13 13:44                                                           ` [Buildroot] [PATCH v3 3/3] merge_config.sh: Avoid false positive matches from comment lines Nasser Afshin
2018-11-13 18:38                                                             ` Petr Vorel
2018-11-14  7:18                                                           ` [Buildroot] [PATCH v3 0/3] Fix merging configuration fragments Nasser Afshin
2018-11-01 13:23                                       ` [Buildroot] [PATCH] merge_config.sh: Fix merging buildroot config files Petr Vorel
2018-11-02  2:18                                         ` Nasser
2018-10-29 15:46                     ` [Buildroot] Antwort: Re: Antwort: Re: [PATCH v3] merge_config.sh: merge also " Petr Vorel

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.