[oe-commits] Martyn Welch : mktemp_1.6.bb: use update-alternatives

git version control git at git.openembedded.org
Sun Mar 28 17:27:18 UTC 2010


Module: openembedded.git
Branch: shr/unstable
Commit: 1715eb524b26f109b22c3c05b248575e7df562a1
URL:    http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=1715eb524b26f109b22c3c05b248575e7df562a1

Author: Martyn Welch <martyn.welch at ge.com>
Date:   Mon Mar 15 03:35:08 2010 +0000

 mktemp_1.6.bb: use update-alternatives

* As suggested in the original version, this patch makes mktemp use
  update-alternatives.

Signed-off-by: Martyn Welch <martyn.welch at ge.com>
Signed-off-by: Khem Raj <raj.khem at gmail.com>

---

 recipes/mktemp/mktemp_1.6.bb |   15 +++++++++++----
 1 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/recipes/mktemp/mktemp_1.6.bb b/recipes/mktemp/mktemp_1.6.bb
index bd9c4ca..33c1cf1 100644
--- a/recipes/mktemp/mktemp_1.6.bb
+++ b/recipes/mktemp/mktemp_1.6.bb
@@ -3,7 +3,7 @@ HOMEPAGE = "http://www.mktemp.org/"
 SECTION = "console/utils"
 LICENSE = "GPLv2 BSD"
 
-inherit autotools
+inherit autotools update-alternatives
 
 EXTRA_OECONF = "--with-libc"
 
@@ -12,6 +12,13 @@ SRC_URI = "\
   file://add_destdir.patch;patch=1 \
   file://disable-strip.patch;patch=1 \
 "
-	 	 	
-# FIXME should rather use update-alternatives
-RCONFLICTS_${PN} = "coreutils"
+
+do_install_append () {
+	mkdir ${D}${base_bindir}
+	mv ${D}${bindir}/mktemp ${D}${base_bindir}/mktemp.${PN}
+}
+
+ALTERNATIVE_NAME = "mktemp"
+ALTERNATIVE_LINK = "${base_bindir}/mktemp"
+ALTERNATIVE_PATH = "${base_bindir}/mktemp.${PN}"
+ALTERNATIVE_PRIORITY = "100"





More information about the Openembedded-commits mailing list