summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/base.bbclass7
-rw-r--r--meta/classes/bugzilla.bbclass1
-rw-r--r--meta/classes/buildhistory.bbclass8
-rw-r--r--meta/classes/buildstats.bbclass1
-rw-r--r--meta/classes/cross.bbclass4
-rw-r--r--meta/classes/distrodata.bbclass44
-rw-r--r--meta/classes/migrate_localcount.bbclass68
-rw-r--r--meta/classes/multilib.bbclass4
-rw-r--r--meta/classes/multilib_global.bbclass1
-rw-r--r--meta/classes/native.bbclass4
-rw-r--r--meta/classes/nativesdk.bbclass4
-rw-r--r--meta/classes/packageinfo.bbclass50
-rw-r--r--meta/classes/prexport.bbclass1
-rw-r--r--meta/classes/primport.bbclass1
-rw-r--r--meta/classes/recipe_sanity.bbclass4
-rw-r--r--meta/classes/sanity.bbclass1
-rw-r--r--meta/classes/typecheck.bbclass8
-rw-r--r--meta/conf/distro/include/csl-versions.inc3
-rw-r--r--meta/conf/distro/include/tcmode-external-sourcery.inc8
19 files changed, 107 insertions, 115 deletions
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index 8af104f765..3a0ff6bd63 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -32,12 +32,12 @@ def oe_import(d):
32 inject(toimport.split(".", 1)[0], imported) 32 inject(toimport.split(".", 1)[0], imported)
33 33
34python oe_import_eh () { 34python oe_import_eh () {
35 if isinstance(e, bb.event.ConfigParsed): 35 oe_import(e.data)
36 oe_import(e.data) 36 e.data.setVar("NATIVELSBSTRING", lsb_distro_identifier(e.data))
37 e.data.setVar("NATIVELSBSTRING", lsb_distro_identifier(e.data))
38} 37}
39 38
40addhandler oe_import_eh 39addhandler oe_import_eh
40oe_import_eh[eventmask] = "bb.event.ConfigParsed"
41 41
42def lsb_distro_identifier(d): 42def lsb_distro_identifier(d):
43 adjust = d.getVar('LSB_DISTRO_ADJUST', True) 43 adjust = d.getVar('LSB_DISTRO_ADJUST', True)
@@ -299,6 +299,7 @@ def buildcfg_neededvars(d):
299 bb.fatal('The following variable(s) were not set: %s\nPlease set them directly, or choose a MACHINE or DISTRO that sets them.' % ', '.join(pesteruser)) 299 bb.fatal('The following variable(s) were not set: %s\nPlease set them directly, or choose a MACHINE or DISTRO that sets them.' % ', '.join(pesteruser))
300 300
301addhandler base_eventhandler 301addhandler base_eventhandler
302base_eventhandler[eventmask] = "bb.event.ConfigParsed bb.event.BuildStarted"
302python base_eventhandler() { 303python base_eventhandler() {
303 if isinstance(e, bb.event.ConfigParsed): 304 if isinstance(e, bb.event.ConfigParsed):
304 e.data.setVar('BB_VERSION', bb.__version__) 305 e.data.setVar('BB_VERSION', bb.__version__)
diff --git a/meta/classes/bugzilla.bbclass b/meta/classes/bugzilla.bbclass
index 006763d2c7..3fc8956428 100644
--- a/meta/classes/bugzilla.bbclass
+++ b/meta/classes/bugzilla.bbclass
@@ -71,6 +71,7 @@ def bugzilla_add_comment(debug_file, server, args, bug_number, text):
71 return False 71 return False
72 72
73addhandler bugzilla_eventhandler 73addhandler bugzilla_eventhandler
74bugzilla_eventhandler[eventmask] = "bb.event.MsgNote bb.build.TaskFailed"
74python bugzilla_eventhandler() { 75python bugzilla_eventhandler() {
75 import glob 76 import glob
76 import xmlrpclib, httplib 77 import xmlrpclib, httplib
diff --git a/meta/classes/buildhistory.bbclass b/meta/classes/buildhistory.bbclass
index 450eb7cb80..c8fd68c39e 100644
--- a/meta/classes/buildhistory.bbclass
+++ b/meta/classes/buildhistory.bbclass
@@ -525,13 +525,13 @@ END
525} 525}
526 526
527python buildhistory_eventhandler() { 527python buildhistory_eventhandler() {
528 if isinstance(e, bb.event.BuildCompleted): 528 if e.data.getVar('BUILDHISTORY_FEATURES', True).strip():
529 if e.data.getVar('BUILDHISTORY_FEATURES', True).strip(): 529 if e.data.getVar("BUILDHISTORY_COMMIT", True) == "1":
530 if e.data.getVar("BUILDHISTORY_COMMIT", True) == "1": 530 bb.build.exec_func("buildhistory_commit", e.data)
531 bb.build.exec_func("buildhistory_commit", e.data)
532} 531}
533 532
534addhandler buildhistory_eventhandler 533addhandler buildhistory_eventhandler
534buildhistory_eventhandler[eventmask] = "bb.event.BuildCompleted"
535 535
536 536
537# FIXME this ought to be moved into the fetcher 537# FIXME this ought to be moved into the fetcher
diff --git a/meta/classes/buildstats.bbclass b/meta/classes/buildstats.bbclass
index e12e14fcd6..b98ba3bea7 100644
--- a/meta/classes/buildstats.bbclass
+++ b/meta/classes/buildstats.bbclass
@@ -278,4 +278,5 @@ python run_buildstats () {
278} 278}
279 279
280addhandler run_buildstats 280addhandler run_buildstats
281run_buildstats[eventmask] = "bb.event.BuildStarted bb.event.BuildCompleted bb.build.TaskStarted bb.build.TaskSucceeded bb.build.TaskFailed"
281 282
diff --git a/meta/classes/cross.bbclass b/meta/classes/cross.bbclass
index eaba4d113c..54584fea52 100644
--- a/meta/classes/cross.bbclass
+++ b/meta/classes/cross.bbclass
@@ -58,9 +58,6 @@ do_populate_sysroot[sstate-inputdirs] = "${SYSROOT_DESTDIR}/${STAGING_DIR_NATIVE
58do_populate_sysroot[stamp-extra-info] = "" 58do_populate_sysroot[stamp-extra-info] = ""
59 59
60python cross_virtclass_handler () { 60python cross_virtclass_handler () {
61 if not isinstance(e, bb.event.RecipePreFinalise):
62 return
63
64 classextend = e.data.getVar('BBCLASSEXTEND', True) or "" 61 classextend = e.data.getVar('BBCLASSEXTEND', True) or ""
65 if "cross" not in classextend: 62 if "cross" not in classextend:
66 return 63 return
@@ -73,6 +70,7 @@ python cross_virtclass_handler () {
73} 70}
74 71
75addhandler cross_virtclass_handler 72addhandler cross_virtclass_handler
73cross_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise"
76 74
77do_install () { 75do_install () {
78 oe_runmake 'DESTDIR=${D}' install 76 oe_runmake 'DESTDIR=${D}' install
diff --git a/meta/classes/distrodata.bbclass b/meta/classes/distrodata.bbclass
index cedacc214c..3ff62684aa 100644
--- a/meta/classes/distrodata.bbclass
+++ b/meta/classes/distrodata.bbclass
@@ -1,15 +1,14 @@
1include conf/distro/include/package_regex.inc 1include conf/distro/include/package_regex.inc
2addhandler distro_eventhandler 2addhandler distro_eventhandler
3distro_eventhandler[eventmask] = "bb.event.BuildStarted"
3python distro_eventhandler() { 4python distro_eventhandler() {
4 5 import oe.distro_check as dc
5 if bb.event.getName(e) == "BuildStarted": 6 logfile = dc.create_log_file(e.data, "distrodata.csv")
6 import oe.distro_check as dc 7 lf = bb.utils.lockfile("%s.lock" % logfile)
7 logfile = dc.create_log_file(e.data, "distrodata.csv") 8 f = open(logfile, "a")
8 lf = bb.utils.lockfile("%s.lock" % logfile) 9 f.write("Package,Description,Owner,License,VerMatch,Version,Upsteam,Reason,Recipe Status,Distro 1,Distro 2,Distro 3\n")
9 f = open(logfile, "a") 10 f.close()
10 f.write("Package,Description,Owner,License,VerMatch,Version,Upsteam,Reason,Recipe Status,Distro 1,Distro 2,Distro 3\n") 11 bb.utils.unlockfile(lf)
11 f.close()
12 bb.utils.unlockfile(lf)
13 12
14 return 13 return
15} 14}
@@ -197,6 +196,7 @@ do_distrodataall() {
197} 196}
198 197
199addhandler checkpkg_eventhandler 198addhandler checkpkg_eventhandler
199 checkpkg_eventhandler[eventmask] = "bb.event.BuildStarted bb.event.BuildCompleted"
200python checkpkg_eventhandler() { 200python checkpkg_eventhandler() {
201 def parse_csv_file(filename): 201 def parse_csv_file(filename):
202 package_dict = {} 202 package_dict = {}
@@ -793,11 +793,11 @@ do_checkpkgall() {
793} 793}
794 794
795addhandler distro_check_eventhandler 795addhandler distro_check_eventhandler
796distro_check_eventhandler bb.event.BuildStarted
796python distro_check_eventhandler() { 797python distro_check_eventhandler() {
797 if bb.event.getName(e) == "BuildStarted": 798 """initialize log files."""
798 """initialize log files.""" 799 import oe.distro_check as dc
799 import oe.distro_check as dc 800 result_file = dc.create_log_file(e.data, "distrocheck.csv")
800 result_file = dc.create_log_file(e.data, "distrocheck.csv")
801 return 801 return
802} 802}
803 803
@@ -839,16 +839,16 @@ do_distro_checkall() {
839#then we can search those recipes which license text isn't exsit in common-licenses directory 839#then we can search those recipes which license text isn't exsit in common-licenses directory
840# 840#
841addhandler checklicense_eventhandler 841addhandler checklicense_eventhandler
842checklicense_eventhandler[eventmask] = "bb.event.BuildStarted"
842python checklicense_eventhandler() { 843python checklicense_eventhandler() {
843 if bb.event.getName(e) == "BuildStarted": 844 """initialize log files."""
844 """initialize log files.""" 845 import oe.distro_check as dc
845 import oe.distro_check as dc 846 logfile = dc.create_log_file(e.data, "missinglicense.csv")
846 logfile = dc.create_log_file(e.data, "missinglicense.csv") 847 lf = bb.utils.lockfile("%s.lock" % logfile)
847 lf = bb.utils.lockfile("%s.lock" % logfile) 848 f = open(logfile, "a")
848 f = open(logfile, "a") 849 f.write("Package\tLicense\tMissingLicense\n")
849 f.write("Package\tLicense\tMissingLicense\n") 850 f.close()
850 f.close() 851 bb.utils.unlockfile(lf)
851 bb.utils.unlockfile(lf)
852 return 852 return
853} 853}
854 854
diff --git a/meta/classes/migrate_localcount.bbclass b/meta/classes/migrate_localcount.bbclass
index 3916ad4461..aa0df8bb76 100644
--- a/meta/classes/migrate_localcount.bbclass
+++ b/meta/classes/migrate_localcount.bbclass
@@ -6,41 +6,41 @@ python migrate_localcount_handler () {
6 if not e.data: 6 if not e.data:
7 return 7 return
8 8
9 if isinstance(e, bb.event.RecipeParsed): 9 pv = e.data.getVar('PV', True)
10 pv = e.data.getVar('PV', True) 10 if not 'AUTOINC' in pv:
11 if not 'AUTOINC' in pv: 11 return
12 return 12
13 13 localcounts = bb.persist_data.persist('BB_URI_LOCALCOUNT', e.data)
14 localcounts = bb.persist_data.persist('BB_URI_LOCALCOUNT', e.data) 14 pn = e.data.getVar('PN', True)
15 pn = e.data.getVar('PN', True) 15 revs = localcounts.get_by_pattern('%%-%s_rev' % pn)
16 revs = localcounts.get_by_pattern('%%-%s_rev' % pn) 16 counts = localcounts.get_by_pattern('%%-%s_count' % pn)
17 counts = localcounts.get_by_pattern('%%-%s_count' % pn) 17 if not revs or not counts:
18 if not revs or not counts: 18 return
19 return
20
21 if len(revs) != len(counts):
22 bb.warn("The number of revs and localcounts don't match in %s" % pn)
23 return
24
25 version = e.data.getVar('PRAUTOINX', True)
26 srcrev = bb.fetch2.get_srcrev(e.data)
27 base_ver = 'AUTOINC-%s' % version[:version.find(srcrev)]
28 pkgarch = e.data.getVar('PACKAGE_ARCH', True)
29 value = max(int(count) for count in counts)
30
31 if len(revs) == 1:
32 if srcrev != ('AUTOINC+%s' % revs[0]):
33 value += 1
34 else:
35 value += 1
36 19
37 bb.utils.mkdirhier(e.data.getVar('PRSERV_DUMPDIR', True)) 20 if len(revs) != len(counts):
38 df = e.data.getVar('LOCALCOUNT_DUMPFILE', True) 21 bb.warn("The number of revs and localcounts don't match in %s" % pn)
39 flock = bb.utils.lockfile("%s.lock" % df) 22 return
40 with open(df, 'a') as fd: 23
41 fd.write('PRAUTO$%s$%s$%s = "%s"\n' % 24 version = e.data.getVar('PRAUTOINX', True)
42 (base_ver, pkgarch, srcrev, str(value))) 25 srcrev = bb.fetch2.get_srcrev(e.data)
43 bb.utils.unlockfile(flock) 26 base_ver = 'AUTOINC-%s' % version[:version.find(srcrev)]
27 pkgarch = e.data.getVar('PACKAGE_ARCH', True)
28 value = max(int(count) for count in counts)
29
30 if len(revs) == 1:
31 if srcrev != ('AUTOINC+%s' % revs[0]):
32 value += 1
33 else:
34 value += 1
35
36 bb.utils.mkdirhier(e.data.getVar('PRSERV_DUMPDIR', True))
37 df = e.data.getVar('LOCALCOUNT_DUMPFILE', True)
38 flock = bb.utils.lockfile("%s.lock" % df)
39 with open(df, 'a') as fd:
40 fd.write('PRAUTO$%s$%s$%s = "%s"\n' %
41 (base_ver, pkgarch, srcrev, str(value)))
42 bb.utils.unlockfile(flock)
44} 43}
45 44
46addhandler migrate_localcount_handler 45addhandler migrate_localcount_handler
46migrate_localcount_handler[eventmask] = "bb.event.RecipeParsed"
diff --git a/meta/classes/multilib.bbclass b/meta/classes/multilib.bbclass
index 9337f65a70..b04825f987 100644
--- a/meta/classes/multilib.bbclass
+++ b/meta/classes/multilib.bbclass
@@ -1,7 +1,4 @@
1python multilib_virtclass_handler () { 1python multilib_virtclass_handler () {
2 if not isinstance(e, bb.event.RecipePreFinalise):
3 return
4
5 cls = e.data.getVar("BBEXTENDCURR", True) 2 cls = e.data.getVar("BBEXTENDCURR", True)
6 variant = e.data.getVar("BBEXTENDVARIANT", True) 3 variant = e.data.getVar("BBEXTENDVARIANT", True)
7 if cls != "multilib" or not variant: 4 if cls != "multilib" or not variant:
@@ -60,6 +57,7 @@ python multilib_virtclass_handler () {
60} 57}
61 58
62addhandler multilib_virtclass_handler 59addhandler multilib_virtclass_handler
60multilib_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise"
63 61
64STAGINGCC_prepend = "${BBEXTENDVARIANT}-" 62STAGINGCC_prepend = "${BBEXTENDVARIANT}-"
65 63
diff --git a/meta/classes/multilib_global.bbclass b/meta/classes/multilib_global.bbclass
index 85f2d8d15d..3315ba9327 100644
--- a/meta/classes/multilib_global.bbclass
+++ b/meta/classes/multilib_global.bbclass
@@ -43,4 +43,5 @@ python multilib_virtclass_handler_global () {
43} 43}
44 44
45addhandler multilib_virtclass_handler_global 45addhandler multilib_virtclass_handler_global
46multilib_virtclass_handler_global[eventmask] = "bb.event.RecipePreFinalise bb.event.RecipeParsed"
46 47
diff --git a/meta/classes/native.bbclass b/meta/classes/native.bbclass
index cd930f0702..04f0d06ad9 100644
--- a/meta/classes/native.bbclass
+++ b/meta/classes/native.bbclass
@@ -104,9 +104,6 @@ CLASSOVERRIDE = "class-native"
104PATH_prepend = "${COREBASE}/scripts/native-intercept:" 104PATH_prepend = "${COREBASE}/scripts/native-intercept:"
105 105
106python native_virtclass_handler () { 106python native_virtclass_handler () {
107 if not isinstance(e, bb.event.RecipePreFinalise):
108 return
109
110 classextend = e.data.getVar('BBCLASSEXTEND', True) or "" 107 classextend = e.data.getVar('BBCLASSEXTEND', True) or ""
111 if "native" not in classextend: 108 if "native" not in classextend:
112 return 109 return
@@ -152,6 +149,7 @@ python native_virtclass_handler () {
152} 149}
153 150
154addhandler native_virtclass_handler 151addhandler native_virtclass_handler
152native_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise"
155 153
156do_package[noexec] = "1" 154do_package[noexec] = "1"
157do_packagedata[noexec] = "1" 155do_packagedata[noexec] = "1"
diff --git a/meta/classes/nativesdk.bbclass b/meta/classes/nativesdk.bbclass
index 8b689e760a..96e1b42a49 100644
--- a/meta/classes/nativesdk.bbclass
+++ b/meta/classes/nativesdk.bbclass
@@ -60,9 +60,6 @@ export PKG_CONFIG_DIR = "${STAGING_DIR_HOST}${libdir}/pkgconfig"
60export PKG_CONFIG_SYSROOT_DIR = "${STAGING_DIR_HOST}" 60export PKG_CONFIG_SYSROOT_DIR = "${STAGING_DIR_HOST}"
61 61
62python nativesdk_virtclass_handler () { 62python nativesdk_virtclass_handler () {
63 if not isinstance(e, bb.event.RecipePreFinalise):
64 return
65
66 pn = e.data.getVar("PN", True) 63 pn = e.data.getVar("PN", True)
67 if not pn.endswith("-nativesdk") or pn.startswith("nativesdk-"): 64 if not pn.endswith("-nativesdk") or pn.startswith("nativesdk-"):
68 return 65 return
@@ -89,5 +86,6 @@ python () {
89} 86}
90 87
91addhandler nativesdk_virtclass_handler 88addhandler nativesdk_virtclass_handler
89nativesdk_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise"
92 90
93do_populate_sysroot[stamp-extra-info] = "" 91do_populate_sysroot[stamp-extra-info] = ""
diff --git a/meta/classes/packageinfo.bbclass b/meta/classes/packageinfo.bbclass
index 4709bea359..42fcd04150 100644
--- a/meta/classes/packageinfo.bbclass
+++ b/meta/classes/packageinfo.bbclass
@@ -1,29 +1,29 @@
1python packageinfo_handler () { 1python packageinfo_handler () {
2 if isinstance(e, bb.event.RequestPackageInfo): 2 import oe.packagedata
3 import oe.packagedata 3 pkginfolist = []
4 pkginfolist = [] 4 tmpdir = e.data.getVar('TMPDIR', True)
5 tmpdir = e.data.getVar('TMPDIR', True) 5 target_vendor = e.data.getVar('TARGET_VENDOR', True)
6 target_vendor = e.data.getVar('TARGET_VENDOR', True) 6 target_os = e.data.getVar('TARGET_OS', True)
7 target_os = e.data.getVar('TARGET_OS', True) 7 package_archs = e.data.getVar('PACKAGE_ARCHS', True)
8 package_archs = e.data.getVar('PACKAGE_ARCHS', True) 8 packaging = e.data.getVar('PACKAGE_CLASSES', True).split()[0].split('_')[1]
9 packaging = e.data.getVar('PACKAGE_CLASSES', True).split()[0].split('_')[1] 9 deploy_dir = e.data.getVar('DEPLOY_DIR', True) + '/' + packaging
10 deploy_dir = e.data.getVar('DEPLOY_DIR', True) + '/' + packaging 10
11 11 for arch in package_archs.split():
12 for arch in package_archs.split(): 12 pkgdata_dir = tmpdir + '/pkgdata/' + arch + target_vendor + '-' + target_os + '/runtime/'
13 pkgdata_dir = tmpdir + '/pkgdata/' + arch + target_vendor + '-' + target_os + '/runtime/' 13 if os.path.exists(pkgdata_dir):
14 if os.path.exists(pkgdata_dir): 14 for root, dirs, files in os.walk(pkgdata_dir):
15 for root, dirs, files in os.walk(pkgdata_dir): 15 for pkgname in files:
16 for pkgname in files: 16 if pkgname.endswith('.packaged'):
17 if pkgname.endswith('.packaged'): 17 pkgname = pkgname[:-9]
18 pkgname = pkgname[:-9] 18 pkgdatafile = root + pkgname
19 pkgdatafile = root + pkgname 19 try:
20 try: 20 sdata = oe.packagedata.read_pkgdatafile(pkgdatafile)
21 sdata = oe.packagedata.read_pkgdatafile(pkgdatafile) 21 sdata['PKG'] = pkgname
22 sdata['PKG'] = pkgname 22 pkginfolist.append(sdata)
23 pkginfolist.append(sdata) 23 except Exception as e:
24 except Exception as e: 24 bb.warn("Failed to read pkgdata file %s: %s: %s" % (pkgdatafile, e.__class__, str(e)))
25 bb.warn("Failed to read pkgdata file %s: %s: %s" % (pkgdatafile, e.__class__, str(e))) 25 bb.event.fire(bb.event.PackageInfo(pkginfolist), e.data)
26 bb.event.fire(bb.event.PackageInfo(pkginfolist), e.data)
27} 26}
28 27
29addhandler packageinfo_handler 28addhandler packageinfo_handler
29packageinfo_handler[eventmask] = "bb.event.RequestPackageInfo"
diff --git a/meta/classes/prexport.bbclass b/meta/classes/prexport.bbclass
index 6b9d540989..16c4bf2f23 100644
--- a/meta/classes/prexport.bbclass
+++ b/meta/classes/prexport.bbclass
@@ -55,3 +55,4 @@ python prexport_handler () {
55} 55}
56 56
57addhandler prexport_handler 57addhandler prexport_handler
58prexport_handler bb.event.RecipeParsed bb.event.ParseStarted bb.event.ParseCompleted"
diff --git a/meta/classes/primport.bbclass b/meta/classes/primport.bbclass
index 37b0d6b1b7..8ed45f03f0 100644
--- a/meta/classes/primport.bbclass
+++ b/meta/classes/primport.bbclass
@@ -18,3 +18,4 @@ python primport_handler () {
18} 18}
19 19
20addhandler primport_handler 20addhandler primport_handler
21primport_handler[eventmask] = "bb.event.ParseCompleted bb.event.ParseStarted"
diff --git a/meta/classes/recipe_sanity.bbclass b/meta/classes/recipe_sanity.bbclass
index bf378eafc1..8b3a1c9571 100644
--- a/meta/classes/recipe_sanity.bbclass
+++ b/meta/classes/recipe_sanity.bbclass
@@ -140,9 +140,6 @@ do_recipe_sanity_all () {
140addtask recipe_sanity_all after do_recipe_sanity 140addtask recipe_sanity_all after do_recipe_sanity
141 141
142python recipe_sanity_eh () { 142python recipe_sanity_eh () {
143 if bb.event.getName(e) != "ConfigParsed":
144 return
145
146 d = e.data 143 d = e.data
147 144
148 cfgdata = {} 145 cfgdata = {}
@@ -168,3 +165,4 @@ python recipe_sanity_eh () {
168 DataSmart.renameVar = myrename 165 DataSmart.renameVar = myrename
169} 166}
170addhandler recipe_sanity_eh 167addhandler recipe_sanity_eh
168recipe_sanity_eh[eventmask] = "bb.event.ConfigParsed"
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index e692f33839..3b9934b488 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -672,6 +672,7 @@ def copy_data(e):
672 return sanity_data 672 return sanity_data
673 673
674addhandler check_sanity_eventhandler 674addhandler check_sanity_eventhandler
675check_sanity_eventhandler[eventmask] = "bb.event.ConfigParsed bb.event.SanityCheck bb.event.NetworkTest"
675python check_sanity_eventhandler() { 676python check_sanity_eventhandler() {
676 if bb.event.getName(e) == "ConfigParsed" and e.data.getVar("BB_WORKERCONTEXT", True) != "1" and e.data.getVar("DISABLE_SANITY_CHECKS", True) != "1": 677 if bb.event.getName(e) == "ConfigParsed" and e.data.getVar("BB_WORKERCONTEXT", True) != "1" and e.data.getVar("DISABLE_SANITY_CHECKS", True) != "1":
677 sanity_data = copy_data(e) 678 sanity_data = copy_data(e)
diff --git a/meta/classes/typecheck.bbclass b/meta/classes/typecheck.bbclass
index 353532d73c..72da932232 100644
--- a/meta/classes/typecheck.bbclass
+++ b/meta/classes/typecheck.bbclass
@@ -4,9 +4,9 @@
4 4
5python check_types() { 5python check_types() {
6 import oe.types 6 import oe.types
7 if isinstance(e, bb.event.ConfigParsed): 7 for key in e.data.keys():
8 for key in e.data.keys(): 8 if e.data.getVarFlag(key, "type"):
9 if e.data.getVarFlag(key, "type"): 9 oe.data.typed_value(key, e.data)
10 oe.data.typed_value(key, e.data)
11} 10}
12addhandler check_types 11addhandler check_types
12check_types[eventmask] = "bb.event.ConfigParsed"
diff --git a/meta/conf/distro/include/csl-versions.inc b/meta/conf/distro/include/csl-versions.inc
index e8f52d272d..f3b491cb16 100644
--- a/meta/conf/distro/include/csl-versions.inc
+++ b/meta/conf/distro/include/csl-versions.inc
@@ -88,8 +88,6 @@ def csl_get_gdb_version(d):
88 return first_line.split()[-1] 88 return first_line.split()[-1]
89 89
90python csl_version_handler () { 90python csl_version_handler () {
91 if not isinstance(e, bb.event.ConfigParsed):
92 return
93 d = e.data 91 d = e.data
94 ld = d.createCopy() 92 ld = d.createCopy()
95 ld.finalize() 93 ld.finalize()
@@ -101,6 +99,7 @@ python csl_version_handler () {
101 d.setVar('CSL_VER_GDB', csl_get_gdb_version(ld)) 99 d.setVar('CSL_VER_GDB', csl_get_gdb_version(ld))
102} 100}
103addhandler csl_version_handler 101addhandler csl_version_handler
102csl_version_handler[eventmask] = "bb.event.ConfigParsed"
104 103
105# Ensure that any variable which includes the --sysroot (CC, CXX, etc) also 104# Ensure that any variable which includes the --sysroot (CC, CXX, etc) also
106# depends on the toolchain version 105# depends on the toolchain version
diff --git a/meta/conf/distro/include/tcmode-external-sourcery.inc b/meta/conf/distro/include/tcmode-external-sourcery.inc
index 098c724e02..53e6653e79 100644
--- a/meta/conf/distro/include/tcmode-external-sourcery.inc
+++ b/meta/conf/distro/include/tcmode-external-sourcery.inc
@@ -79,9 +79,6 @@ EXTERNAL_TOOLCHAIN_SYSROOT_CMD += "${@csl_multilib_arg(d)}"
79# to our staging toolchain bindir. 79# to our staging toolchain bindir.
80 80
81python toolchain_metadata_setup () { 81python toolchain_metadata_setup () {
82 if not isinstance(e, bb.event.ConfigParsed):
83 return
84
85 d = e.data 82 d = e.data
86 83
87 l = d.createCopy() 84 l = d.createCopy()
@@ -90,17 +87,16 @@ python toolchain_metadata_setup () {
90 d.setVar('TOOLCHAIN_PATH_ADD', '') 87 d.setVar('TOOLCHAIN_PATH_ADD', '')
91} 88}
92addhandler toolchain_metadata_setup 89addhandler toolchain_metadata_setup
90toolchain_metadata_setup[eventmask] = "bb.event.ConfigParsed"
93 91
94python toolchain_setup () { 92python toolchain_setup () {
95 if not isinstance(e, bb.event.BuildStarted):
96 return
97
98 d = e.data 93 d = e.data
99 94
100 if not d.getVar('TOOLCHAIN_PATH_ADD', True): 95 if not d.getVar('TOOLCHAIN_PATH_ADD', True):
101 populate_toolchain_links(d) 96 populate_toolchain_links(d)
102} 97}
103addhandler toolchain_setup 98addhandler toolchain_setup
99toolchain_setup[eventmask] = "bb.event.BuildStarted"
104 100
105def populate_toolchain_links(d): 101def populate_toolchain_links(d):
106 import errno 102 import errno