Makefile revision 194206
1# 2# OpenSSL/crypto/sha/Makefile 3# 4 5DIR= sha 6TOP= ../.. 7CC= cc 8CPP= $(CC) -E 9INCLUDES= 10CFLAG=-g 11MAKEFILE= Makefile 12AR= ar r 13 14SHA1_ASM_OBJ= 15 16CFLAGS= $(INCLUDES) $(CFLAG) 17ASFLAGS= $(INCLUDES) $(ASFLAG) 18AFLAGS= $(ASFLAGS) 19 20GENERAL=Makefile 21TEST=shatest.c sha1test.c sha256t.c sha512t.c 22APPS= 23 24LIB=$(TOP)/libcrypto.a 25LIBSRC=sha_dgst.c sha1dgst.c sha_one.c sha1_one.c sha256.c sha512.c 26LIBOBJ=sha_dgst.o sha1dgst.o sha_one.o sha1_one.o sha256.o sha512.o $(SHA1_ASM_OBJ) 27 28SRC= $(LIBSRC) 29 30EXHEADER= sha.h 31HEADER= sha_locl.h $(EXHEADER) 32 33ALL= $(GENERAL) $(SRC) $(HEADER) 34 35top: 36 (cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all) 37 38all: lib 39 40lib: $(LIBOBJ) 41 $(ARX) $(LIB) $(LIBOBJ) 42 $(RANLIB) $(LIB) || echo Never mind. 43 @touch lib 44 45# ELF 46sx86-elf.s: asm/sha1-586.pl ../perlasm/x86asm.pl 47 (cd asm; $(PERL) sha1-586.pl elf $(CFLAGS) $(PROCESSOR) > ../$@) 48s512sse2-elf.s: asm/sha512-sse2.pl ../perlasm/x86asm.pl 49 (cd asm; $(PERL) sha512-sse2.pl elf $(CFLAGS) $(PROCESSOR) > ../$@) 50# COFF 51sx86-cof.s: asm/sha1-586.pl ../perlasm/x86asm.pl 52 (cd asm; $(PERL) sha1-586.pl coff $(CFLAGS) $(PROCESSOR) > ../$@) 53s512sse2-cof.s: asm/sha512-sse2.pl ../perlasm/x86asm.pl 54 (cd asm; $(PERL) sha512-sse2.pl coff $(CFLAGS) $(PROCESSOR) > ../$@) 55# a.out 56sx86-out.s: asm/sha1-586.pl ../perlasm/x86asm.pl 57 (cd asm; $(PERL) sha1-586.pl a.out $(CFLAGS) $(PROCESSOR) > ../$@) 58s512sse2-out.s: asm/sha512-sse2.pl ../perlasm/x86asm.pl 59 (cd asm; $(PERL) sha512-sse2.pl a.out $(CFLAGS) $(PROCESSOR) > ../$@) 60 61sha1-ia64.s: asm/sha1-ia64.pl 62 (cd asm; $(PERL) sha1-ia64.pl ../$@ $(CFLAGS)) 63sha256-ia64.s: asm/sha512-ia64.pl 64 (cd asm; $(PERL) sha512-ia64.pl ../$@ $(CFLAGS)) 65sha512-ia64.s: asm/sha512-ia64.pl 66 (cd asm; $(PERL) sha512-ia64.pl ../$@ $(CFLAGS)) 67 68# Solaris make has to be explicitly told 69sha1-x86_64.s: asm/sha1-x86_64.pl; $(PERL) asm/sha1-x86_64.pl $@ 70sha256-x86_64.s:asm/sha512-x86_64.pl; $(PERL) asm/sha512-x86_64.pl $@ 71sha512-x86_64.s:asm/sha512-x86_64.pl; $(PERL) asm/sha512-x86_64.pl $@ 72 73files: 74 $(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO 75 76links: 77 @$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER) 78 @$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST) 79 @$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS) 80 81install: 82 @[ -n "$(INSTALLTOP)" ] # should be set by top Makefile... 83 @headerlist="$(EXHEADER)"; for i in $$headerlist ; \ 84 do \ 85 (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ 86 chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ 87 done; 88 89tags: 90 ctags $(SRC) 91 92tests: 93 94lint: 95 lint -DLINT $(INCLUDES) $(SRC)>fluff 96 97depend: 98 @[ -n "$(MAKEDEPEND)" ] # should be set by upper Makefile... 99 $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(LIBSRC) 100 101dclean: 102 $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new 103 mv -f Makefile.new $(MAKEFILE) 104 105clean: 106 rm -f *.s *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff 107 108# DO NOT DELETE THIS LINE -- make depend depends on it. 109 110sha1_one.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h 111sha1_one.o: ../../include/openssl/opensslconf.h 112sha1_one.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h 113sha1_one.o: ../../include/openssl/safestack.h ../../include/openssl/sha.h 114sha1_one.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h 115sha1_one.o: sha1_one.c 116sha1dgst.o: ../../include/openssl/e_os2.h ../../include/openssl/fips.h 117sha1dgst.o: ../../include/openssl/opensslconf.h 118sha1dgst.o: ../../include/openssl/opensslv.h ../../include/openssl/sha.h 119sha1dgst.o: ../md32_common.h sha1dgst.c sha_locl.h 120sha256.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h 121sha256.o: ../../include/openssl/fips.h ../../include/openssl/opensslconf.h 122sha256.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h 123sha256.o: ../../include/openssl/safestack.h ../../include/openssl/sha.h 124sha256.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h 125sha256.o: ../md32_common.h sha256.c 126sha512.o: ../../e_os.h ../../include/openssl/bio.h 127sha512.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h 128sha512.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h 129sha512.o: ../../include/openssl/fips.h ../../include/openssl/lhash.h 130sha512.o: ../../include/openssl/opensslconf.h ../../include/openssl/opensslv.h 131sha512.o: ../../include/openssl/ossl_typ.h ../../include/openssl/safestack.h 132sha512.o: ../../include/openssl/sha.h ../../include/openssl/stack.h 133sha512.o: ../../include/openssl/symhacks.h ../cryptlib.h sha512.c 134sha_dgst.o: ../../include/openssl/bio.h ../../include/openssl/crypto.h 135sha_dgst.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h 136sha_dgst.o: ../../include/openssl/fips.h ../../include/openssl/lhash.h 137sha_dgst.o: ../../include/openssl/opensslconf.h 138sha_dgst.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h 139sha_dgst.o: ../../include/openssl/safestack.h ../../include/openssl/sha.h 140sha_dgst.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h 141sha_dgst.o: ../md32_common.h sha_dgst.c sha_locl.h 142sha_one.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h 143sha_one.o: ../../include/openssl/opensslconf.h ../../include/openssl/opensslv.h 144sha_one.o: ../../include/openssl/ossl_typ.h ../../include/openssl/safestack.h 145sha_one.o: ../../include/openssl/sha.h ../../include/openssl/stack.h 146sha_one.o: ../../include/openssl/symhacks.h sha_one.c 147