Enabling SHA-NI (which is done by default) sets -msse4 and -msha,
which generates popcntl instructions in librhash. My Thinkpad T400
doesn't support those:
cpu0: Intel(R) Core(TM)2 Duo CPU T9400 @ 2.53GHz, 1600.16 MHz,
06-17-0a, patch 00000a0b
cpu0: cpuid 1
edx=bfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
ecx=408e3fd<SSE3,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,XSAVE>
This makes e.g. cmake crash with a SIGILL. I don't know if rhash's
SHA-NI functions are used anywhere, but disabling them fixes the
issue on my machine.
diff /usr/ports
path + /usr/ports
commit - 9153b9d3e6b9fbc534afa3caa6eef5c9e04ab191
blob - b0883dab0c696ad9aa20cd5c8f8a659329a652b2
file + security/rhash/Makefile
--- security/rhash/Makefile
+++ security/rhash/Makefile
@@ -3,7 +3,7 @@ COMMENT = utility and library for computing hash sums
GH_ACCOUNT = rhash
GH_PROJECT = RHash
GH_TAGNAME = v1.4.6
-REVISION = 0
+REVISION = 1
PKGNAME = ${DISTNAME:L}
SHARED_LIBS = rhash 1.1
@@ -21,6 +21,7 @@ WANTLIB = c
CONFIGURE_STYLE = simple
CONFIGURE_ARGS = --enable-lib-static \
+ --disable-shani \
--extra-cflags="${CFLAGS}" \
--extra-ldflags="${LDFLAGS}" \
--mandir=${PREFIX}/man \