diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..7b011aa --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/robin-map-0.2.0.tar.gz diff --git a/README.md b/README.md deleted file mode 100644 index 605fe8b..0000000 --- a/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# robin-map - -The robin-map package \ No newline at end of file diff --git a/robin-map.spec b/robin-map.spec new file mode 100644 index 0000000..0398d22 --- /dev/null +++ b/robin-map.spec @@ -0,0 +1,75 @@ +%global debug_package %{nil} + +Name: robin-map +Version: 0.2.0 +Release: 1%{?dist} +Summary: C++ implementation of a fast hash map and hash set using robin hood hashing + +License: MIT +URL: https://github.com/Tessil/robin-map +Source0: https://github.com/Tessil/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz + +BuildArch: noarch + +BuildRequires: cmake gcc-c++ +BuildRequires: boost-devel + +%description +The robin-map library is a C++ implementation of a fast hash map and hash set +using open-addressing and linear robin hood hashing with backward shift +deletion to resolve collisions. + +*** This is a header only library. *** +The package you want is %{name}-devel. + + +%package devel +Summary: %{summary} + +%description devel +The robin-map library is a C++ implementation of a fast hash map and hash set +using open-addressing and linear robin hood hashing with backward shift +deletion to resolve collisions. + +Four classes are provided: tsl::robin_map, tsl::robin_set, tsl::robin_pg_map +and tsl::robin_pg_set. The first two are faster and use a power of two growth +policy, the last two use a prime growth policy instead and are able to cope +better with a poor hash function. Use the prime version if there is a chance of +repeating patterns in the lower bits of your hash (e.g. you are storing +pointers with an identity hash function). See GrowthPolicy for details. + +A benchmark of tsl::robin_map against other hash maps may be found here. This +page also gives some advices on which hash table structure you should try for +your use case (useful if you are a bit lost with the multiple hash tables +implementations in the tsl namespace). + + +%prep +%autosetup + + +%build +rm -rf build && mkdir build && pushd build +%cmake ../ +%make_build + + +%install +mkdir -p %{buildroot}%{_includedir} +cp -a tsl %{buildroot}%{_includedir}/ + + +%check +pushd build +./test_robin_map + + +%files devel +%license LICENSE +%doc README.md +%{_includedir}/tsl/ + + +%changelog +* Mon Jun 11 2018 Richard Shaw - 0.2.0-1 +- Initial packaging. diff --git a/sources b/sources new file mode 100644 index 0000000..44f62ac --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (robin-map-0.2.0.tar.gz) = 6d16c612a0d646fd08857f2f6ee2909fb607ff05fa9c7733a2b618d662f63bba2f99677b75a09870a1582b7b37f255c4ff1f9171c897c3cfa73dd8879de1ec18