updated to current version
updated for mingw