diff options
author | Ross Burton <ross@openedhand.com> | 2007-11-14 09:36:55 +0000 |
---|---|---|
committer | Ross Burton <ross@openedhand.com> | 2007-11-14 09:36:55 +0000 |
commit | ab2a04d8434ef5f0acbe2e7ea89ad8c1ed291264 (patch) | |
tree | 143f6492a6ab02e3402cd05f392dbe7c40fe6fdf | |
parent | 9e0b8d9bdb8828d9182bdf47e68415918688eb4d (diff) | |
download | poky-ab2a04d8434ef5f0acbe2e7ea89ad8c1ed291264.tar.gz |
insane.bbclass: validate desktop files
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@3151 311d38ba-8fff-0310-9ca6-ca027cbcb966
-rw-r--r-- | meta/classes/insane.bbclass | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass index 613d0e57a8..7b7175232d 100644 --- a/meta/classes/insane.bbclass +++ b/meta/classes/insane.bbclass | |||
@@ -21,7 +21,7 @@ | |||
21 | 21 | ||
22 | # We play a special package function | 22 | # We play a special package function |
23 | inherit package | 23 | inherit package |
24 | PACKAGE_DEPENDS += "pax-utils-native" | 24 | PACKAGE_DEPENDS += "pax-utils-native desktop-file-utils-native" |
25 | #PACKAGE_DEPENDS += chrpath-native" | 25 | #PACKAGE_DEPENDS += chrpath-native" |
26 | PACKAGEFUNCS += " do_package_qa " | 26 | PACKAGEFUNCS += " do_package_qa " |
27 | 27 | ||
@@ -308,8 +308,19 @@ def package_qa_check_pcla(path,name,d): | |||
308 | .pc and .la files should not point to the WORKDIR | 308 | .pc and .la files should not point to the WORKDIR |
309 | """ | 309 | """ |
310 | sane = True | 310 | sane = True |
311 | # TODO | ||
311 | return sane | 312 | return sane |
312 | 313 | ||
314 | def package_qa_check_desktop(path, name, d): | ||
315 | """ | ||
316 | Run all desktop files through desktop-file-validate. | ||
317 | """ | ||
318 | import bb, os | ||
319 | if path.endswith(".desktop"): | ||
320 | validate = os.path.join(bb.data.getVar('STAGING_BINDIR_NATIVE',d,True), 'desktop-file-validate') | ||
321 | os.system ("%s %s" % (validate, path)) | ||
322 | return True | ||
323 | |||
313 | def package_qa_check_staged(path,d): | 324 | def package_qa_check_staged(path,d): |
314 | """ | 325 | """ |
315 | Check staged la and pc files for sanity | 326 | Check staged la and pc files for sanity |
@@ -422,7 +433,7 @@ python do_package_qa () { | |||
422 | 433 | ||
423 | bb.note("Checking Package: %s" % package) | 434 | bb.note("Checking Package: %s" % package) |
424 | path = "%s/install/%s" % (workdir, package) | 435 | path = "%s/install/%s" % (workdir, package) |
425 | if not package_qa_walk(path, [package_qa_check_rpath, package_qa_check_devdbg, package_qa_check_perm, package_qa_check_arch], package, d): | 436 | 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): |
426 | walk_sane = False | 437 | walk_sane = False |
427 | if not package_qa_check_rdepends(package, workdir, d): | 438 | if not package_qa_check_rdepends(package, workdir, d): |
428 | rdepends_sane = False | 439 | rdepends_sane = False |