forked from Lainports/freebsd-ports
security/highwayhash: Update g20181002 -> g20190324
This commit is contained in:
parent
753e14d8f5
commit
a5989a768f
4 changed files with 8 additions and 76 deletions
|
|
@ -2,7 +2,7 @@
|
|||
# $FreeBSD$
|
||||
|
||||
PORTNAME= highwayhash
|
||||
PORTVERSION= g20181002
|
||||
PORTVERSION= g20190324
|
||||
PORTEPOCH= 1
|
||||
CATEGORIES= security
|
||||
|
||||
|
|
@ -20,14 +20,7 @@ ONLY_FOR_ARCHS_REASON= Assembly is implemented only for specific architectures i
|
|||
USES= compiler:c++11-lib gmake
|
||||
USE_GITHUB= yes
|
||||
GH_ACCOUNT= google
|
||||
GH_TAGNAME= c5ee50b
|
||||
GH_TAGNAME= 30bd801
|
||||
USE_LDCONFIG= yes
|
||||
|
||||
# workaround for https://github.com/google/highwayhash/issues/69
|
||||
|
||||
post-install:
|
||||
# Symlink upstream issue: https://github.com/google/highwayhash/issues/57
|
||||
${RM} ${STAGEDIR}${PREFIX}/lib/libhighwayhash.so
|
||||
${LN} -s libhighwayhash.so.0 ${STAGEDIR}${PREFIX}/lib/libhighwayhash.so
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
|
|
|||
|
|
@ -1,3 +1,3 @@
|
|||
TIMESTAMP = 1538491392
|
||||
SHA256 (google-highwayhash-g20181002-c5ee50b_GH0.tar.gz) = 728a25a21f9d9f4e0af418bc41167a666b9ea1ba9133f5211becef4f9a3fc47a
|
||||
SIZE (google-highwayhash-g20181002-c5ee50b_GH0.tar.gz) = 153393
|
||||
TIMESTAMP = 1563763616
|
||||
SHA256 (google-highwayhash-g20190324-30bd801_GH0.tar.gz) = 9a00d0a1b28e57ec9a20487e975dcb023536c6944d2ece1ed24ffd1e62f34b63
|
||||
SIZE (google-highwayhash-g20190324-30bd801_GH0.tar.gz) = 158965
|
||||
|
|
|
|||
|
|
@ -1,64 +0,0 @@
|
|||
--- highwayhash/os_specific.cc.orig 2017-05-08 14:09:02 UTC
|
||||
+++ highwayhash/os_specific.cc
|
||||
@@ -40,6 +40,16 @@
|
||||
#define OS_LINUX 0
|
||||
#endif
|
||||
|
||||
+#ifdef __FreeBSD__
|
||||
+#define OS_FREEBSD 1
|
||||
+#include <sched.h>
|
||||
+#include <sys/time.h>
|
||||
+#include <sys/param.h>
|
||||
+#include <sys/cpuset.h>
|
||||
+#else
|
||||
+#define OS_FREEBSD 0
|
||||
+#endif
|
||||
+
|
||||
#ifdef __MACH__
|
||||
#define OS_MAC 1
|
||||
#include <mach/mach.h>
|
||||
@@ -134,6 +144,10 @@ ThreadAffinity* GetThreadAffinity() {
|
||||
const int err = cpuset_getaffinity(CPU_LEVEL_WHICH, CPU_WHICH_PID, pid,
|
||||
sizeof(cpuset_t), &affinity->set);
|
||||
CHECK(err == 0);
|
||||
+#elif OS_FREEBSD
|
||||
+ const pid_t pid = 0; // current thread
|
||||
+ const int err = cpuset_getaffinity(CPU_LEVEL_WHICH, CPU_WHICH_TID, pid, sizeof(cpuset_t), &affinity->set);
|
||||
+ CHECK(err == 0);
|
||||
#endif
|
||||
return affinity;
|
||||
}
|
||||
@@ -165,6 +179,10 @@ void SetThreadAffinity(ThreadAffinity* a
|
||||
const int err = cpuset_setaffinity(CPU_LEVEL_WHICH, CPU_WHICH_PID, pid,
|
||||
sizeof(cpuset_t), &affinity->set);
|
||||
CHECK(err == 0);
|
||||
+#elif OS_FREEBSD
|
||||
+ const pid_t pid = 0; // current thread
|
||||
+ const int err = cpuset_setaffinity(CPU_LEVEL_WHICH, CPU_WHICH_TID, pid, sizeof(cpuset_t), &affinity->set);
|
||||
+ CHECK(err == 0);
|
||||
#else
|
||||
#error "port"
|
||||
#endif
|
||||
@@ -192,6 +210,12 @@ std::vector<int> AvailableCPUs() {
|
||||
cpus.push_back(cpu);
|
||||
}
|
||||
}
|
||||
+#elif OS_FREEBSD
|
||||
+ for (size_t cpu = 0; cpu < sizeof(cpuset_t) * 8; ++cpu) {
|
||||
+ if (CPU_ISSET(cpu, &affinity->set)) {
|
||||
+ cpus.push_back(cpu);
|
||||
+ }
|
||||
+ }
|
||||
#else
|
||||
#error "port"
|
||||
#endif
|
||||
@@ -208,6 +232,9 @@ void PinThreadToCPU(const int cpu) {
|
||||
#elif OS_FREEBSD
|
||||
CPU_ZERO(&affinity.set);
|
||||
CPU_SET(cpu, &affinity.set);
|
||||
+#elif OS_FREEBSD
|
||||
+ CPU_ZERO(&affinity.set);
|
||||
+ CPU_SET(cpu, &affinity.set);
|
||||
#else
|
||||
#error "port"
|
||||
#endif
|
||||
|
|
@ -5,6 +5,7 @@ include/highwayhash/data_parallel.h
|
|||
include/highwayhash/endianess.h
|
||||
include/highwayhash/hh_avx2.h
|
||||
include/highwayhash/hh_buffer.h
|
||||
include/highwayhash/hh_neon.h
|
||||
include/highwayhash/hh_portable.h
|
||||
include/highwayhash/hh_sse41.h
|
||||
include/highwayhash/hh_types.h
|
||||
|
|
@ -16,6 +17,7 @@ include/highwayhash/iaca.h
|
|||
include/highwayhash/instruction_sets.h
|
||||
include/highwayhash/load3.h
|
||||
include/highwayhash/nanobenchmark.h
|
||||
include/highwayhash/os_mac.h
|
||||
include/highwayhash/os_specific.h
|
||||
include/highwayhash/profiler.h
|
||||
include/highwayhash/robust_statistics.h
|
||||
|
|
@ -27,6 +29,7 @@ include/highwayhash/state_helpers.h
|
|||
include/highwayhash/tsc_timer.h
|
||||
include/highwayhash/vector128.h
|
||||
include/highwayhash/vector256.h
|
||||
include/highwayhash/vector_neon.h
|
||||
include/highwayhash/vector_test_target.h
|
||||
lib/libhighwayhash.a
|
||||
lib/libhighwayhash.so
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue