I know this will sound silly, but it took me a lot of googling and mixing.
Been having some issues while manually compiling OpenSSL with GNU Make for Windows.
OpenSSL does not add implicit rules for C compilation, and the GNU Make for Windows defaults to G++, causing errors (mostly, missing include files).
You could go around all makefiles and add all the default rules, one at a time, or you can follow my lead:
Create a text file, with a name you can recognize.
Place it in your openssl-x.y.z directory.
It will contain our C rules, I named it
makefile.c_rules_fix.
Paste this inside:
%.o: %.c
$(CC) $(CFLAGS) -c -o $@ $< |
Create a batch file in the same directory, with these contents:
export MAKEFILES=$(PWD)/makefile.c_rules_fix
echo Adapt the following command for your system.
echo To build a static library, remove shared.
echo To build for mingw32, use "mingw".
echo Run ./Configure for more.
./Configure shared mingw64
make depend
make
make install |
Open a MSYS prompt and run the batch file.