summaryrefslogtreecommitdiff
path: root/dev-cpp/parallel-hashmap
diff options
context:
space:
mode:
Diffstat (limited to 'dev-cpp/parallel-hashmap')
-rw-r--r--dev-cpp/parallel-hashmap/Manifest2
-rw-r--r--dev-cpp/parallel-hashmap/metadata.xml37
-rw-r--r--dev-cpp/parallel-hashmap/parallel-hashmap-1.4.1.ebuild46
-rw-r--r--dev-cpp/parallel-hashmap/parallel-hashmap-2.0.0.ebuild46
4 files changed, 131 insertions, 0 deletions
diff --git a/dev-cpp/parallel-hashmap/Manifest b/dev-cpp/parallel-hashmap/Manifest
new file mode 100644
index 000000000000..f1fc4386ce19
--- /dev/null
+++ b/dev-cpp/parallel-hashmap/Manifest
@@ -0,0 +1,2 @@
+DIST parallel-hashmap-1.4.1.tar.gz 2058024 BLAKE2B bcb5886173a25325c6381f0f174f08de33a2c9c9a0bd43eed6eee6273a2dba357fdfc09064a35aef219c03f7460cf10949808ea982e2dede89f4e103bcbe4b8f SHA512 80fc90b1545ef6d05b33f29cd694fc5687d29c87463bd648bd91f84177e596432bc2630b5e57be80476c07e549689c65cb30d0e1901adfb2b34f57caa81d0751
+DIST parallel-hashmap-2.0.0.tar.gz 2059086 BLAKE2B 982297943a7044787b4280cefd62200cfe57dc318b1590cb6bd98a653b6297f9f359428e52b29831a544ba85c6be39d8aded94340df2009975b0926b9bf98754 SHA512 edd5ff6eb492bf0b34fcbb6594d3d07256c9498b677a3d8b41fd14329d7149f0fc11c697591447e4ea14e83268d98e129c34dfb11c87401c3cee35aaa016fc6e
diff --git a/dev-cpp/parallel-hashmap/metadata.xml b/dev-cpp/parallel-hashmap/metadata.xml
new file mode 100644
index 000000000000..ef53df07feb0
--- /dev/null
+++ b/dev-cpp/parallel-hashmap/metadata.xml
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM 'https://www.gentoo.org/dtd/metadata.dtd'>
+<pkgmetadata>
+ <maintainer type="person">
+ <email>denis7774@gmail.com</email>
+ <name>Denis Reva</name>
+ </maintainer>
+ <longdescription lang="en">
+Overview
+
+This repository aims to provide a set of excellent hash map implementations, as well as a btree alternative to std::map and std::set, with the following characteristics:
+
+Header only: nothing to build, just copy the parallel_hashmap directory to your project and you are good to go.
+
+drop-in replacement for std::unordered_map, std::unordered_set, std::map and std::set
+
+Compiler with C++11 support required, C++14 and C++17 APIs are provided (such as try_emplace)
+
+Very efficient, significantly faster than your compiler's unordered map/set or Boost's, or than sparsepp
+
+Memory friendly: low memory usage, although a little higher than sparsepp
+
+Supports heterogeneous lookup
+
+Easy to forward declare: just include phmap_fwd_decl.h in your header files to forward declare Parallel Hashmap containers [note: this does not work currently for hash maps with pointer keys]
+
+Dump/load feature: when a flat hash map stores data that is std::trivially_copyable, the table can be dumped to disk and restored as a single array, very efficiently, and without requiring any hash computation. This is typically about 10 times faster than doing element-wise serialization to disk, but it will use 10% to 60% extra disk space. See examples/serialize.cc. (flat hash map/set only)
+
+Automatic support for boost's hash_value() method for providing the hash function (see examples/hash_value.h). Also default hash support for std::pair and std::tuple.
+
+natvis visualization support in Visual Studio (hash map/set only)
+ </longdescription>
+ <upstream>
+ <bugs-to>https://github.com/greg7mdp/parallel-hashmap/issues</bugs-to>
+ <remote-id type="github">greg7mdp/parallel-hashmap</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-cpp/parallel-hashmap/parallel-hashmap-1.4.1.ebuild b/dev-cpp/parallel-hashmap/parallel-hashmap-1.4.1.ebuild
new file mode 100644
index 000000000000..e51d8e9c9107
--- /dev/null
+++ b/dev-cpp/parallel-hashmap/parallel-hashmap-1.4.1.ebuild
@@ -0,0 +1,46 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CMAKE_MAKEFILE_GENERATOR=emake
+
+inherit cmake
+
+DESCRIPTION="Family of header-only, fast and memory-friendly hashmap and btree containers"
+HOMEPAGE="
+ https://greg7mdp.github.io/parallel-hashmap/
+ https://github.com/greg7mdp/parallel-hashmap
+"
+SRC_URI="https://github.com/greg7mdp/parallel-hashmap/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~arm64"
+IUSE="examples test"
+
+CDEPEND="dev-libs/cereal"
+DEPEND="${CDEPEND} test? ( dev-cpp/gtest )"
+RDEPEND="${CDEPEND}"
+
+# tests will download gtest, not trivial to use the system one
+# https://github.com/greg7mdp/parallel-hashmap/issues/154
+RESTRICT="!test? ( test )"
+src_configure() {
+ local mycmakeargs=(
+ -DPHMAP_BUILD_EXAMPLES=$(usex examples)
+ -DPHMAP_BUILD_TESTS=$(usex test)
+ )
+ if use test; then
+ mycmakeargs+=( -DPHMAP_GTEST_LIBS="gmock -lgmock_main -lgtest -lgtest_main" )
+ fi
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+ if use examples ; then
+ dodoc -r examples
+ docompress -x "/usr/share/doc/${PF}/examples"
+ fi
+}
diff --git a/dev-cpp/parallel-hashmap/parallel-hashmap-2.0.0.ebuild b/dev-cpp/parallel-hashmap/parallel-hashmap-2.0.0.ebuild
new file mode 100644
index 000000000000..e51d8e9c9107
--- /dev/null
+++ b/dev-cpp/parallel-hashmap/parallel-hashmap-2.0.0.ebuild
@@ -0,0 +1,46 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CMAKE_MAKEFILE_GENERATOR=emake
+
+inherit cmake
+
+DESCRIPTION="Family of header-only, fast and memory-friendly hashmap and btree containers"
+HOMEPAGE="
+ https://greg7mdp.github.io/parallel-hashmap/
+ https://github.com/greg7mdp/parallel-hashmap
+"
+SRC_URI="https://github.com/greg7mdp/parallel-hashmap/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~arm64"
+IUSE="examples test"
+
+CDEPEND="dev-libs/cereal"
+DEPEND="${CDEPEND} test? ( dev-cpp/gtest )"
+RDEPEND="${CDEPEND}"
+
+# tests will download gtest, not trivial to use the system one
+# https://github.com/greg7mdp/parallel-hashmap/issues/154
+RESTRICT="!test? ( test )"
+src_configure() {
+ local mycmakeargs=(
+ -DPHMAP_BUILD_EXAMPLES=$(usex examples)
+ -DPHMAP_BUILD_TESTS=$(usex test)
+ )
+ if use test; then
+ mycmakeargs+=( -DPHMAP_GTEST_LIBS="gmock -lgmock_main -lgtest -lgtest_main" )
+ fi
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+ if use examples ; then
+ dodoc -r examples
+ docompress -x "/usr/share/doc/${PF}/examples"
+ fi
+}