diff options
| -rw-r--r-- | meta/recipes-extended/grep/grep_2.5.1a.bb | 23 | ||||
| -rw-r--r-- | meta/recipes-extended/grep/grep_2.9.bb | 26 |
2 files changed, 22 insertions, 27 deletions
diff --git a/meta/recipes-extended/grep/grep_2.5.1a.bb b/meta/recipes-extended/grep/grep_2.5.1a.bb index 5aecf17cf0..3a8bcbfdb7 100644 --- a/meta/recipes-extended/grep/grep_2.5.1a.bb +++ b/meta/recipes-extended/grep/grep_2.5.1a.bb | |||
| @@ -27,20 +27,17 @@ do_configure_prepend () { | |||
| 27 | do_install () { | 27 | do_install () { |
| 28 | autotools_do_install | 28 | autotools_do_install |
| 29 | install -d ${D}${base_bindir} | 29 | install -d ${D}${base_bindir} |
| 30 | mv ${D}${bindir}/grep ${D}${base_bindir}/grep.${PN} | 30 | mv ${D}${bindir}/grep ${D}${base_bindir}/grep |
| 31 | mv ${D}${bindir}/egrep ${D}${base_bindir}/egrep.${PN} | 31 | mv ${D}${bindir}/egrep ${D}${base_bindir}/egrep |
| 32 | mv ${D}${bindir}/fgrep ${D}${base_bindir}/fgrep.${PN} | 32 | mv ${D}${bindir}/fgrep ${D}${base_bindir}/fgrep |
| 33 | rmdir ${D}${bindir}/ | 33 | rmdir ${D}${bindir}/ |
| 34 | } | 34 | } |
| 35 | 35 | ||
| 36 | pkg_postinst_${PN} () { | 36 | inherit update-alternatives |
| 37 | update-alternatives --install ${base_bindir}/grep grep grep.${PN} 100 | ||
| 38 | update-alternatives --install ${base_bindir}/egrep egrep egrep.${PN} 100 | ||
| 39 | update-alternatives --install ${base_bindir}/fgrep fgrep fgrep.${PN} 100 | ||
| 40 | } | ||
| 41 | 37 | ||
| 42 | pkg_prerm_${PN} () { | 38 | ALTERNATIVE_PRIORITY = "100" |
| 43 | update-alternatives --remove grep grep.${PN} | 39 | |
| 44 | update-alternatives --remove egrep egrep.${PN} | 40 | ALTERNATIVE_${PN} = "grep egrep fgrep" |
| 45 | update-alternatives --remove fgrep fgrep.${PN} | 41 | ALTERNATIVE_LINK_NAME[grep] = "${base_bindir}/grep" |
| 46 | } | 42 | ALTERNATIVE_LINK_NAME[egrep] = "${base_bindir}/egrep" |
| 43 | ALTERNATIVE_LINK_NAME[fgrep] = "${base_bindir}/fgrep" | ||
diff --git a/meta/recipes-extended/grep/grep_2.9.bb b/meta/recipes-extended/grep/grep_2.9.bb index 1bc79f21c9..f936611062 100644 --- a/meta/recipes-extended/grep/grep_2.9.bb +++ b/meta/recipes-extended/grep/grep_2.9.bb | |||
| @@ -6,7 +6,7 @@ SECTION = "console/utils" | |||
| 6 | LICENSE = "GPLv3" | 6 | LICENSE = "GPLv3" |
| 7 | LIC_FILES_CHKSUM = "file://COPYING;md5=8006d9c814277c1bfc4ca22af94b59ee" | 7 | LIC_FILES_CHKSUM = "file://COPYING;md5=8006d9c814277c1bfc4ca22af94b59ee" |
| 8 | 8 | ||
| 9 | PR = "r1" | 9 | PR = "r2" |
| 10 | 10 | ||
| 11 | SRC_URI = "${GNU_MIRROR}/grep/grep-${PV}.tar.gz" | 11 | SRC_URI = "${GNU_MIRROR}/grep/grep-${PV}.tar.gz" |
| 12 | 12 | ||
| @@ -24,20 +24,18 @@ do_configure_prepend () { | |||
| 24 | do_install () { | 24 | do_install () { |
| 25 | autotools_do_install | 25 | autotools_do_install |
| 26 | install -d ${D}${base_bindir} | 26 | install -d ${D}${base_bindir} |
| 27 | mv ${D}${bindir}/grep ${D}${base_bindir}/grep.${PN} | 27 | mv ${D}${bindir}/grep ${D}${base_bindir}/grep |
| 28 | mv ${D}${bindir}/egrep ${D}${base_bindir}/egrep.${PN} | 28 | mv ${D}${bindir}/egrep ${D}${base_bindir}/egrep |
| 29 | mv ${D}${bindir}/fgrep ${D}${base_bindir}/fgrep.${PN} | 29 | mv ${D}${bindir}/fgrep ${D}${base_bindir}/fgrep |
| 30 | rmdir ${D}${bindir}/ | 30 | rmdir ${D}${bindir}/ |
| 31 | } | 31 | } |
| 32 | 32 | ||
| 33 | pkg_postinst_${PN} () { | 33 | inherit update-alternatives |
| 34 | update-alternatives --install ${base_bindir}/grep grep grep.${PN} 100 | 34 | |
| 35 | update-alternatives --install ${base_bindir}/egrep egrep egrep.${PN} 100 | 35 | ALTERNATIVE_PRIORITY = "100" |
| 36 | update-alternatives --install ${base_bindir}/fgrep fgrep fgrep.${PN} 100 | 36 | |
| 37 | } | 37 | ALTERNATIVE_${PN} = "grep egrep fgrep" |
| 38 | ALTERNATIVE_LINK_NAME[grep] = "${base_bindir}/grep" | ||
| 39 | ALTERNATIVE_LINK_NAME[egrep] = "${base_bindir}/egrep" | ||
| 40 | ALTERNATIVE_LINK_NAME[fgrep] = "${base_bindir}/fgrep" | ||
| 38 | 41 | ||
| 39 | pkg_prerm_${PN} () { | ||
| 40 | update-alternatives --remove grep grep.${PN} | ||
| 41 | update-alternatives --remove egrep egrep.${PN} | ||
| 42 | update-alternatives --remove fgrep fgrep.${PN} | ||
| 43 | } | ||
