--- libtool-2.4.2.ebuild 26 Apr 2012 13:07:54 -0000 1.5 +++ libtool-2.4.2.ebuild 15 Jan 2013 04:14:51 -0000 @@ -39,15 +39,37 @@ src_unpack() { fi } +bk() { + local opt=$1; shift + local file + for file ; do + case ${opt} in + save) chmod u+rw "${file}" && cp -p "${file}"{,.orig} || die ;; + touch) touch -r "${file}"{.orig,} || die ;; + restore) cp -p "${file}"{.orig,} || die ;; + esac + done +} + src_prepare() { use vanilla && return 0 + # We need to patch the local libtool.m4 because that is used to generate + # the local libtool which is later installed. But we don't want to install + # the hacked libtool.m4 as that'll get copied into other random projects. + bk save libltdl/{m4/libtool.m4,config/ltmain.sh} + epatch "${FILESDIR}"/${PN}-2.4.2-dynamic-gcc.patch #88596 + # Hack the timestamp so that we regen once, and `make` doesn't try again. + bk touch libltdl/{m4/libtool.m4,config/ltmain.sh} + cd libltdl/m4 epatch "${FILESDIR}"/1.5.20/${PN}-1.5.20-use-linux-version-in-fbsd.patch #109105 cd .. AT_NOELIBTOOLIZE=yes eautoreconf cd .. AT_NOELIBTOOLIZE=yes eautoreconf + + bk restore libltdl/m4/libtool.m4 } src_configure() { @@ -63,6 +85,7 @@ src_configure() { export CONFIG_SHELL=/bin/bash econf $(use_enable static-libs static) + bk restore libltdl/config/ltmain.sh } src_install() {