From: Jamie Lenehan Date: Tue, 24 Oct 2006 00:01:10 +0000 (+0000) Subject: findutils 4.1.20: Use alternatives for find and xargs since these commands X-Git-Tag: Release-2010-05/1~9453^2~567^2~19 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ba0c83a289da26a48f1b08fd69b7d8ef501b224a;p=openembedded.git findutils 4.1.20: Use alternatives for find and xargs since these commands are also provided by busybox. Closes #1472. --- diff --git a/packages/findutils/findutils_4.1.20.bb b/packages/findutils/findutils_4.1.20.bb index e633b6d405..0ea93f44d3 100644 --- a/packages/findutils/findutils_4.1.20.bb +++ b/packages/findutils/findutils_4.1.20.bb @@ -1,7 +1,7 @@ SECTION = "console/utils" LICENSE = "GPL" DESCRIPTION = "find, locate, and xargs binaries." -PR = "r2" +PR = "r3" SRC_URI = "ftp://alpha.gnu.org/gnu/findutils/findutils-${PV}.tar.gz \ file://configure.patch;patch=1 \ @@ -15,3 +15,16 @@ inherit autotools gettext # because it uses __mempcpy, there are other things (TBD: # see diffutils.mk in buildroot) EXTRA_OECONF_linux-uclibc = "--without-included-regex" + +do_install_append () { + mv ${D}${bindir}/find ${D}${bindir}/find.${PN} + mv ${D}${bindir}/xargs ${D}${bindir}/xargs.${PN} +} + +pkg_postinst_${PN} () { + for i in find xargs; do update-alternatives --install ${bindir}/$i $i $i.${PN} 100; done +} + +pkg_prerm_${PN} () { + for i in find xargs; do update-alternatives --remove $i $i.${PN}; done +}