summaryrefslogtreecommitdiffstats
path: root/meta/classes/multilib_global.bbclass
diff options
context:
space:
mode:
authorJoshua Lock <joshua.g.lock@intel.com>2016-12-14 21:13:04 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-12-16 10:23:23 +0000
commitc4e2c59088765d1f1de7ec57cde91980f887c2ff (patch)
treea2fda8ac5916fb59a711e9220c2177008cca9347 /meta/classes/multilib_global.bbclass
parentd5e67725ac11e3296cad104470931ffa16824b90 (diff)
downloadpoky-c4e2c59088765d1f1de7ec57cde91980f887c2ff.tar.gz
meta: remove True option to getVar calls
getVar() now defaults to expanding by default, thus remove the True option from getVar() calls with a regex search and replace. Search made with the following regex: getVar ?\(( ?[^,()]*), True\) (From OE-Core rev: 7c552996597faaee2fbee185b250c0ee30ea3b5f) Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/multilib_global.bbclass')
-rw-r--r--meta/classes/multilib_global.bbclass22
1 files changed, 11 insertions, 11 deletions
diff --git a/meta/classes/multilib_global.bbclass b/meta/classes/multilib_global.bbclass
index 11ae2681f0..aba0371648 100644
--- a/meta/classes/multilib_global.bbclass
+++ b/meta/classes/multilib_global.bbclass
@@ -1,7 +1,7 @@
1def preferred_ml_updates(d): 1def preferred_ml_updates(d):
2 # If any PREFERRED_PROVIDER or PREFERRED_VERSION are set, 2 # If any PREFERRED_PROVIDER or PREFERRED_VERSION are set,
3 # we need to mirror these variables in the multilib case; 3 # we need to mirror these variables in the multilib case;
4 multilibs = d.getVar('MULTILIBS', True) or "" 4 multilibs = d.getVar('MULTILIBS') or ""
5 if not multilibs: 5 if not multilibs:
6 return 6 return
7 7
@@ -102,7 +102,7 @@ def preferred_ml_updates(d):
102 prov = prov.replace("virtual/", "") 102 prov = prov.replace("virtual/", "")
103 return "virtual/" + prefix + "-" + prov 103 return "virtual/" + prefix + "-" + prov
104 104
105 mp = (d.getVar("MULTI_PROVIDER_WHITELIST", True) or "").split() 105 mp = (d.getVar("MULTI_PROVIDER_WHITELIST") or "").split()
106 extramp = [] 106 extramp = []
107 for p in mp: 107 for p in mp:
108 if p.endswith("-native") or "-crosssdk-" in p or p.startswith(("nativesdk-", "virtual/nativesdk-")) or 'cross-canadian' in p: 108 if p.endswith("-native") or "-crosssdk-" in p or p.startswith(("nativesdk-", "virtual/nativesdk-")) or 'cross-canadian' in p:
@@ -111,14 +111,14 @@ def preferred_ml_updates(d):
111 extramp.append(translate_provide(pref, p)) 111 extramp.append(translate_provide(pref, p))
112 d.setVar("MULTI_PROVIDER_WHITELIST", " ".join(mp + extramp)) 112 d.setVar("MULTI_PROVIDER_WHITELIST", " ".join(mp + extramp))
113 113
114 abisafe = (d.getVar("SIGGEN_EXCLUDERECIPES_ABISAFE", True) or "").split() 114 abisafe = (d.getVar("SIGGEN_EXCLUDERECIPES_ABISAFE") or "").split()
115 extras = [] 115 extras = []
116 for p in prefixes: 116 for p in prefixes:
117 for a in abisafe: 117 for a in abisafe:
118 extras.append(p + "-" + a) 118 extras.append(p + "-" + a)
119 d.appendVar("SIGGEN_EXCLUDERECIPES_ABISAFE", " " + " ".join(extras)) 119 d.appendVar("SIGGEN_EXCLUDERECIPES_ABISAFE", " " + " ".join(extras))
120 120
121 siggen_exclude = (d.getVar("SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS", True) or "").split() 121 siggen_exclude = (d.getVar("SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS") or "").split()
122 extras = [] 122 extras = []
123 for p in prefixes: 123 for p in prefixes:
124 for a in siggen_exclude: 124 for a in siggen_exclude:
@@ -128,7 +128,7 @@ def preferred_ml_updates(d):
128 128
129python multilib_virtclass_handler_vendor () { 129python multilib_virtclass_handler_vendor () {
130 if isinstance(e, bb.event.ConfigParsed): 130 if isinstance(e, bb.event.ConfigParsed):
131 for v in e.data.getVar("MULTILIB_VARIANTS", True).split(): 131 for v in e.data.getVar("MULTILIB_VARIANTS").split():
132 if e.data.getVar("TARGET_VENDOR_virtclass-multilib-" + v, False) is None: 132 if e.data.getVar("TARGET_VENDOR_virtclass-multilib-" + v, False) is None:
133 e.data.setVar("TARGET_VENDOR_virtclass-multilib-" + v, e.data.getVar("TARGET_VENDOR", False) + "ml" + v) 133 e.data.setVar("TARGET_VENDOR_virtclass-multilib-" + v, e.data.getVar("TARGET_VENDOR", False) + "ml" + v)
134 preferred_ml_updates(e.data) 134 preferred_ml_updates(e.data)
@@ -140,14 +140,14 @@ python multilib_virtclass_handler_global () {
140 if not e.data: 140 if not e.data:
141 return 141 return
142 142
143 variant = e.data.getVar("BBEXTENDVARIANT", True) 143 variant = e.data.getVar("BBEXTENDVARIANT")
144 144
145 if isinstance(e, bb.event.RecipeParsed) and not variant: 145 if isinstance(e, bb.event.RecipeParsed) and not variant:
146 if bb.data.inherits_class('kernel', e.data) or \ 146 if bb.data.inherits_class('kernel', e.data) or \
147 bb.data.inherits_class('module-base', e.data) or \ 147 bb.data.inherits_class('module-base', e.data) or \
148 (bb.data.inherits_class('allarch', e.data) and\ 148 (bb.data.inherits_class('allarch', e.data) and\
149 not bb.data.inherits_class('packagegroup', e.data)): 149 not bb.data.inherits_class('packagegroup', e.data)):
150 variants = (e.data.getVar("MULTILIB_VARIANTS", True) or "").split() 150 variants = (e.data.getVar("MULTILIB_VARIANTS") or "").split()
151 151
152 import oe.classextend 152 import oe.classextend
153 clsextends = [] 153 clsextends = []
@@ -155,21 +155,21 @@ python multilib_virtclass_handler_global () {
155 clsextends.append(oe.classextend.ClassExtender(variant, e.data)) 155 clsextends.append(oe.classextend.ClassExtender(variant, e.data))
156 156
157 # Process PROVIDES 157 # Process PROVIDES
158 origprovs = provs = e.data.getVar("PROVIDES", True) or "" 158 origprovs = provs = e.data.getVar("PROVIDES") or ""
159 for clsextend in clsextends: 159 for clsextend in clsextends:
160 provs = provs + " " + clsextend.map_variable("PROVIDES", setvar=False) 160 provs = provs + " " + clsextend.map_variable("PROVIDES", setvar=False)
161 e.data.setVar("PROVIDES", provs) 161 e.data.setVar("PROVIDES", provs)
162 162
163 # Process RPROVIDES 163 # Process RPROVIDES
164 origrprovs = rprovs = e.data.getVar("RPROVIDES", True) or "" 164 origrprovs = rprovs = e.data.getVar("RPROVIDES") or ""
165 for clsextend in clsextends: 165 for clsextend in clsextends:
166 rprovs = rprovs + " " + clsextend.map_variable("RPROVIDES", setvar=False) 166 rprovs = rprovs + " " + clsextend.map_variable("RPROVIDES", setvar=False)
167 if rprovs.strip(): 167 if rprovs.strip():
168 e.data.setVar("RPROVIDES", rprovs) 168 e.data.setVar("RPROVIDES", rprovs)
169 169
170 # Process RPROVIDES_${PN}... 170 # Process RPROVIDES_${PN}...
171 for pkg in (e.data.getVar("PACKAGES", True) or "").split(): 171 for pkg in (e.data.getVar("PACKAGES") or "").split():
172 origrprovs = rprovs = e.data.getVar("RPROVIDES_%s" % pkg, True) or "" 172 origrprovs = rprovs = e.data.getVar("RPROVIDES_%s" % pkg) or ""
173 for clsextend in clsextends: 173 for clsextend in clsextends:
174 rprovs = rprovs + " " + clsextend.map_variable("RPROVIDES_%s" % pkg, setvar=False) 174 rprovs = rprovs + " " + clsextend.map_variable("RPROVIDES_%s" % pkg, setvar=False)
175 rprovs = rprovs + " " + clsextend.extname + "-" + pkg 175 rprovs = rprovs + " " + clsextend.extname + "-" + pkg