summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorChen Qi <Qi.Chen@windriver.com>2021-08-06 02:03:31 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-08-12 06:26:15 +0100
commit62372aedfe5e04b6b0c0bc5dba7c29bd4685e83b (patch)
treed8b13f52e02c4b67d209de168100728cf5fb3d5a /scripts
parent2f743b473938e798bff7122d1be177ce8e460d8b (diff)
downloadpoky-62372aedfe5e04b6b0c0bc5dba7c29bd4685e83b.tar.gz
convert-overrides.py: also convert comments without a leading whitespace
Currently lines like below are converted. e.g. # IMAGE_INSTALL_append = " A" But lines without a leading whitespace are not converted. e.g. #IMAGE_INSTALL_append = " A" We should be converting both. (From OE-Core rev: 1994e3844c1aa6b595c0c18040e4f8240fa04438) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/contrib/convert-overrides.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/contrib/convert-overrides.py b/scripts/contrib/convert-overrides.py
index e4a310d1d6..4d41a4c475 100755
--- a/scripts/contrib/convert-overrides.py
+++ b/scripts/contrib/convert-overrides.py
@@ -69,15 +69,15 @@ packagevars = packagevars + imagevars
69 69
70vars_re = {} 70vars_re = {}
71for exp in vars: 71for exp in vars:
72 vars_re[exp] = (re.compile('((^|[\'"\s\-\+])[A-Za-z0-9_\-:${}\.]+)_' + exp), r"\1:" + exp) 72 vars_re[exp] = (re.compile('((^|[#\'"\s\-\+])[A-Za-z0-9_\-:${}\.]+)_' + exp), r"\1:" + exp)
73 73
74shortvars_re = {} 74shortvars_re = {}
75for exp in shortvars: 75for exp in shortvars:
76 shortvars_re[exp] = (re.compile('((^|[\'"\s\-\+])[A-Za-z0-9_\-:${}\.]+)_' + exp + '([\(\'"\s:])'), r"\1:" + exp + r"\3") 76 shortvars_re[exp] = (re.compile('((^|[#\'"\s\-\+])[A-Za-z0-9_\-:${}\.]+)_' + exp + '([\(\'"\s:])'), r"\1:" + exp + r"\3")
77 77
78package_re = {} 78package_re = {}
79for exp in packagevars: 79for exp in packagevars:
80 package_re[exp] = (re.compile('(^|[\'"\s\-\+]+)' + exp + '_' + '([$a-z"\'\s%\[<{\\\*].)'), r"\1" + exp + r":\2") 80 package_re[exp] = (re.compile('(^|[#\'"\s\-\+]+)' + exp + '_' + '([$a-z"\'\s%\[<{\\\*].)'), r"\1" + exp + r":\2")
81 81
82# Other substitutions to make 82# Other substitutions to make
83subs = { 83subs = {