From beca2c5704531d3afee51b148e0e6d01927d5153 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ulrich=20M=C3=BCller?= Date: Fri, 22 Nov 2019 12:09:41 +0100 Subject: [PATCH] app-editors/emacs: Remove compatibility code in pkg_preinst. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Needed only for Portage versions from before 2011. Since all ebuilds are EAPI 7 (approved in 2018), it should be safe to drop this. Package-Manager: Portage-2.3.79, Repoman-2.3.18 Signed-off-by: Ulrich Müller --- app-editors/emacs/emacs-23.4-r18.ebuild | 15 ++------------- app-editors/emacs/emacs-24.5-r7.ebuild | 15 ++------------- app-editors/emacs/emacs-25.3-r6.ebuild | 15 ++------------- app-editors/emacs/emacs-26.2.ebuild | 14 ++------------ app-editors/emacs/emacs-26.3-r1.ebuild | 14 ++------------ 5 files changed, 10 insertions(+), 63 deletions(-) diff --git a/app-editors/emacs/emacs-23.4-r18.ebuild b/app-editors/emacs/emacs-23.4-r18.ebuild index a5179566d3f6..7fa200d71b1c 100644 --- a/app-editors/emacs/emacs-23.4-r18.ebuild +++ b/app-editors/emacs/emacs-23.4-r18.ebuild @@ -328,19 +328,8 @@ src_install () { pkg_preinst() { # move Info dir file to correct name - local infodir=/usr/share/info/${EMACS_SUFFIX} f - if [[ -f ${ED}${infodir}/dir.orig ]]; then - mv "${ED}"${infodir}/dir{.orig,} || die "moving info dir failed" - elif [[ -d "${ED}"${infodir} ]]; then - # this should not happen in EAPI 4 - ewarn "Regenerating Info directory index in ${infodir} ..." - rm -f "${ED}"${infodir}/dir{,.*} - for f in "${ED}"${infodir}/*; do - if [[ ${f##*/} != *-[0-9]* && -e ${f} ]]; then - install-info --info-dir="${ED}"${infodir} "${f}" \ - || die "install-info failed" - fi - done + if [[ -d ${ED}/usr/share/info ]]; then + mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{.orig,} || die fi } diff --git a/app-editors/emacs/emacs-24.5-r7.ebuild b/app-editors/emacs/emacs-24.5-r7.ebuild index 80d215cacae8..7a8a310132f8 100644 --- a/app-editors/emacs/emacs-24.5-r7.ebuild +++ b/app-editors/emacs/emacs-24.5-r7.ebuild @@ -322,19 +322,8 @@ src_install () { pkg_preinst() { # move Info dir file to correct name - local infodir=/usr/share/info/${EMACS_SUFFIX} f - if [[ -f ${ED}${infodir}/dir.orig ]]; then - mv "${ED}"${infodir}/dir{.orig,} || die "moving info dir failed" - elif [[ -d "${ED}"${infodir} ]]; then - # this should not happen in EAPI 4 - ewarn "Regenerating Info directory index in ${infodir} ..." - rm -f "${ED}"${infodir}/dir{,.*} - for f in "${ED}"${infodir}/*; do - if [[ ${f##*/} != *-[0-9]* && -e ${f} ]]; then - install-info --info-dir="${ED}"${infodir} "${f}" \ - || die "install-info failed" - fi - done + if [[ -d ${ED}/usr/share/info ]]; then + mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{.orig,} || die fi } diff --git a/app-editors/emacs/emacs-25.3-r6.ebuild b/app-editors/emacs/emacs-25.3-r6.ebuild index 757eadddc093..8825e18aa7e9 100644 --- a/app-editors/emacs/emacs-25.3-r6.ebuild +++ b/app-editors/emacs/emacs-25.3-r6.ebuild @@ -330,19 +330,8 @@ src_install () { pkg_preinst() { # move Info dir file to correct name - local infodir=/usr/share/info/${EMACS_SUFFIX} f - if [[ -f ${ED}${infodir}/dir.orig ]]; then - mv "${ED}"${infodir}/dir{.orig,} || die "moving info dir failed" - elif [[ -d "${ED}"${infodir} ]]; then - # this should not happen in EAPI 4 - ewarn "Regenerating Info directory index in ${infodir} ..." - rm -f "${ED}"${infodir}/dir{,.*} - for f in "${ED}"${infodir}/*; do - if [[ ${f##*/} != *-[0-9]* && -e ${f} ]]; then - install-info --info-dir="${ED}"${infodir} "${f}" \ - || die "install-info failed" - fi - done + if [[ -d ${ED}/usr/share/info ]]; then + mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{.orig,} || die fi } diff --git a/app-editors/emacs/emacs-26.2.ebuild b/app-editors/emacs/emacs-26.2.ebuild index 3ac8b0f94dae..457aade942a7 100644 --- a/app-editors/emacs/emacs-26.2.ebuild +++ b/app-editors/emacs/emacs-26.2.ebuild @@ -347,18 +347,8 @@ src_install () { pkg_preinst() { # move Info dir file to correct name - local infodir=/usr/share/info/${EMACS_SUFFIX} f - if [[ -f ${ED}${infodir}/dir.orig ]]; then - mv "${ED}"${infodir}/dir{.orig,} || die - elif [[ -d "${ED}"${infodir} ]]; then - # this should not happen in EAPI 4 - ewarn "Regenerating Info directory index in ${infodir} ..." - rm -f "${ED}"${infodir}/dir{,.*} - for f in "${ED}"${infodir}/*; do - if [[ ${f##*/} != *-[0-9]* && -e ${f} ]]; then - install-info --info-dir="${ED}"${infodir} "${f}" || die - fi - done + if [[ -d ${ED}/usr/share/info ]]; then + mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{.orig,} || die fi } diff --git a/app-editors/emacs/emacs-26.3-r1.ebuild b/app-editors/emacs/emacs-26.3-r1.ebuild index eeb8091162ba..ba2743383655 100644 --- a/app-editors/emacs/emacs-26.3-r1.ebuild +++ b/app-editors/emacs/emacs-26.3-r1.ebuild @@ -356,18 +356,8 @@ src_install () { pkg_preinst() { # move Info dir file to correct name - local infodir=/usr/share/info/${EMACS_SUFFIX} f - if [[ -f ${ED}${infodir}/dir.orig ]]; then - mv "${ED}"${infodir}/dir{.orig,} || die - elif [[ -d "${ED}"${infodir} ]]; then - # this should not happen in EAPI 4 - ewarn "Regenerating Info directory index in ${infodir} ..." - rm -f "${ED}"${infodir}/dir{,.*} - for f in "${ED}"${infodir}/*; do - if [[ ${f##*/} != *-[0-9]* && -e ${f} ]]; then - install-info --info-dir="${ED}"${infodir} "${f}" || die - fi - done + if [[ -d ${ED}/usr/share/info ]]; then + mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{.orig,} || die fi } -- 2.26.2