summaryrefslogtreecommitdiff
path: root/extra/libcuckoo/PKGBUILD
diff options
context:
space:
mode:
authorAndreas Baumann <mail@andreasbaumann.cc>2022-02-11 06:40:40 +0100
committerAndreas Baumann <mail@andreasbaumann.cc>2022-02-11 06:40:40 +0100
commit2027c709e0ffc06f2e20660dce7100a0443ca10a (patch)
tree53bac90009e00200c7270d7c10362e5c6958702a /extra/libcuckoo/PKGBUILD
parent1323de7c15f8515752e0b1a8d4c44e9aaf764e94 (diff)
downloadpackages-2027c709e0ffc06f2e20660dce7100a0443ca10a.tar.xz
extra/libcuckoo: proper patching of the unit tests and -latomic for i486
Diffstat (limited to 'extra/libcuckoo/PKGBUILD')
-rw-r--r--extra/libcuckoo/PKGBUILD25
1 files changed, 23 insertions, 2 deletions
diff --git a/extra/libcuckoo/PKGBUILD b/extra/libcuckoo/PKGBUILD
index 86f9cd90..ffda60f6 100644
--- a/extra/libcuckoo/PKGBUILD
+++ b/extra/libcuckoo/PKGBUILD
@@ -1,2 +1,23 @@
-# ignoring tests for now, see https://github.com/efficient/libcuckoo/issues/143
-unset check
+# fix tests with https://github.com/efficient/libcuckoo/commit/c749c88864d286c3d875b1de2a082355b7838af7,
+# see https://github.com/efficient/libcuckoo/issues/137
+source+=('libcuckoo-0.3-resize-unit-test.patch')
+md5sums+=('653038be4849c29e459e946ce0cbdac6')
+eval "$(
+ {
+ declare -f prepare || \
+ printf 'prepare() { cd "${pkgname}-${pkgver}"\n}\n'
+ } \
+ | sed '
+ $ i patch -Np1 -i "$srcdir/libcuckoo-0.3-resize-unit-test.patch"
+ '
+)"
+
+# i486 needs -latomic
+if [ "$CARCH" = 'i486' ]; then
+ eval "$(
+ declare -f build | \
+ sed '
+ s/cmake /cmake -DCMAKE_CXX_STANDARD_LIBRARIES=-latomic /
+ '
+ )"
+fi