diff options
-rw-r--r-- | meta/classes/insane.bbclass | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass index c8fa7116b3..9ffe6751d8 100644 --- a/meta/classes/insane.bbclass +++ b/meta/classes/insane.bbclass | |||
@@ -17,9 +17,6 @@ | |||
17 | # files under exec_prefix | 17 | # files under exec_prefix |
18 | 18 | ||
19 | 19 | ||
20 | PACKAGE_DEPENDS += "${QADEPENDS}" | ||
21 | PACKAGEFUNCS += " do_package_qa " | ||
22 | |||
23 | # unsafe-references-in-binaries requires prelink-rtld from | 20 | # unsafe-references-in-binaries requires prelink-rtld from |
24 | # prelink-native, but we don't want this DEPENDS for -native builds | 21 | # prelink-native, but we don't want this DEPENDS for -native builds |
25 | QADEPENDS = "prelink-native" | 22 | QADEPENDS = "prelink-native" |
@@ -828,6 +825,8 @@ python do_package_qa () { | |||
828 | 825 | ||
829 | bb.note("DO PACKAGE QA") | 826 | bb.note("DO PACKAGE QA") |
830 | 827 | ||
828 | bb.build.exec_func("read_subpackage_metadata", d) | ||
829 | |||
831 | logdir = d.getVar('T', True) | 830 | logdir = d.getVar('T', True) |
832 | pkg = d.getVar('PN', True) | 831 | pkg = d.getVar('PN', True) |
833 | 832 | ||
@@ -855,6 +854,15 @@ python do_package_qa () { | |||
855 | pkgdest = d.getVar('PKGDEST', True) | 854 | pkgdest = d.getVar('PKGDEST', True) |
856 | packages = d.getVar('PACKAGES', True) | 855 | packages = d.getVar('PACKAGES', True) |
857 | 856 | ||
857 | cpath = oe.cachedpath.CachedPath() | ||
858 | global pkgfiles | ||
859 | pkgfiles = {} | ||
860 | for pkg in (packages or "").split(): | ||
861 | pkgfiles[pkg] = [] | ||
862 | for walkroot, dirs, files in cpath.walk(pkgdest + "/" + pkg): | ||
863 | for file in files: | ||
864 | pkgfiles[pkg].append(walkroot + os.sep + file) | ||
865 | |||
858 | # no packages should be scanned | 866 | # no packages should be scanned |
859 | if not packages: | 867 | if not packages: |
860 | return | 868 | return |
@@ -909,6 +917,15 @@ python do_package_qa () { | |||
909 | bb.note("DONE with PACKAGE QA") | 917 | bb.note("DONE with PACKAGE QA") |
910 | } | 918 | } |
911 | 919 | ||
920 | addtask do_package_qa after do_package before do_build | ||
921 | |||
922 | SSTATETASKS += "do_package_qa" | ||
923 | do_package_qa[sstate-inputdirs] = "" | ||
924 | do_package_qa[sstate-outputdirs] = "" | ||
925 | python do_package_qa_setscene () { | ||
926 | sstate_setscene(d) | ||
927 | } | ||
928 | addtask do_package_qa_setscene | ||
912 | 929 | ||
913 | python do_qa_staging() { | 930 | python do_qa_staging() { |
914 | bb.note("QA checking staging") | 931 | bb.note("QA checking staging") |
@@ -1018,6 +1035,8 @@ python () { | |||
1018 | 1035 | ||
1019 | issues = [] | 1036 | issues = [] |
1020 | if (d.getVar('PACKAGES', True) or "").split(): | 1037 | if (d.getVar('PACKAGES', True) or "").split(): |
1038 | for dep in (d.getVar('QADEPENDS', True) or "").split(): | ||
1039 | d.appendVarFlag('do_package_qa', 'depends', " %s:do_populate_sysroot" % dep) | ||
1021 | for var in 'RDEPENDS', 'RRECOMMENDS', 'RSUGGESTS', 'RCONFLICTS', 'RPROVIDES', 'RREPLACES', 'FILES', 'pkg_preinst', 'pkg_postinst', 'pkg_prerm', 'pkg_postrm', 'ALLOW_EMPTY': | 1040 | for var in 'RDEPENDS', 'RRECOMMENDS', 'RSUGGESTS', 'RCONFLICTS', 'RPROVIDES', 'RREPLACES', 'FILES', 'pkg_preinst', 'pkg_postinst', 'pkg_prerm', 'pkg_postrm', 'ALLOW_EMPTY': |
1022 | if d.getVar(var): | 1041 | if d.getVar(var): |
1023 | issues.append(var) | 1042 | issues.append(var) |