[CONSOLIDATED,PULL,(v2),19/33] shared-mime-info: package runtime data separately

Submitted by Saul Wold on Nov. 10, 2011, 7:43 a.m.

Details

Message ID d6691d239a3e12eda77cb91bb784d1ca6af9bc85.1320910946.git.sgw@linux.intel.com
State New
Headers show

Commit Message

Saul Wold Nov. 10, 2011, 7:43 a.m.
From: Joshua Lock <josh@linux.intel.com>

The freedesktop.org.xml is required when updating the mime database but
otherwise not much use. Therefore package it separately, rather than
removing it completely, so that it can be used as required for on-device
updates without adding almost 2MB to every image which hase shared-mime-info.

Signed-off-by: Joshua Lock <josh@linux.intel.com>
---
 .../shared-mime-info/shared-mime-info.inc          |    9 ++++++---
 .../shared-mime-info/shared-mime-info_0.91.bb      |    2 +-
 2 files changed, 7 insertions(+), 4 deletions(-)

Patch hide | download patch | download mbox

diff --git a/meta/recipes-support/shared-mime-info/shared-mime-info.inc b/meta/recipes-support/shared-mime-info/shared-mime-info.inc
index c8cab29..57e829c 100644
--- a/meta/recipes-support/shared-mime-info/shared-mime-info.inc
+++ b/meta/recipes-support/shared-mime-info/shared-mime-info.inc
@@ -17,13 +17,16 @@  EXTRA_OECONF = "--disable-update-mimedb"
 FILES_${PN} += "${datadir}/mime"
 FILES_${PN}-dev += "${datadir}/pkgconfig/shared-mime-info.pc"
 
+# freedesktop.org.xml is only required when updating the mime database,
+# package it separately
+PACKAGES += "shared-mime-info-data"
+FILES_shared-mime-info-data = "${datadir}/mime/packages/freedesktop.org.xml"
+RDEPENDS_shared-mime-info-data = "shared-mime-info"
+
 do_install () {
 	autotools_do_install
 
 	update-mime-database ${D}${datadir}/mime
-
-	# we do not need it on device and it is huge
-	rm ${D}${datadir}/mime/packages/freedesktop.org.xml
 }
 
 do_install_virtclass-native () {
diff --git a/meta/recipes-support/shared-mime-info/shared-mime-info_0.91.bb b/meta/recipes-support/shared-mime-info/shared-mime-info_0.91.bb
index 0c3b01c..bc4a8f7 100644
--- a/meta/recipes-support/shared-mime-info/shared-mime-info_0.91.bb
+++ b/meta/recipes-support/shared-mime-info/shared-mime-info_0.91.bb
@@ -1,5 +1,5 @@ 
 require shared-mime-info.inc
-PR = "r1"
+PR = "r2"
 
 SRC_URI[md5sum] = "982a211560ba4c47dc791ccff34e8fbc"
 SRC_URI[sha256sum] = "98cfebe1d809afb24934e634373821e2a1dfa86fc6462cab230589a1c80988bd"