summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-libs/leveldb')
-rw-r--r--dev-libs/leveldb/leveldb-1.20.ebuild6
-rw-r--r--dev-libs/leveldb/leveldb-1.23-r1.ebuild37
-rw-r--r--dev-libs/leveldb/leveldb-1.23-r6.ebuild51
-rw-r--r--dev-libs/leveldb/metadata.xml3
4 files changed, 54 insertions, 43 deletions
diff --git a/dev-libs/leveldb/leveldb-1.20.ebuild b/dev-libs/leveldb/leveldb-1.20.ebuild
index fbf7e9603eda..6961f094c8cc 100644
--- a/dev-libs/leveldb/leveldb-1.20.ebuild
+++ b/dev-libs/leveldb/leveldb-1.20.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -13,7 +13,7 @@ LICENSE="BSD"
# https://github.com/google/leveldb/issues/536
SLOT="0/1"
KEYWORDS="amd64 arm arm64 ~mips ppc ppc64 ~riscv ~sparc x86 ~amd64-linux ~x86-linux"
-IUSE="+snappy static-libs kernel_FreeBSD +tcmalloc test"
+IUSE="+snappy static-libs +tcmalloc test"
RESTRICT="!test? ( test )"
DEPEND="tcmalloc? ( dev-util/google-perftools )
@@ -34,7 +34,7 @@ src_configure() {
tc-export AR CC CXX
export OPT="-DNDEBUG ${CPPFLAGS}"
- TARGET_OS=$(usex kernel_FreeBSD FreeBSD Linux) \
+ TARGET_OS=Linux \
USE_SNAPPY=$(usex snappy) \
USE_TCMALLOC=no \
TMPDIR=${T} \
diff --git a/dev-libs/leveldb/leveldb-1.23-r1.ebuild b/dev-libs/leveldb/leveldb-1.23-r1.ebuild
deleted file mode 100644
index 498da29525eb..000000000000
--- a/dev-libs/leveldb/leveldb-1.23-r1.ebuild
+++ /dev/null
@@ -1,37 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit cmake
-
-DESCRIPTION="A fast key-value storage library written at Google"
-HOMEPAGE="https://github.com/google/leveldb"
-SRC_URI="https://github.com/google/${PN}/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0/1"
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux"
-IUSE="+crc32c +snappy +tcmalloc test"
-
-RESTRICT="!test? ( test )"
-
-DEPEND="crc32c? ( dev-libs/crc32c )
- snappy? ( app-arch/snappy )
- tcmalloc? ( dev-util/google-perftools )"
-RDEPEND="${DEPEND}"
-BDEPEND="test? ( dev-cpp/gtest )"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-1.23-system-testdeps.patch
- "${FILESDIR}"/${PN}-1.23-remove-benchmark-dep.patch
-)
-
-src_configure() {
- local mycmakeargs=(
- -DBUILD_SHARED_LIBS=ON
- -DLEVELDB_BUILD_BENCHMARKS=OFF
- -DLEVELDB_BUILD_TESTS=$(usex test)
- )
- cmake_src_configure
-}
diff --git a/dev-libs/leveldb/leveldb-1.23-r6.ebuild b/dev-libs/leveldb/leveldb-1.23-r6.ebuild
new file mode 100644
index 000000000000..c963638d5fd9
--- /dev/null
+++ b/dev-libs/leveldb/leveldb-1.23-r6.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="A fast key-value storage library written at Google"
+HOMEPAGE="https://github.com/google/leveldb"
+SRC_URI="https://github.com/google/${PN}/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/1"
+KEYWORDS="amd64 arm arm64 ~loong ~mips ppc ppc64 ~riscv ~sparc x86 ~amd64-linux ~x86-linux"
+IUSE="+snappy +tcmalloc test"
+RESTRICT="!test? ( test )"
+
+DEPEND="
+ dev-libs/crc32c
+ snappy? ( app-arch/snappy:= )
+ tcmalloc? ( dev-util/google-perftools:=[-minimal] )
+"
+RDEPEND="${DEPEND}"
+BDEPEND="test? ( dev-cpp/gtest )"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.23-system-testdeps.patch
+ "${FILESDIR}"/${PN}-1.23-remove-benchmark-dep.patch
+)
+
+src_prepare() {
+ sed -e '/fno-rtti/d' -i CMakeLists.txt || die
+ cmake_src_prepare
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DCMAKE_CXX_STANDARD=14 # C++14 or later required for >=gtest-1.13.0
+ -DHAVE_CRC32C=ON
+ -DLEVELDB_BUILD_BENCHMARKS=OFF
+ -DHAVE_SNAPPY=$(usex snappy)
+ -DHAVE_TCMALLOC=$(usex tcmalloc)
+ -DLEVELDB_BUILD_TESTS=$(usex test)
+ -DHAVE_CLANG_THREAD_SAFETY=OFF # adds -Werror to current build and all revdeps
+ )
+ 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>