diff options
author | peter <peter@FreeBSD.org> | 2002-05-03 00:14:39 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2002-05-03 00:14:39 +0000 |
commit | afb49cba0dff86548cb42f8d4eb03d29f5aa97d2 (patch) | |
tree | 85400debd2bd2c66ca232d0c5e3e6551ecd8fe2d /secure/lib/libcrypto/Makefile | |
parent | 4bd83f238785826252b148590755a82692a2dcfc (diff) | |
download | FreeBSD-src-afb49cba0dff86548cb42f8d4eb03d29f5aa97d2.zip FreeBSD-src-afb49cba0dff86548cb42f8d4eb03d29f5aa97d2.tar.gz |
Pre-generate the optimized x86 crypto code and check it in rather than
depending on perl at build time. Makefile.asm is a helper for after the
next import.
With my cvs@ hat on, the relatively small repo cost of this is acceptable,
especially given that we have other (much bigger) things like
lib*.so.gz.uu checked in under src/lib/compat/*.
Reviewed by: kris (maintainer)
Diffstat (limited to 'secure/lib/libcrypto/Makefile')
-rw-r--r-- | secure/lib/libcrypto/Makefile | 58 |
1 files changed, 21 insertions, 37 deletions
diff --git a/secure/lib/libcrypto/Makefile b/secure/lib/libcrypto/Makefile index f7bbd10..71166cb 100644 --- a/secure/lib/libcrypto/Makefile +++ b/secure/lib/libcrypto/Makefile @@ -16,13 +16,8 @@ ${LCRYPTO_SRC}/stack ${LCRYPTO_SRC}/txt_db ${LCRYPTO_SRC}/x509 \ ${LCRYPTO_SRC}/x509v3 -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -.PATH: ${LCRYPTO_SRC}/rc4/asm ${LCRYPTO_SRC}/rc5/asm \ - ${LCRYPTO_SRC}/des/asm ${LCRYPTO_SRC}/cast/asm \ - ${LCRYPTO_SRC}/sha/asm ${LCRYPTO_SRC}/bn/asm \ - ${LCRYPTO_SRC}/bf/asm ${LCRYPTO_SRC}/md5/asm \ - ${LCRYPTO_SRC}/ripemd/asm -PERLPATH= ${LCRYPTO_SRC}/des/asm:${LCRYPTO_SRC}/perlasm +.if ${MACHINE_ARCH} == "i386" +.PATH: ${.CURDIR}/i386 .endif .if defined(MAKE_IDEA) && ${MAKE_IDEA} == YES @@ -58,11 +53,11 @@ SRCS+= a_bitstr.c a_bmp.c a_bool.c a_bytes.c a_d2i_fp.c a_digest.c \ # blowfish SRCS+= bf_cfb64.c bf_ecb.c bf_ofb64.c bf_skey.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" +.if ${MACHINE_ARCH} == "i386" .if ${MACHINE_CPU:Mi686} -SRCS+= bf-686.pl +SRCS+= bf-686.s .else -SRCS+= bf-586.pl +SRCS+= bf-586.s .endif .else SRCS+= bf_enc.c @@ -79,8 +74,8 @@ SRCS+= bn_add.c bn_blind.c bn_ctx.c bn_div.c bn_err.c \ bn_exp.c bn_exp2.c bn_gcd.c bn_lib.c bn_mont.c bn_mpi.c \ bn_mul.c bn_prime.c bn_print.c bn_rand.c bn_recp.c bn_shift.c \ bn_sqr.c bn_word.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -SRCS+= bn-586.pl co-586.pl +.if ${MACHINE_ARCH} == "i386" +SRCS+= bn-586.s co-586.s .else SRCS+= bn_asm.c .endif @@ -90,8 +85,8 @@ SRCS+= buf_err.c buffer.c # cast SRCS+= c_cfb64.c c_ecb.c c_ofb64.c c_skey.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -SRCS+= cast-586.pl +.if ${MACHINE_ARCH} == "i386" +SRCS+= cast-586.s .else SRCS+= c_enc.c .endif @@ -108,8 +103,8 @@ SRCS+= cbc_cksm.c cbc_enc.c cfb64ede.c cfb64enc.c cfb_enc.c \ fcrypt.c ofb64ede.c ofb64enc.c ofb_enc.c pcbc_enc.c \ qud_cksm.c rand_key.c read2pwd.c read_pwd.c rpc_enc.c \ set_key.c str2key.c xcbc_enc.c rnd_keys.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -SRCS+= des-586.pl crypt586.pl +.if ${MACHINE_ARCH} == "i386" +SRCS+= des-586.s crypt586.s .else SRCS+= des_enc.c fcrypt_b.c .endif @@ -156,8 +151,8 @@ SRCS+= md4_dgst.c md4_one.c # md5 SRCS+= md5_dgst.c md5_one.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -SRCS+= md5-586.pl +.if ${MACHINE_ARCH} == "i386" +SRCS+= md5-586.s .endif # mdc2 @@ -185,24 +180,24 @@ SRCS+= rc2_cbc.c rc2cfb64.c rc2_ecb.c rc2ofb64.c rc2_skey.c # rc4 SRCS+= rc4_skey.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -SRCS+= rc4-586.pl +.if ${MACHINE_ARCH} == "i386" +SRCS+= rc4-586.s .else SRCS+= rc4_enc.c .endif # rc5 SRCS+= rc5cfb64.c rc5_ecb.c rc5ofb64.c rc5_skey.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -SRCS+= rc5-586.pl +.if ${MACHINE_ARCH} == "i386" +SRCS+= rc5-586.s .else SRCS+= rc5_enc.c .endif # ripemd SRCS+= rmd_dgst.c rmd_one.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -SRCS+= rmd-586.pl +.if ${MACHINE_ARCH} == "i386" +SRCS+= rmd-586.s .endif # rsa @@ -213,8 +208,8 @@ SRCS+= rsa_chk.c rsa_eay.c rsa_err.c rsa_gen.c rsa_lib.c rsa_none.c \ # sha SRCS+= sha_dgst.c sha_one.c sha1_one.c sha1dgst.c -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -SRCS+= sha1-586.pl +.if ${MACHINE_ARCH} == "i386" +SRCS+= sha1-586.s .endif # stack @@ -387,14 +382,3 @@ SYMLINKS+= lib${LIB}_p.a ${LIBDIR}/libdes_p.a .endif .include <bsd.lib.mk> - -.if !defined(NOPERL) && !defined(NO_PERL) && ${MACHINE_ARCH} == "i386" -CLEANFILES+= ${SRCS:M*.pl:S/.pl$/.cmt/} ${SRCS:M*.pl:S/.pl$/.s/} -.SUFFIXES: .pl .cmt - -.pl.cmt: - perl -I${PERLPATH} ${.IMPSRC} elf ${CPUTYPE:Mi386:S/i//} > ${.TARGET} - -.cmt.s: - tr -d "'" < ${.IMPSRC} > ${.TARGET} -.endif |