perl Configure VC-WIN32 no-apps no-async no-capieng no-deprecated no-docs no-dso no-module no-pinshared no-shared no-tests
:: Optional for multicore build
set CL=/MP
nmake DESTDIR=..\build install_dev
perl Configure VC-WIN64A no-apps no-async no-capieng no-deprecated no-docs no-dso no-module no-pinshared no-shared no-tests
:: Optional for multicore build
set CL=/MP
nmake DESTDIR=..\build install_dev
./Configure mingw no-apps no-async no-capieng no-deprecated no-docs no-dso no-module no-pinshared no-shared no-tests --cross-compile-prefix=i686-w64-mingw32- --prefix=.
make -jX
make DESTDIR=../dist/ install_dev
./Configure mingw no-apps no-async no-capieng no-deprecated no-docs no-dso no-module no-pinshared no-shared no-tests no-sse2 --cross-compile-prefix=i686-w64-mingw32- -D_WIN32_WINNT=0x0501 --prefix=.
make -jX
make DESTDIR=../dist-legacy/ install_dev
./Configure mingw64 no-apps no-async no-capieng no-deprecated no-docs no-dso no-module no-pinshared no-shared no-tests --cross-compile-prefix=x86_64-w64-mingw32- -D_WIN32_WINNT=0x0501 --prefix=.
make -jX
make DESTDIR=../dist64/ install_dev
Add -D_WIN32_WINNT=0x0501 to Configure command line if you need Windows XP compatibility.