mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-08 21:22:09 -04:00
scripts: gki: Fix setting of a CONFIG if it's unset in base defconfig
CONFIGs that are unset in base defconfig (# CONFIG_X is not set), but gets enabled in fragments through menuconfig, the diff is shown as: -# CONFIG_X is not set. However, for the fragments to work correctly, it must be set to 'y'. Hence, explicitly set them in the config fragments. Change-Id: Ic1c1578fb8109c09f3f39b9d254474d2c341a6d6 Signed-off-by: Raghavendra Rao Ananta <rananta@codeaurora.org>
This commit is contained in:
parent
9b450de075
commit
ac63c97d08
1 changed files with 10 additions and 0 deletions
|
|
@ -95,6 +95,16 @@ for config_del in $configs_to_remove; do
|
|||
sed -i "/$config_del/d" ${FRAG_CONFIG}
|
||||
done
|
||||
|
||||
# CONFIGs that are unset in base defconfig (# CONFIG_X is not set), but enabled in fragments,
|
||||
# the diff is shown as: -# CONFIG_X is not set. Hence, explicitly set them in the config fragments.
|
||||
configs_to_set=`diff -u defconfig_base defconfig | grep "^-# CONFIG_" | awk '{print $2}'`
|
||||
for config_to_set in $configs_to_set; do
|
||||
# The CONFIG could be set as 'm' in the previous steps. Ignore setting them to 'y'
|
||||
if ! grep -q "$config_to_set" ${FRAG_CONFIG}; then
|
||||
echo $config_to_set=y >> ${FRAG_CONFIG}
|
||||
fi
|
||||
done
|
||||
|
||||
# CONFIGs that are set in base defconfig (or lower fragment), but wanted it to be disabled in FRAG_CONFIG
|
||||
diff -u .config_base .config | grep "^+# CONFIG_" | sed 's/^.//' >> ${FRAG_CONFIG}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue