Quickpost: Compiling DLLs with MinGW on Kali

To compile the DLLs from this quickpost with MinGW on Kali, you first have to install MinGW.

Issue this command: apt install mingw-w64

Compile for 64-bit: x86_64-w64-mingw32-gcc -shared -o DemoDll.dll DemoDll.cpp

Compile for 32-bit: i686-w64-mingw32-gcc -shared -o DemoDll-x86.dll DemoDll.cpp

Option -shared is required to produce a DLL in stead of an EXE.

Quickpost info

 

Article Link: https://blog.didierstevens.com/2018/07/10/quickpost-compiling-dlls-with-mingw-on-kali/