commit: 1ffd1b26731d512c0554282394d7f3e58d1fa6f7
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Tue Sep 17 07:07:39 2019 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Tue Sep 17 07:11:56 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1ffd1b26
app-text/openjade: Restore .cat backup for non-empty too
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
app-text/openjade/openjade-1.3.2-r9.ebuild | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/app-text/openjade/openjade-1.3.2-r9.ebuild
b/app-text/openjade/openjade-1.3.2-r9.ebuild
index 2d63798c3d7..9aa17662d63 100644
--- a/app-text/openjade/openjade-1.3.2-r9.ebuild
+++ b/app-text/openjade/openjade-1.3.2-r9.ebuild
@@ -124,8 +124,10 @@ pkg_preinst() {
}
pkg_postinst() {
- if [[ ! -f ${EROOT}/etc/sgml/${P}.cat ]]; then
- cp "${T}"/${P}.cat "${EROOT}"/etc/sgml/ || die
+ local backup=${T}/${P}.cat
+ local real=${EROOT}/etc/sgml/${P}.cat
+ if ! cmp -s "${backup}" "${real}"; then
+ cp "${backup}" "${real}" || die
fi
# this one's shared with docbook-dsssl, so we need to do it in postinst
if ! grep -q -s ${P}.cat \