Fix apple build.

The apple build was broken because the elseif in the CMakeLists is never triggered.

Some code was not properly adapted for the new qtmacgoodies.

Some paths were not adapted to new split.
Merge pull request #2194 from tim-vandecasteele/fix-apple-build

Fix apple build.