summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArthur Zamarin <arthurzam@gentoo.org>2022-02-04 22:11:49 +0200
committerArthur Zamarin <arthurzam@gentoo.org>2022-02-04 22:16:42 +0200
commit24c755dc2ad54e7add8c111233094b5db08b0909 (patch)
treea46f8e0e50bbf68f270be26b860c4ef652d031d3 /dev-libs/leveldb
parentdev-libs/leveldb: drop 1.20, 1.23-r1 (diff)
downloadgentoo-24c755dc2ad54e7add8c111233094b5db08b0909.tar.gz
gentoo-24c755dc2ad54e7add8c111233094b5db08b0909.tar.bz2
gentoo-24c755dc2ad54e7add8c111233094b5db08b0909.zip
dev-libs/leveldb: various fixes
- Redirect test suite temp directories to ${T}. This fixes an issue I had when running the test suite in some arm chroots. - Remove crc32c USE flag (otherwise uses bundled same code) - Add flags during compilation for the USE flags - Fix SLOT deps for app-arch/snappy and dev-util/google-perftools (thanks iwdevtools for noting those) - small styling fixes - all those changes were tested on all stabilized arches just to be sure. Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
Diffstat (limited to 'dev-libs/leveldb')
-rw-r--r--dev-libs/leveldb/leveldb-1.23-r3.ebuild (renamed from dev-libs/leveldb/leveldb-1.23-r2.ebuild)19
-rw-r--r--dev-libs/leveldb/metadata.xml3
2 files changed, 13 insertions, 9 deletions
diff --git a/dev-libs/leveldb/leveldb-1.23-r2.ebuild b/dev-libs/leveldb/leveldb-1.23-r3.ebuild
index 9adbd1551ad0..13684bcf2b50 100644
--- a/dev-libs/leveldb/leveldb-1.23-r2.ebuild
+++ b/dev-libs/leveldb/leveldb-1.23-r3.ebuild
@@ -12,13 +12,14 @@ SRC_URI="https://github.com/google/${PN}/archive/refs/tags/${PV}.tar.gz -> ${P}.
LICENSE="BSD"
SLOT="0/1"
KEYWORDS="amd64 arm arm64 ~mips ppc ppc64 ~riscv ~sparc x86 ~amd64-linux ~x86-linux"
-IUSE="+crc32c +snappy +tcmalloc test"
-
+IUSE="+snappy +tcmalloc test"
RESTRICT="!test? ( test )"
-DEPEND="crc32c? ( dev-libs/crc32c )
- snappy? ( app-arch/snappy )
- tcmalloc? ( dev-util/google-perftools )"
+DEPEND="
+ dev-libs/crc32c
+ snappy? ( app-arch/snappy:= )
+ tcmalloc? ( dev-util/google-perftools:= )
+"
RDEPEND="${DEPEND}"
BDEPEND="test? ( dev-cpp/gtest )"
@@ -34,9 +35,15 @@ src_prepare() {
src_configure() {
local mycmakeargs=(
- -DBUILD_SHARED_LIBS=ON
+ -DHAVE_CRC32C=ON
-DLEVELDB_BUILD_BENCHMARKS=OFF
+ -DHAVE_SNAPPY=$(usex snappy)
+ -DHAVE_TCMALLOC=$(usex tcmalloc)
-DLEVELDB_BUILD_TESTS=$(usex test)
)
cmake_src_configure
}
+
+src_test() {
+ TEST_TMPDIR="${T}" TEMP="${T}" cmake_src_test
+}
diff --git a/dev-libs/leveldb/metadata.xml b/dev-libs/leveldb/metadata.xml
index e937f6bb5998..0c3bde759c88 100644
--- a/dev-libs/leveldb/metadata.xml
+++ b/dev-libs/leveldb/metadata.xml
@@ -9,7 +9,4 @@
<remote-id type="github">google/leveldb</remote-id>
<bugs-to>https://github.com/google/leveldb/issues</bugs-to>
</upstream>
- <use>
- <flag name="crc32c">Link against <pkg>dev-libs/crc32c</pkg> for accelerated CRC32C calculation</flag>
- </use>
</pkgmetadata>