Skip to content

Commit

Permalink
merge_config.sh: Use the first file as the initial config
Browse files Browse the repository at this point in the history
Take the first config fragment and use it verbatim as the initial config
set.  This avoids running the verification loop for the first file, as
nothing has actually been merged at this point.  This significantly
increases performance for large config fragments.

Signed-off-by: Josh Boyer <jwboyer@redhat.com>
Acked-by: John Stultz <john.stultz@linaro.org>
Acked-by: Darren Hart <dvhart@linux.intel.com>
Signed-off-by: Michal Marek <mmarek@suse.cz>
  • Loading branch information
Josh Boyer authored and Michal Marek committed Mar 24, 2012
1 parent 5d09598 commit 0928061
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion scripts/kconfig/merge_config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,16 @@ while true; do
esac
done


INITFILE=$1
shift;

MERGE_LIST=$*
SED_CONFIG_EXP="s/^\(# \)\{0,1\}\(CONFIG_[a-zA-Z0-9_]*\)[= ].*/\2/p"
TMP_FILE=$(mktemp ./.tmp.config.XXXXXXXXXX)

echo "Using $INITFILE as base"
cat $INITFILE > $TMP_FILE

# Merge files, printing warnings on overrided values
for MERGE_FILE in $MERGE_LIST ; do
echo "Merging $MERGE_FILE"
Expand Down

0 comments on commit 0928061

Please sign in to comment.