summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2014-11-15 04:17:12 +0000
committerMike Frysinger <vapier@gentoo.org>2014-11-15 04:17:12 +0000
commited698bf376d69c68c4f943a8026dd2ca78e600f3 (patch)
tree251607a95c029074c4a13cc58dfbca6674ce2961 /app-arch/unrar/unrar-5.2.2.ebuild
parentFix parallel build #528218 by Alexander E. Patrakov. (diff)
downloadgentoo-2-ed698bf376d69c68c4f943a8026dd2ca78e600f3.tar.gz
gentoo-2-ed698bf376d69c68c4f943a8026dd2ca78e600f3.tar.bz2
gentoo-2-ed698bf376d69c68c4f943a8026dd2ca78e600f3.zip
Build the lib & bin in diff subdirs so we can avoid the clean step.
(Portage version: 2.2.14/cvs/Linux x86_64, signed Manifest commit with key D2E96200)
Diffstat (limited to 'app-arch/unrar/unrar-5.2.2.ebuild')
-rw-r--r--app-arch/unrar/unrar-5.2.2.ebuild24
1 files changed, 13 insertions, 11 deletions
diff --git a/app-arch/unrar/unrar-5.2.2.ebuild b/app-arch/unrar/unrar-5.2.2.ebuild
index 02cd44fe9e50..4715ad5e334a 100644
--- a/app-arch/unrar/unrar-5.2.2.ebuild
+++ b/app-arch/unrar/unrar-5.2.2.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-arch/unrar/unrar-5.2.2.ebuild,v 1.2 2014/11/15 04:16:16 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-arch/unrar/unrar-5.2.2.ebuild,v 1.3 2014/11/15 04:17:12 vapier Exp $
EAPI=5
inherit eutils flag-o-matic multilib toolchain-funcs
@@ -32,27 +32,29 @@ src_prepare() {
sed -i "${sed_args[@]}" makefile
}
+src_configure() {
+ mkdir -p build-{lib,bin}
+ printf 'VPATH = ..\ninclude ../makefile' > build-lib/Makefile || die
+ cp build-{lib,bin}/Makefile || die
+}
+
src_compile() {
unrar_make() {
emake CXX="$(tc-getCXX)" CXXFLAGS="${CXXFLAGS}" STRIP=true "$@"
}
- unrar_make CXXFLAGS+=" -fPIC" lib
- ln -s libunrar$(get_libname ${PV%.*.*}) libunrar$(get_libname)
- ln -s libunrar$(get_libname ${PV%.*.*}) libunrar$(get_libname ${PV})
+ unrar_make CXXFLAGS+=" -fPIC" -C build-lib lib
+ ln -s libunrar$(get_libname ${PV%.*.*}) build-lib/libunrar$(get_libname)
+ ln -s libunrar$(get_libname ${PV%.*.*}) build-lib/libunrar$(get_libname ${PV})
- # The stupid code compiles a lot of objects differently if
- # they're going into a lib (-DRARDLL) or into the main app.
- # So for now, we can't link the main app against the lib.
- unrar_make clean
- unrar_make
+ unrar_make -C build-bin
}
src_install() {
- dobin unrar
+ dobin build-bin/unrar
dodoc readme.txt
- dolib.so libunrar*
+ dolib.so build-lib/libunrar*
insinto /usr/include/libunrar${PV%.*.*}
doins *.hpp