Q:

Compiling and linking library MSVC/MingW

I'm a big fan of StackOverflow because you always have answers for problems, and now is my chance to get advance of it Ö! 
I'm trying to use a library which I got in the Internet, its OZCollide.  Its suppossed to be crossplatform as it says in its website "Cross-platform, works on Windows, Linux and Macintosh, in fact any platform supporting VisualStudio 6/7 or gcc"
I got all the .h and .cpp, compile them with MinGW as objects (.o) and then link them all using ar.  But the problem is when I include and use the library on my project (QT & MinGW) it throws "undefined reference". 
I thought the problem could be that library examples only uses Visual Studio, so the library coulnd't be compiled for MinGW, but the website tells other story. 
Thanks for your time! 

EDIT: Okay I have managed to compile it and use it moving to another computer and compiling makefile.  The only one difference is that Computer A had Cygwing and MinGW installed (with Cygwin set up in Windows path) and Computer B only had MinGW. 
So I guess the problem was Makefile calling for g++ and Cygwin g++ got called instead of MinGW g++?? 
If I'm right, whats the difference between Cygwin and MinGW? 

A:

if you have experience with CMake, create your own CMakeLists file and import/link this libraries against your project.  In this way, you can create projects for MinGW/MSVC/Linux/etc. 
Here you'll find a good start with CMake http://www.cmake.org/cmake-tutorial/

