2
0

Makefile 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. LIBNAME= librsaref
  2. SRC= rsaref.c
  3. OBJ= rsaref.o
  4. HEADER= rsaref.h
  5. CC= gcc
  6. PIC= -fPIC
  7. CFLAGS= -g -I../../../include $(PIC) -DENGINE_DYNAMIC_SUPPORT
  8. AR= ar r
  9. RANLIB= ranlib
  10. LIB= $(LIBNAME).a
  11. SHLIB= $(LIBNAME).so
  12. all:
  13. @echo 'Please choose a system to build on:'
  14. @echo ''
  15. @echo 'tru64: Tru64 Unix, Digital Unix, Digital OSF/1'
  16. @echo 'solaris: Solaris'
  17. @echo 'irix: IRIX'
  18. @echo 'hpux32: 32-bit HP/UX'
  19. @echo 'hpux64: 64-bit HP/UX'
  20. @echo 'aix: AIX'
  21. @echo 'gnu: Generic GNU-based system (gcc and GNU ld)'
  22. @echo ''
  23. FORCE.install:
  24. install: FORCE.install
  25. cd install; \
  26. make -f unix/makefile CFLAGS='-I. -DPROTOTYPES=1 -O -c' RSAREFLIB=librsaref.a librsaref.a
  27. FORCE.update:
  28. update: FORCE.update
  29. perl ../../../util/mkerr.pl -conf rsaref.ec \
  30. -nostatic -staticloader -write rsaref.c
  31. darwin: install $(SHLIB).darwin
  32. cygwin: install $(SHLIB).cygwin
  33. gnu: install $(SHLIB).gnu
  34. alpha-osf1: install $(SHLIB).alpha-osf1
  35. tru64: install $(SHLIB).tru64
  36. solaris: install $(SHLIB).solaris
  37. irix: install $(SHLIB).irix
  38. hpux32: install $(SHLIB).hpux32
  39. hpux64: install $(SHLIB).hpux64
  40. aix: install $(SHLIB).aix
  41. reliantunix: install $(SHLIB).reliantunix
  42. $(LIB): $(OBJ)
  43. $(AR) $(LIB) $(OBJ)
  44. - $(RANLIB) $(LIB)
  45. LINK_SO= \
  46. ld -r -o $(LIBNAME).o $$ALLSYMSFLAGS $(LIB) install/librsaref.a && \
  47. (nm -Pg $(LIBNAME).o | grep ' [BDT] ' | cut -f1 -d' ' > $(LIBNAME).exp; \
  48. $$SHAREDCMD $$SHAREDFLAGS -o $(SHLIB) $(LIBNAME).o -L ../../.. -lcrypto -lc)
  49. $(SHLIB).darwin: $(LIB) install/librsaref.a
  50. ALLSYMSFLAGS='-all_load' \
  51. SHAREDFLAGS='-dynamiclib -install_name $(SHLIB)' \
  52. SHAREDCMD='$(CC)'; \
  53. $(LINK_SO)
  54. touch $(SHLIB).darwin
  55. $(SHLIB).cygwin: $(LIB) install/librsaref.a
  56. ALLSYMSFLAGS='--whole-archive' \
  57. SHAREDFLAGS='-shared -Wl,-Bsymbolic -Wl,--out-implib,$(LIBNAME).dll.a' \
  58. SHAREDCMD='$(CC)'; \
  59. $(LINK_SO)
  60. touch $(SHLIB).cygwin
  61. $(SHLIB).gnu: $(LIB) install/librsaref.a
  62. ALLSYMSFLAGS='--whole-archive' \
  63. SHAREDFLAGS='-shared -Wl,-soname=$(SHLIB)' \
  64. SHAREDCMD='$(CC)'; \
  65. $(LINK_SO)
  66. touch $(SHLIB).gnu
  67. $(SHLIB).tru64: $(LIB) install/librsaref.a
  68. ALLSYMSFLAGS='-all' \
  69. SHAREDFLAGS='-shared' \
  70. SHAREDCMD='$(CC)'; \
  71. $(LINK_SO)
  72. touch $(SHLIB).tru64
  73. $(SHLIB).solaris: $(LIB) install/librsaref.a
  74. ALLSYMSFLAGS='-z allextract' \
  75. SHAREDFLAGS='-G -h $(SHLIB)' \
  76. SHAREDCMD='$(CC)'; \
  77. $(LINK_SO)
  78. touch $(SHLIB).solaris
  79. $(SHLIB).irix: $(LIB) install/librsaref.a
  80. ALLSYMSFLAGS='-all' \
  81. SHAREDFLAGS='-shared -Wl,-soname,$(SHLIB)' \
  82. SHAREDCMD='$(CC)'; \
  83. $(LINK_SO)
  84. touch $(SHLIB).irix
  85. $(SHLIB).hpux32: $(LIB) install/librsaref.a
  86. ALLSYMSFLAGS='-Fl' \
  87. SHAREDFLAGS='+vnocompatwarnings -b -z +s +h $(SHLIB)' \
  88. SHAREDCMD='/usr/ccs/bin/ld'; \
  89. $(LINK_SO)
  90. touch $(SHLIB).hpux32
  91. $(SHLIB).hpux64: $(LIB) install/librsaref.a
  92. ALLSYMSFLAGS='+forceload' \
  93. SHAREDFLAGS='-b -z +h $(SHLIB)' \
  94. SHAREDCMD='/usr/ccs/bin/ld'; \
  95. $(LINK_SO)
  96. touch $(SHLIB).hpux64
  97. $(SHLIB).aix: $(LIB) install/librsaref.a
  98. ALLSYMSFLAGS='-bnogc' \
  99. SHAREDFLAGS='-G -bE:$(LIBNAME).exp -bM:SRE' \
  100. SHAREDCMD='$(CC)'; \
  101. $(LINK_SO)
  102. touch $(SHLIB).aix
  103. depend:
  104. sed -e '/^# DO NOT DELETE.*/,$$d' < Makefile > Makefile.tmp
  105. echo '# DO NOT DELETE THIS LINE -- make depend depends on it.' >> Makefile.tmp
  106. gcc -M $(CFLAGS) $(SRC) >> Makefile.tmp
  107. perl ../../../util/clean-depend.pl < Makefile.tmp > Makefile.new
  108. rm -f Makefile.tmp Makefile
  109. mv Makefile.new Makefile
  110. # DO NOT DELETE THIS LINE -- make depend depends on it.
  111. rsaref.o: ../../../include/openssl/asn1.h ../../../include/openssl/bio.h
  112. rsaref.o: ../../../include/openssl/bn.h ../../../include/openssl/crypto.h
  113. rsaref.o: ../../../include/openssl/dh.h ../../../include/openssl/dsa.h
  114. rsaref.o: ../../../include/openssl/e_os2.h ../../../include/openssl/engine.h
  115. rsaref.o: ../../../include/openssl/err.h ../../../include/openssl/lhash.h
  116. rsaref.o: ../../../include/openssl/opensslconf.h
  117. rsaref.o: ../../../include/openssl/opensslv.h
  118. rsaref.o: ../../../include/openssl/ossl_typ.h ../../../include/openssl/rand.h
  119. rsaref.o: ../../../include/openssl/rsa.h ../../../include/openssl/safestack.h
  120. rsaref.o: ../../../include/openssl/stack.h ../../../include/openssl/symhacks.h
  121. rsaref.o: ../../../include/openssl/ui.h rsaref.c rsaref_err.c rsaref_err.h
  122. rsaref.o: source/des.h source/global.h source/md2.h source/md5.h source/rsa.h
  123. rsaref.o: source/rsaref.h