CMake fixes

Hi,

I add to make CMake fixes so as to compile under OSX 10.6+.

Included as well is a temporary solution to be able to compile everything when OpenCV isn't compiled against Qt. This should be ideally tested within the CMake integration.

Would you mind considering these points?

Best regards,
Christian