commit:     02da1bfffe30537bf7fe7680fc628acc9d6ec289
Author:     Anthony G. Basile <blueness <AT> gentoo <DOT> org>
AuthorDate: Tue Dec 26 19:24:33 2017 +0000
Commit:     Anthony G. Basile <blueness <AT> gentoo <DOT> org>
CommitDate: Tue Dec 26 19:25:45 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=02da1bff

dev-libs/mpfr: add preserve_old_lib, bug #642316

For people that have FEATURES=-preserve-libs, we don't want the toolchain
to break as the so name is bumped from libmpfr.so.4 to libmpfr.so.6.

Package-Manager: Portage-2.3.13, Repoman-2.3.3

 dev-libs/mpfr/{mpfr-4.0.0.ebuild => mpfr-4.0.0-r1.ebuild} | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/dev-libs/mpfr/mpfr-4.0.0.ebuild 
b/dev-libs/mpfr/mpfr-4.0.0-r1.ebuild
similarity index 90%
rename from dev-libs/mpfr/mpfr-4.0.0.ebuild
rename to dev-libs/mpfr/mpfr-4.0.0-r1.ebuild
index d74928dff90..fa5e936f499 100644
--- a/dev-libs/mpfr/mpfr-4.0.0.ebuild
+++ b/dev-libs/mpfr/mpfr-4.0.0-r1.ebuild
@@ -50,3 +50,11 @@ multilib_src_install_all() {
        rm "${ED}"/usr/share/doc/"${P}"/COPYING*
        use static-libs || find "${ED}"/usr -name '*.la' -delete
 }
+
+pkg_preinst() {
+       preserve_old_lib /usr/$(get_libdir)/libmpfr$(get_libname 4)
+}
+
+pkg_postinst() {
+       preserve_old_lib_notify /usr/$(get_libdir)/libmpfr$(get_libname 4)
+}

Reply via email to