freebsd-ports/devel/libcdb/files/patch-cdb__impl.h
Steve Wills aac3faa276 devel/libcdb: create port
The NetBSD's constant database (cdb) library provides a space efficient
key-value database based on perfect hashing, thus guaranteeing the O(1) lookup
time. The database preserves the key order.

WWW: https://github.com/rmind/libcdb

While be used by npf port
2019-05-24 14:49:28 +00:00

21 lines
481 B
C

--- cdb_impl.h.orig 2018-06-11 23:57:47 UTC
+++ cdb_impl.h
@@ -5,7 +5,7 @@
#ifndef _CDB_IMPL_H
#define _CDB_IMPL_H
-#ifndef __NetBSD__
+#if !defined(__NetBSD__) && !defined(__FreeBSD__)
#define __predict_false(exp) __builtin_expect((exp) != 0, 0)
@@ -27,6 +27,9 @@ le32enc(void *buf, uint32_t u)
p[2] = (u >> 16) & 0xff;
p[3] = (u >> 24) & 0xff;
}
+#endif
+
+#if !defined(__NetBSD__)
void mi_vector_hash(const void * __restrict, size_t, uint32_t, uint32_t[3]);