Quoting the building instructions for K-Meleon (http://kmeleon.sourceforge.net/docs/build.php)
This text is intended to help you at least compile a few plugins by using GCC as included in the MinGW project instead of VC++. (Other free C++ compilers should work as well; Try Cygwin/GCC, for instance)
Compiler: This is the one tool you really need. The others are optional. Easiest way to get MinGW is to download their pre-compiled bundle (MinGW-3.0.0-1.exe). It contains the compiler gcc/g++ together with make and win32 headers.
CVS client: There are no recent .zip or .tar.gz packages with the K-Meleon source. You are expected to get the latest source out of the versioning system. Best is to use a CVS client for this. For Windows there is WinCvs which is part of the CvsGui project.
MinGW+MSYS: If you will use both MinGW and MSYS you can either first install msys as c:/msys and later mingw as c:/msys/mingw, or you can first install mingw as c:/mingw and, while instaling msys as c:/msys, tell the installation program where to find mingw. (other choices of directories are, of course, also possible)
MinGW: If you will only use MinGW you will have to setup your search %PATH% correctly. Something like:
will do. Make it a .bat file for the future.
If you are happy with coding for the latest release you can download the source from the Download page, otherwise you need to reach the CVS.
To get all source files out of the repository with WinCVS you first set up some preferences.
After that you can checkout the module "k-meleon" at a local folder of your choice (maybe c:/src).
You will have to write your own Makefile (or copy and modify an old). Use g++ to compile and dllwrap to turn it into a dll.