--- /usr/portage/dev-libs/libev/libev-4.15.ebuild 2013-09-26 21:31:09.000000000 +0400 +++ libev-4.15-r1.ebuild 2013-12-21 09:47:17.671755294 +0400 @@ -4,7 +4,7 @@ EAPI=5 -inherit autotools eutils multilib +inherit autotools-multilib DESCRIPTION="A high-performance event loop/event model with lots of feature" HOMEPAGE="http://software.schmorp.de/pkg/libev.html" @@ -22,30 +22,33 @@ DOCS=( Changes README ) -src_prepare() { - sed -i -e "/^include_HEADERS/s/ event.h//" Makefile.am || die - - # bug #411847 - epatch "${FILESDIR}/${PN}-pc.patch" - - eautoreconf -} +# bug #411847 +PATCHES=( "${FILESDIR}"/${PN}-pc.patch "${FILESDIR}"/${P}-gentoo.patch ) +AUTOTOOLS_AUTORECONF=1 src_configure() { - econf \ - --disable-maintainer-mode \ + local myeconfargs=( + --disable-maintainer-mode $(use_enable static-libs static) + ) + autotools-multilib_src_configure } src_install() { - default + autotools-multilib_src_install use static-libs || prune_libtool_files } pkg_preinst() { + keep_old_lib() { preserve_old_lib /usr/$(get_libdir)/libev.so.3.0.0 + } + multilib_foreach_abi keep_old_lib } pkg_postinst() { + keep_old_lib() { preserve_old_lib_notify /usr/$(get_libdir)/libev.so.3.0.0 + } + multilib_foreach_abi keep_old_lib }