This may be an issue with GCC or MingW, I'm not sure, but I got the following error:
undefined reference to `MonitorFromPoint@12'
I was able to fix it by following the instructions from this link:
http://www.freebasic.net/forum/viewtopic.php?p=116178