summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJamie Lenehan <lenehan@twibble.org>2006-09-10 04:21:58 +0000
committerJamie Lenehan <lenehan@twibble.org>2006-09-10 04:21:58 +0000
commit1631f5f16233e4a234f4629ab06d2462b1132b3f (patch)
tree29fe12330326c85144e61b6c9240e01248d53c1d
parentb123d379836c1d5d5a55a6e7bcdf5becf4d8a2cf (diff)
gawk 3.1.4: Use the update-alternatives class rather than manually
performing the update-alternatives actions.
-rw-r--r--packages/gawk/gawk_3.1.4.bb12
1 files changed, 5 insertions, 7 deletions
diff --git a/packages/gawk/gawk_3.1.4.bb b/packages/gawk/gawk_3.1.4.bb
index 9594127b08..5af890eec8 100644
--- a/packages/gawk/gawk_3.1.4.bb
+++ b/packages/gawk/gawk_3.1.4.bb
@@ -8,7 +8,7 @@ PR = "r3"
SRC_URI = "${GNU_MIRROR}/gawk/gawk-${PV}.tar.gz"
-inherit autotools
+inherit autotools update-alternatives
do_configure_prepend () {
grep -E '^AC_DEFUN' m4/*.m4|grep -E '\(\[?(AM|AC)_'|xargs rm -f
@@ -21,9 +21,7 @@ FILES_gawk-common += "${datadir}/awk/* ${libexecdir}/awk/*"
FILES_pgawk = "${bindir}/pgawk*"
FILES_${PN}-dbg += "${libexecdir}/awk/.debug"
-pkg_postinst_${PN} () {
- update-alternatives --install ${bindir}/awk awk gawk 100
-}
-pkg_prerm_${PN} () {
- update-alternatives --remove awk gawk
-}
+ALTERNATIVE_NAME = "awk"
+ALTERNATIVE_PATH = "gawk"
+ALTERNATIVE_LINK = "${bindir}/awk"
+ALTERNATIVE_PRIORITY = "100"