summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authormiod <miod@openbsd.org>2014-05-01 20:42:59 +0000
committermiod <miod@openbsd.org>2014-05-01 20:42:59 +0000
commit9406436f29ab8532fa85e11145bb047e285e2a9b (patch)
tree95864a655b4b23e30d77262db9fc832ae06b7f96 /lib
parentFix include filename to get register name aliases under BSD (diff)
downloadwireguard-openbsd-9406436f29ab8532fa85e11145bb047e285e2a9b.tar.xz
wireguard-openbsd-9406436f29ab8532fa85e11145bb047e285e2a9b.zip
Enable use of the assembly code for BN (Montgomery) and SHA1.
Diffstat (limited to 'lib')
-rw-r--r--lib/libcrypto/arch/alpha/Makefile.inc40
-rw-r--r--lib/libcrypto/crypto/arch/alpha/Makefile.inc40
2 files changed, 80 insertions, 0 deletions
diff --git a/lib/libcrypto/arch/alpha/Makefile.inc b/lib/libcrypto/arch/alpha/Makefile.inc
new file mode 100644
index 00000000000..a13726e8cce
--- /dev/null
+++ b/lib/libcrypto/arch/alpha/Makefile.inc
@@ -0,0 +1,40 @@
+# $OpenBSD: Makefile.inc,v 1.1 2014/05/01 20:42:59 miod Exp $
+
+# alpha-specific libcrypto build rules
+
+# aes
+SRCS+= aes_core.c aes_cbc.c
+# bf
+SRCS+= bf_enc.c
+# bn
+SRCS+= bn_asm.c
+SSLASM+= bn alpha-mont
+# des
+SRCS+= des_enc.c fcrypt_b.c
+# modes
+CFLAGS+= -DGHASH_ASM
+SSLASM+= modes ghash-alpha
+# rc4
+SRCS+= rc4_enc.c rc4_skey.c
+## rc5
+#SRCS+= rc5_enc.c
+# sha
+CFLAGS+= -DSHA1_ASM
+SSLASM+= sha sha1-alpha
+# whrlpool
+SRCS+= wp_block.c
+
+.for dir f in ${SSLASM}
+SRCS+= ${f}.S
+GENERATED+=${f}.S
+${f}.S: ${LCRYPTO_SRC}/${dir}/asm/${f}.pl
+ /usr/bin/perl \
+ ${LCRYPTO_SRC}/${dir}/asm/${f}.pl > ${.TARGET}
+.endfor
+
+CFLAGS+= -DOPENSSL_CPUID_OBJ
+SRCS+= alphacpuid.S
+GENERATED+=alphacpuid.S
+alphacpuid.S: ${LCRYPTO_SRC}/alphacpuid.pl
+ /usr/bin/perl \
+ ${LCRYPTO_SRC}/alphacpuid.pl > ${.TARGET}
diff --git a/lib/libcrypto/crypto/arch/alpha/Makefile.inc b/lib/libcrypto/crypto/arch/alpha/Makefile.inc
new file mode 100644
index 00000000000..a13726e8cce
--- /dev/null
+++ b/lib/libcrypto/crypto/arch/alpha/Makefile.inc
@@ -0,0 +1,40 @@
+# $OpenBSD: Makefile.inc,v 1.1 2014/05/01 20:42:59 miod Exp $
+
+# alpha-specific libcrypto build rules
+
+# aes
+SRCS+= aes_core.c aes_cbc.c
+# bf
+SRCS+= bf_enc.c
+# bn
+SRCS+= bn_asm.c
+SSLASM+= bn alpha-mont
+# des
+SRCS+= des_enc.c fcrypt_b.c
+# modes
+CFLAGS+= -DGHASH_ASM
+SSLASM+= modes ghash-alpha
+# rc4
+SRCS+= rc4_enc.c rc4_skey.c
+## rc5
+#SRCS+= rc5_enc.c
+# sha
+CFLAGS+= -DSHA1_ASM
+SSLASM+= sha sha1-alpha
+# whrlpool
+SRCS+= wp_block.c
+
+.for dir f in ${SSLASM}
+SRCS+= ${f}.S
+GENERATED+=${f}.S
+${f}.S: ${LCRYPTO_SRC}/${dir}/asm/${f}.pl
+ /usr/bin/perl \
+ ${LCRYPTO_SRC}/${dir}/asm/${f}.pl > ${.TARGET}
+.endfor
+
+CFLAGS+= -DOPENSSL_CPUID_OBJ
+SRCS+= alphacpuid.S
+GENERATED+=alphacpuid.S
+alphacpuid.S: ${LCRYPTO_SRC}/alphacpuid.pl
+ /usr/bin/perl \
+ ${LCRYPTO_SRC}/alphacpuid.pl > ${.TARGET}