Lines 4-10
Link Here
|
4 |
|
4 |
|
5 |
EAPI="3" |
5 |
EAPI="3" |
6 |
PYTHON_DEPEND="2" |
6 |
PYTHON_DEPEND="2" |
7 |
inherit autotools eutils python |
7 |
inherit cmake-utils python |
8 |
|
8 |
|
9 |
DESCRIPTION="Google C++ Testing Framework" |
9 |
DESCRIPTION="Google C++ Testing Framework" |
10 |
HOMEPAGE="http://code.google.com/p/googletest/" |
10 |
HOMEPAGE="http://code.google.com/p/googletest/" |
Lines 13-19
Link Here
|
13 |
LICENSE="BSD" |
13 |
LICENSE="BSD" |
14 |
SLOT="0" |
14 |
SLOT="0" |
15 |
KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~ppc-macos" |
15 |
KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~ppc-macos" |
16 |
IUSE="examples threads static-libs" |
16 |
IUSE="examples threads" |
|
|
17 |
|
18 |
DOCS="CHANGES CONTRIBUTORS README" |
17 |
|
19 |
|
18 |
pkg_setup() { |
20 |
pkg_setup() { |
19 |
python_set_active_version 2 |
21 |
python_set_active_version 2 |
Lines 25-52
Link Here
|
25 |
python_convert_shebangs -r 2 . |
27 |
python_convert_shebangs -r 2 . |
26 |
|
28 |
|
27 |
epatch "${FILESDIR}/${P}-asneeded.patch" |
29 |
epatch "${FILESDIR}/${P}-asneeded.patch" |
|
|
30 |
epatch "${FILESDIR}/${P}-pthread-as-needed.patch" |
28 |
eautoreconf |
31 |
eautoreconf |
29 |
} |
32 |
} |
30 |
|
33 |
|
31 |
src_configure() { |
34 |
src_configure() { |
32 |
econf \ |
35 |
if use threads ; then |
33 |
$(use_enable static-libs static) \ |
36 |
econf --with-pthreads || die |
34 |
$(use_with threads pthreads) || die |
37 |
MYCMAKEARGS="-Dbuild_with_pthreads=1" |
35 |
} |
38 |
else |
36 |
|
39 |
econf || die |
37 |
src_test() { |
40 |
fi |
38 |
# explicitly use parallel make |
41 |
cmake-utils_src_configure || die |
39 |
emake check || die |
|
|
40 |
} |
42 |
} |
41 |
|
43 |
|
42 |
src_install() { |
44 |
src_install() { |
43 |
emake DESTDIR="${D}" install || die "emake install failed" |
45 |
cmake-utils_src_install |
44 |
|
|
|
45 |
dodoc CHANGES CONTRIBUTORS README || die |
46 |
|
47 |
if ! use static-libs ; then |
48 |
rm "${ED}"/usr/lib*/*.la || die |
49 |
fi |
50 |
|
46 |
|
51 |
if use examples ; then |
47 |
if use examples ; then |
52 |
insinto /usr/share/doc/${PF}/examples |
48 |
insinto /usr/share/doc/${PF}/examples |