diff options
author | Michał Górny <mgorny@gentoo.org> | 2019-09-17 09:07:44 +0200 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2019-09-17 09:11:58 +0200 |
commit | 27da295ed52b004a9f42fa4fdc06db9bcfde2667 (patch) | |
tree | b95f2767d723aa23d537e120ff852a71e3d3bec5 /app-text | |
parent | app-text/sgmltools-lite: Restore .cat backup for non-empty too (diff) | |
download | gentoo-27da295ed52b004a9f42fa4fdc06db9bcfde2667.tar.gz gentoo-27da295ed52b004a9f42fa4fdc06db9bcfde2667.tar.bz2 gentoo-27da295ed52b004a9f42fa4fdc06db9bcfde2667.zip |
app-text/xhtml1: Restore .cat backup for non-empty too
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'app-text')
-rw-r--r-- | app-text/xhtml1/xhtml1-20020801-r6.ebuild | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app-text/xhtml1/xhtml1-20020801-r6.ebuild b/app-text/xhtml1/xhtml1-20020801-r6.ebuild index 306fefc150cb..f8356d929bb6 100644 --- a/app-text/xhtml1/xhtml1-20020801-r6.ebuild +++ b/app-text/xhtml1/xhtml1-20020801-r6.ebuild @@ -46,8 +46,10 @@ pkg_preinst() { } pkg_postinst() { - if [[ ! -f ${EROOT}/etc/sgml/xhtml1.cat ]]; then - cp "${T}"/xhtml1.cat "${EROOT}"/etc/sgml/ || die + local backup=${T}/xhtml1.cat + local real=${EROOT}/etc/sgml/xhtml1.cat + if ! cmp -s "${backup}" "${real}"; then + cp "${backup}" "${real}" || die fi sgml-catalog-r1_pkg_postinst |