mingw32.bat 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. @rem OpenSSL with Mingw32+GNU as
  2. @rem ---------------------------
  3. perl Configure mingw %1 %2 %3 %4 %5 %6 %7 %8
  4. @echo off
  5. perl -e "exit 1 if '%1' eq 'no-asm'"
  6. if errorlevel 1 goto noasm
  7. echo Generating x86 for GNU assember
  8. echo Bignum
  9. cd crypto\bn\asm
  10. perl bn-586.pl gaswin > bn-win32.s
  11. perl co-586.pl gaswin > co-win32.s
  12. cd ..\..\..
  13. echo DES
  14. cd crypto\des\asm
  15. perl des-586.pl gaswin > d-win32.s
  16. cd ..\..\..
  17. echo crypt
  18. cd crypto\des\asm
  19. perl crypt586.pl gaswin > y-win32.s
  20. cd ..\..\..
  21. echo Blowfish
  22. cd crypto\bf\asm
  23. perl bf-586.pl gaswin > b-win32.s
  24. cd ..\..\..
  25. echo CAST5
  26. cd crypto\cast\asm
  27. perl cast-586.pl gaswin > c-win32.s
  28. cd ..\..\..
  29. echo RC4
  30. cd crypto\rc4\asm
  31. perl rc4-586.pl gaswin > r4-win32.s
  32. cd ..\..\..
  33. echo MD5
  34. cd crypto\md5\asm
  35. perl md5-586.pl gaswin > m5-win32.s
  36. cd ..\..\..
  37. echo SHA1
  38. cd crypto\sha\asm
  39. perl sha1-586.pl gaswin > s1-win32.s
  40. cd ..\..\..
  41. echo RIPEMD160
  42. cd crypto\ripemd\asm
  43. perl rmd-586.pl gaswin > rm-win32.s
  44. cd ..\..\..
  45. echo RC5\32
  46. cd crypto\rc5\asm
  47. perl rc5-586.pl gaswin > r5-win32.s
  48. cd ..\..\..
  49. :noasm
  50. echo Generating makefile
  51. perl util\mkfiles.pl >MINFO
  52. perl util\mk1mf.pl gaswin Mingw32 >ms\mingw32a.mak
  53. echo Generating DLL definition files
  54. perl util\mkdef.pl 32 libeay >ms\libeay32.def
  55. if errorlevel 1 goto end
  56. perl util\mkdef.pl 32 ssleay >ms\ssleay32.def
  57. if errorlevel 1 goto end
  58. rem copy ms\tlhelp32.h outinc
  59. echo Building the libraries
  60. mingw32-make -f ms/mingw32a.mak
  61. if errorlevel 1 goto end
  62. echo Generating the DLLs and input libraries
  63. dllwrap --dllname libeay32.dll --output-lib out/libeay32.a --def ms/libeay32.def out/libcrypto.a -lwsock32 -lgdi32
  64. if errorlevel 1 goto end
  65. dllwrap --dllname libssl32.dll --output-lib out/libssl32.a --def ms/ssleay32.def out/libssl.a out/libeay32.a
  66. if errorlevel 1 goto end
  67. echo Done compiling OpenSSL
  68. :end