Makefile.ssl 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. #
  2. # SSLeay/crypto/md5/Makefile
  3. #
  4. DIR= md5
  5. TOP= ../..
  6. CC= cc
  7. CPP= $(CC) -E
  8. INCLUDES=
  9. CFLAG=-g
  10. INSTALL_PREFIX=
  11. OPENSSLDIR= /usr/local/ssl
  12. INSTALLTOP=/usr/local/ssl
  13. MAKE= make -f Makefile.ssl
  14. MAKEDEPPROG= makedepend
  15. MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
  16. MAKEFILE= Makefile.ssl
  17. AR= ar r
  18. MD5_ASM_OBJ=
  19. CFLAGS= $(INCLUDES) $(CFLAG)
  20. # We let the C compiler driver to take care of .s files. This is done in
  21. # order to be excused from maintaining a separate set of architecture
  22. # dependent assembler flags. E.g. if you throw -mcpu=ultrasparc at SPARC
  23. # gcc, then the driver will automatically translate it to -xarch=v8plus
  24. # and pass it down to assembler.
  25. AS=$(CC) -c
  26. ASFLAGS=$(CFLAGS)
  27. GENERAL=Makefile
  28. TEST=md5test.c
  29. APPS=
  30. LIB=$(TOP)/libcrypto.a
  31. LIBSRC=md5_dgst.c md5_one.c
  32. LIBOBJ=md5_dgst.o md5_one.o $(MD5_ASM_OBJ)
  33. SRC= $(LIBSRC)
  34. EXHEADER= md5.h
  35. HEADER= md5_locl.h $(EXHEADER)
  36. ALL= $(GENERAL) $(SRC) $(HEADER)
  37. top:
  38. (cd ../..; $(MAKE) DIRS=crypto SDIRS=$(DIR) sub_all)
  39. all: lib
  40. lib: $(LIBOBJ)
  41. $(AR) $(LIB) $(LIBOBJ)
  42. $(RANLIB) $(LIB) || echo Never mind.
  43. @touch lib
  44. # elf
  45. asm/mx86-elf.o: asm/mx86unix.cpp
  46. $(CPP) -DELF -x c asm/mx86unix.cpp | as -o asm/mx86-elf.o
  47. # solaris
  48. asm/mx86-sol.o: asm/mx86unix.cpp
  49. $(CC) -E -DSOL asm/mx86unix.cpp | sed 's/^#.*//' > asm/mx86-sol.s
  50. as -o asm/mx86-sol.o asm/mx86-sol.s
  51. rm -f asm/mx86-sol.s
  52. # a.out
  53. asm/mx86-out.o: asm/mx86unix.cpp
  54. $(CPP) -DOUT asm/mx86unix.cpp | as -o asm/mx86-out.o
  55. # bsdi
  56. asm/mx86bsdi.o: asm/mx86unix.cpp
  57. $(CPP) -DBSDI asm/mx86unix.cpp | sed 's/ :/:/' | as -o asm/mx86bsdi.o
  58. asm/mx86unix.cpp: asm/md5-586.pl ../perlasm/x86asm.pl
  59. (cd asm; $(PERL) md5-586.pl cpp >mx86unix.cpp)
  60. asm/md5-sparcv8plus.o: asm/md5-sparcv9.S
  61. $(CC) $(ASFLAGS) -DMD5_BLOCK_DATA_ORDER -c \
  62. -o asm/md5-sparcv8plus.o asm/md5-sparcv9.S
  63. # Old GNU assembler doesn't understand V9 instructions, so we
  64. # hire /usr/ccs/bin/as to do the job. Note that option is called
  65. # *-gcc27, but even gcc 2>=8 users may experience similar problem
  66. # if they didn't bother to upgrade GNU assembler. Such users should
  67. # not choose this option, but be adviced to *remove* GNU assembler
  68. # or upgrade it.
  69. asm/md5-sparcv8plus-gcc27.o: asm/md5-sparcv9.S
  70. $(CC) $(ASFLAGS) -DMD5_BLOCK_DATA_ORDER -E asm/md5-sparcv9.S | \
  71. /usr/ccs/bin/as -xarch=v8plus - -o asm/md5-sparcv8plus-gcc27.o
  72. asm/md5-sparcv9.o: asm/md5-sparcv9.S
  73. $(CC) $(ASFLAGS) -DMD5_BLOCK_DATA_ORDER -c \
  74. -o asm/md5-sparcv9.o asm/md5-sparcv9.S
  75. files:
  76. $(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
  77. links:
  78. @$(TOP)/util/point.sh Makefile.ssl Makefile
  79. @$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
  80. @$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
  81. @$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
  82. install:
  83. @for i in $(EXHEADER) ; \
  84. do \
  85. (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
  86. chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
  87. done;
  88. tags:
  89. ctags $(SRC)
  90. tests:
  91. lint:
  92. lint -DLINT $(INCLUDES) $(SRC)>fluff
  93. depend:
  94. $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(LIBSRC)
  95. dclean:
  96. $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new
  97. mv -f Makefile.new $(MAKEFILE)
  98. clean:
  99. rm -f asm/mx86unix.cpp *.o asm/*.o *.obj lib tags core .pure .nfs* *.old *.bak fluff
  100. # DO NOT DELETE THIS LINE -- make depend depends on it.
  101. md5_dgst.o: ../../include/openssl/md5.h ../../include/openssl/opensslconf.h
  102. md5_dgst.o: ../../include/openssl/opensslv.h ../md32_common.h md5_dgst.c
  103. md5_dgst.o: md5_locl.h
  104. md5_one.o: ../../include/openssl/md5.h md5_one.c