Compile CPU mining for win32 and win64

enable CPU mining for windows platforms, and test on win7/8+mingw32, win7/8+mingw-w64 and ubuntu 64bit.