Explorar el Código

Only enable SSE Salsa20 on x86 and x86_64 Linux

Adam Ierymenko hace 11 años
padre
commit
1952db5069
Se han modificado 1 ficheros con 20 adiciones y 2 borrados
  1. 20 2
      make-linux.mk

+ 20 - 2
make-linux.mk

@@ -6,8 +6,26 @@ INCLUDES=
 DEFS=
 LIBS=
 
-# Enable SSE-optimized Salsa20 in all modes
-DEFS+=-DZT_SALSA20_SSE 
+# Enable SSE-optimized Salsa20 on x86 and x86_64 machines
+MACHINE=$(shell uname -m)
+ifeq ($(MACHINE),x86_64)
+	DEFS+=-DZT_SALSA20_SSE 
+endif
+ifeq ($(MACHINE),amd64)
+	DEFS+=-DZT_SALSA20_SSE 
+endif
+ifeq ($(MACHINE),i686)
+	DEFS+=-DZT_SALSA20_SSE 
+endif
+ifeq ($(MACHINE),i586)
+	DEFS+=-DZT_SALSA20_SSE 
+endif
+ifeq ($(MACHINE),i386)
+	DEFS+=-DZT_SALSA20_SSE 
+endif
+ifeq ($(MACHINE),x86)
+	DEFS+=-DZT_SALSA20_SSE 
+endif
 
 # "make official" is a shortcut for this
 ifeq ($(ZT_OFFICIAL_RELEASE),1)