From 8903327ff483cd3dbde8cf692be2092462265188 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Wed, 21 Mar 2012 14:29:49 +0000 Subject: pigz: Add update-alternatives support since this otherwise conflicts with busybox/gzip Signed-off-by: Richard Purdie --- meta/recipes-extended/pigz/pigz.inc | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) (limited to 'meta/recipes-extended/pigz/pigz.inc') diff --git a/meta/recipes-extended/pigz/pigz.inc b/meta/recipes-extended/pigz/pigz.inc index 5fda8cabfb..e1cbc8be80 100644 --- a/meta/recipes-extended/pigz/pigz.inc +++ b/meta/recipes-extended/pigz/pigz.inc @@ -15,7 +15,18 @@ PROVIDES_virtclass-native += "gzip-native" DEPENDS = "zlib" do_install () { - install -d ${D}${bindir} - install ${B}/pigz ${D}${bindir}/gzip - install ${B}/unpigz ${D}${bindir}/gunzip + if [ "${PN}" = "${BPN}" ] ; then + # Install files into /bin (FHS), which is typical place for gzip + install -d ${D}${base_bindir} + install ${B}/pigz ${D}${base_bindir}/gzip + install ${B}/unpigz ${D}${base_bindir}/gunzip + else + install -d ${D}${bindir} + install ${B}/pigz ${D}${bindir}/gzip + install ${B}/unpigz ${D}${bindir}/gunzip + fi } + +ALTERNATIVE_LINKS = "${base_bindir}/gzip ${base_bindir}/gunzip" +ALTERNATIVE_PRIORITY = "80" + -- cgit 1.2.3-korg