summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb
diff options
context:
space:
mode:
authorAndré Draszik <adraszik@tycoint.com>2016-11-10 10:46:19 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-11-23 11:10:13 +0000
commit5deddc8767878dedf6020788dcb8d6158ea91b57 (patch)
treedc0f47313aca46f1d7fd09477b0af5f053bb5ed8 /meta/recipes-devtools/opkg-utils/opkg-utils_git.bb
parent39fba4d70f502080cc23556db757db56f06250cf (diff)
downloadpoky-5deddc8767878dedf6020788dcb8d6158ea91b57.tar.gz
opkg-utils: clear update-alternatives database on uninstall
When uninstalling update-alternatives, it doesn't seem to make much sense to keep the update-alternatives database around. In particular when removing packaging data, e.g. due to read-only rootfs, update-alternatives is removed from the target file system. Leaving its database around serves no purpose in that case as there is no way to use it afterwards anyway. This frees close to 700KB of (uncompressed) space in a busybox based environment. (From OE-Core rev: b24a63d71b517af701dfedbc7f7b541d25af708f) Signed-off-by: André Draszik <adraszik@tycoint.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/opkg-utils/opkg-utils_git.bb')
-rw-r--r--meta/recipes-devtools/opkg-utils/opkg-utils_git.bb5
1 files changed, 5 insertions, 0 deletions
diff --git a/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb b/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb
index a7aec45f8d..19a852ec62 100644
--- a/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb
+++ b/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb
@@ -43,4 +43,9 @@ RPROVIDES_update-alternatives-opkg = "update-alternatives update-alternatives-cw
43RREPLACES_update-alternatives-opkg = "update-alternatives-cworth" 43RREPLACES_update-alternatives-opkg = "update-alternatives-cworth"
44RCONFLICTS_update-alternatives-opkg = "update-alternatives-cworth" 44RCONFLICTS_update-alternatives-opkg = "update-alternatives-cworth"
45 45
46pkg_postrm_update-alternatives-opkg() {
47 rm -rf $OPKG_OFFLINE_ROOT${nonarch_libdir}/opkg/alternatives
48 rmdir --ignore-fail-on-non-empty $OPKG_OFFLINE_ROOT${nonarch_libdir}/opkg
49}
50
46BBCLASSEXTEND = "native nativesdk" 51BBCLASSEXTEND = "native nativesdk"