summaryrefslogtreecommitdiff
path: root/classes/insane.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'classes/insane.bbclass')
-rw-r--r--classes/insane.bbclass28
1 files changed, 25 insertions, 3 deletions
diff --git a/classes/insane.bbclass b/classes/insane.bbclass
index 3fb2d04a81..473fe6ebbf 100644
--- a/classes/insane.bbclass
+++ b/classes/insane.bbclass
@@ -21,7 +21,7 @@
# We play a special package function
inherit package
-PACKAGE_DEPENDS += "pax-utils-native"
+PACKAGE_DEPENDS += "pax-utils-native desktop-file-utils-native"
#PACKAGE_DEPENDS += chrpath-native"
PACKAGEFUNCS += " do_package_qa "
@@ -57,8 +57,12 @@ def package_qa_get_machine_dict():
"arm" : ( 40, 97, 0, True, True),
"armeb": ( 40, 97, 0, False, True),
"powerpc": ( 20, 0, 0, False, True),
+ "i386": ( 3, 0, 0, True, True),
+ "i486": ( 3, 0, 0, True, True),
+ "i586": ( 3, 0, 0, True, True),
+ "i686": ( 3, 0, 0, True, True),
"mipsel": ( 8, 0, 0, True, True),
- "avr32": (6317, 0, 0, False, True),
+ "avr32": (6317, 0, 0, False, True),
},
"uclinux-uclibc" : {
"bfin": ( 106, 0, 0, True, True),
@@ -308,8 +312,22 @@ def package_qa_check_pcla(path,name,d):
.pc and .la files should not point to the WORKDIR
"""
sane = True
+ # TODO
return sane
+def package_qa_check_desktop(path, name, d):
+ """
+ Run all desktop files through desktop-file-validate.
+ """
+ import bb, os
+ if path.endswith(".desktop"):
+ validate = os.path.join(bb.data.getVar('STAGING_BINDIR_NATIVE',d,True), 'desktop-file-validate')
+ output = os.popen("%s %s" % (validate, path))
+ # This only produces output on errors
+ for l in output:
+ bb.error(l.strip())
+ return True
+
def package_qa_check_staged(path,d):
"""
Check staged la and pc files for sanity
@@ -416,9 +434,13 @@ python do_package_qa () {
walk_sane = True
rdepends_sane = True
for package in packages.split():
+ if bb.data.getVar('INSANE_SKIP_' + package, d, True):
+ bb.note("Package: %s (skipped)" % package)
+ continue
+
bb.note("Checking Package: %s" % package)
path = "%s/install/%s" % (workdir, package)
- if not package_qa_walk(path, [package_qa_check_rpath, package_qa_check_devdbg, package_qa_check_perm, package_qa_check_arch], package, d):
+ if not package_qa_walk(path, [package_qa_check_rpath, package_qa_check_devdbg, package_qa_check_perm, package_qa_check_arch, package_qa_check_desktop], package, d):
walk_sane = False
if not package_qa_check_rdepends(package, workdir, d):
rdepends_sane = False