Gentoo Archives: gentoo-commits

From: Arthur Zamarin <arthurzam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/leveldb/
Date: Fri, 04 Feb 2022 20:16:55
Message-Id: 1644005802.24c755dc2ad54e7add8c111233094b5db08b0909.arthurzam@gentoo
1 commit: 24c755dc2ad54e7add8c111233094b5db08b0909
2 Author: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
3 AuthorDate: Fri Feb 4 20:11:49 2022 +0000
4 Commit: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
5 CommitDate: Fri Feb 4 20:16:42 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=24c755dc
7
8 dev-libs/leveldb: various fixes
9
10 - Redirect test suite temp directories to ${T}. This fixes an issue
11 I had when running the test suite in some arm chroots.
12 - Remove crc32c USE flag (otherwise uses bundled same code)
13 - Add flags during compilation for the USE flags
14 - Fix SLOT deps for app-arch/snappy and dev-util/google-perftools
15 (thanks iwdevtools for noting those)
16 - small styling fixes
17
18 - all those changes were tested on all stabilized arches just to be
19 sure.
20
21 Signed-off-by: Arthur Zamarin <arthurzam <AT> gentoo.org>
22
23 ...{leveldb-1.23-r2.ebuild => leveldb-1.23-r3.ebuild} | 19 +++++++++++++------
24 dev-libs/leveldb/metadata.xml | 3 ---
25 2 files changed, 13 insertions(+), 9 deletions(-)
26
27 diff --git a/dev-libs/leveldb/leveldb-1.23-r2.ebuild b/dev-libs/leveldb/leveldb-1.23-r3.ebuild
28 similarity index 75%
29 rename from dev-libs/leveldb/leveldb-1.23-r2.ebuild
30 rename to dev-libs/leveldb/leveldb-1.23-r3.ebuild
31 index 9adbd1551ad0..13684bcf2b50 100644
32 --- a/dev-libs/leveldb/leveldb-1.23-r2.ebuild
33 +++ b/dev-libs/leveldb/leveldb-1.23-r3.ebuild
34 @@ -12,13 +12,14 @@ SRC_URI="https://github.com/google/${PN}/archive/refs/tags/${PV}.tar.gz -> ${P}.
35 LICENSE="BSD"
36 SLOT="0/1"
37 KEYWORDS="amd64 arm arm64 ~mips ppc ppc64 ~riscv ~sparc x86 ~amd64-linux ~x86-linux"
38 -IUSE="+crc32c +snappy +tcmalloc test"
39 -
40 +IUSE="+snappy +tcmalloc test"
41 RESTRICT="!test? ( test )"
42
43 -DEPEND="crc32c? ( dev-libs/crc32c )
44 - snappy? ( app-arch/snappy )
45 - tcmalloc? ( dev-util/google-perftools )"
46 +DEPEND="
47 + dev-libs/crc32c
48 + snappy? ( app-arch/snappy:= )
49 + tcmalloc? ( dev-util/google-perftools:= )
50 +"
51 RDEPEND="${DEPEND}"
52 BDEPEND="test? ( dev-cpp/gtest )"
53
54 @@ -34,9 +35,15 @@ src_prepare() {
55
56 src_configure() {
57 local mycmakeargs=(
58 - -DBUILD_SHARED_LIBS=ON
59 + -DHAVE_CRC32C=ON
60 -DLEVELDB_BUILD_BENCHMARKS=OFF
61 + -DHAVE_SNAPPY=$(usex snappy)
62 + -DHAVE_TCMALLOC=$(usex tcmalloc)
63 -DLEVELDB_BUILD_TESTS=$(usex test)
64 )
65 cmake_src_configure
66 }
67 +
68 +src_test() {
69 + TEST_TMPDIR="${T}" TEMP="${T}" cmake_src_test
70 +}
71
72 diff --git a/dev-libs/leveldb/metadata.xml b/dev-libs/leveldb/metadata.xml
73 index e937f6bb5998..0c3bde759c88 100644
74 --- a/dev-libs/leveldb/metadata.xml
75 +++ b/dev-libs/leveldb/metadata.xml
76 @@ -9,7 +9,4 @@
77 <remote-id type="github">google/leveldb</remote-id>
78 <bugs-to>https://github.com/google/leveldb/issues</bugs-to>
79 </upstream>
80 - <use>
81 - <flag name="crc32c">Link against <pkg>dev-libs/crc32c</pkg> for accelerated CRC32C calculation</flag>
82 - </use>
83 </pkgmetadata>