Makefile 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155
  1. #
  2. # crypto/aes/Makefile
  3. #
  4. DIR= aes
  5. TOP= ../..
  6. CC= cc
  7. CPP= $(CC) -E
  8. INCLUDES=
  9. CFLAG=-g
  10. MAKEFILE= Makefile
  11. AR= ar r
  12. AES_ENC=aes_core.o aes_cbc.o
  13. CFLAGS= $(INCLUDES) $(CFLAG)
  14. ASFLAGS= $(INCLUDES) $(ASFLAG)
  15. AFLAGS= $(ASFLAGS)
  16. GENERAL=Makefile
  17. #TEST=aestest.c
  18. TEST=
  19. APPS=
  20. LIB=$(TOP)/libcrypto.a
  21. LIBSRC=aes_core.c aes_misc.c aes_ecb.c aes_cbc.c aes_cfb.c aes_ofb.c \
  22. aes_ctr.c aes_ige.c aes_wrap.c
  23. LIBOBJ=aes_misc.o aes_ecb.o aes_cfb.o aes_ofb.o aes_ctr.o aes_ige.o aes_wrap.o \
  24. $(AES_ENC)
  25. SRC= $(LIBSRC)
  26. EXHEADER= aes.h
  27. HEADER= aes_locl.h $(EXHEADER)
  28. ALL= $(GENERAL) $(SRC) $(HEADER)
  29. top:
  30. (cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all)
  31. all: lib
  32. lib: $(LIBOBJ)
  33. $(AR) $(LIB) $(LIBOBJ)
  34. $(RANLIB) $(LIB) || echo Never mind.
  35. @touch lib
  36. aes-ia64.s: asm/aes-ia64.S
  37. $(CC) $(CFLAGS) -E asm/aes-ia64.S > $@
  38. aes-586.s: asm/aes-586.pl ../perlasm/x86asm.pl
  39. $(PERL) asm/aes-586.pl $(PERLASM_SCHEME) $(CFLAGS) $(PROCESSOR) > $@
  40. vpaes-x86.s: asm/vpaes-x86.pl ../perlasm/x86asm.pl
  41. $(PERL) asm/vpaes-x86.pl $(PERLASM_SCHEME) $(CFLAGS) $(PROCESSOR) > $@
  42. aesni-x86.s: asm/aesni-x86.pl ../perlasm/x86asm.pl
  43. $(PERL) asm/aesni-x86.pl $(PERLASM_SCHEME) $(CFLAGS) $(PROCESSOR) > $@
  44. aes-x86_64.s: asm/aes-x86_64.pl
  45. $(PERL) asm/aes-x86_64.pl $(PERLASM_SCHEME) > $@
  46. vpaes-x86_64.s: asm/vpaes-x86_64.pl
  47. $(PERL) asm/vpaes-x86_64.pl $(PERLASM_SCHEME) > $@
  48. bsaes-x86_64.s: asm/bsaes-x86_64.pl
  49. $(PERL) asm/bsaes-x86_64.pl $(PERLASM_SCHEME) > $@
  50. aesni-x86_64.s: asm/aesni-x86_64.pl
  51. $(PERL) asm/aesni-x86_64.pl $(PERLASM_SCHEME) > $@
  52. aesni-sha1-x86_64.s: asm/aesni-sha1-x86_64.pl
  53. $(PERL) asm/aesni-sha1-x86_64.pl $(PERLASM_SCHEME) > $@
  54. aes-sparcv9.s: asm/aes-sparcv9.pl
  55. $(PERL) asm/aes-sparcv9.pl $(CFLAGS) > $@
  56. aes-ppc.s: asm/aes-ppc.pl
  57. $(PERL) asm/aes-ppc.pl $(PERLASM_SCHEME) $@
  58. aes-parisc.s: asm/aes-parisc.pl
  59. $(PERL) asm/aes-parisc.pl $(PERLASM_SCHEME) $@
  60. aes-mips.S: asm/aes-mips.pl
  61. $(PERL) asm/aes-mips.pl $(PERLASM_SCHEME) $@
  62. # GNU make "catch all"
  63. aes-%.S: asm/aes-%.pl; $(PERL) $< $(PERLASM_SCHEME) > $@
  64. aes-armv4.o: aes-armv4.S
  65. files:
  66. $(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
  67. links:
  68. @$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
  69. @$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
  70. @$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
  71. install:
  72. @[ -n "$(INSTALLTOP)" ] # should be set by top Makefile...
  73. @headerlist="$(EXHEADER)"; for i in $$headerlist ; \
  74. do \
  75. (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
  76. chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
  77. done;
  78. tags:
  79. ctags $(SRC)
  80. tests:
  81. lint:
  82. lint -DLINT $(INCLUDES) $(SRC)>fluff
  83. update: depend
  84. depend:
  85. @[ -n "$(MAKEDEPEND)" ] # should be set by upper Makefile...
  86. $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(LIBSRC)
  87. dclean:
  88. $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new
  89. mv -f Makefile.new $(MAKEFILE)
  90. clean:
  91. rm -f *.s *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
  92. # DO NOT DELETE THIS LINE -- make depend depends on it.
  93. aes_cbc.o: ../../include/openssl/aes.h ../../include/openssl/modes.h
  94. aes_cbc.o: ../../include/openssl/opensslconf.h aes_cbc.c
  95. aes_cfb.o: ../../include/openssl/aes.h ../../include/openssl/modes.h
  96. aes_cfb.o: ../../include/openssl/opensslconf.h aes_cfb.c
  97. aes_core.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
  98. aes_core.o: ../../include/openssl/opensslconf.h aes_core.c aes_locl.h
  99. aes_ctr.o: ../../include/openssl/aes.h ../../include/openssl/modes.h
  100. aes_ctr.o: ../../include/openssl/opensslconf.h aes_ctr.c
  101. aes_ecb.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
  102. aes_ecb.o: ../../include/openssl/opensslconf.h aes_ecb.c aes_locl.h
  103. aes_ige.o: ../../e_os.h ../../include/openssl/aes.h ../../include/openssl/bio.h
  104. aes_ige.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h
  105. aes_ige.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
  106. aes_ige.o: ../../include/openssl/lhash.h ../../include/openssl/opensslconf.h
  107. aes_ige.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
  108. aes_ige.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
  109. aes_ige.o: ../../include/openssl/symhacks.h ../cryptlib.h aes_ige.c aes_locl.h
  110. aes_misc.o: ../../include/openssl/aes.h ../../include/openssl/crypto.h
  111. aes_misc.o: ../../include/openssl/e_os2.h ../../include/openssl/opensslconf.h
  112. aes_misc.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
  113. aes_misc.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
  114. aes_misc.o: ../../include/openssl/symhacks.h aes_locl.h aes_misc.c
  115. aes_ofb.o: ../../include/openssl/aes.h ../../include/openssl/modes.h
  116. aes_ofb.o: ../../include/openssl/opensslconf.h aes_ofb.c
  117. aes_wrap.o: ../../e_os.h ../../include/openssl/aes.h
  118. aes_wrap.o: ../../include/openssl/bio.h ../../include/openssl/buffer.h
  119. aes_wrap.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h
  120. aes_wrap.o: ../../include/openssl/err.h ../../include/openssl/lhash.h
  121. aes_wrap.o: ../../include/openssl/opensslconf.h
  122. aes_wrap.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
  123. aes_wrap.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
  124. aes_wrap.o: ../../include/openssl/symhacks.h ../cryptlib.h aes_wrap.c