Fix path to OSX SDK with XCode >=4.3
Disable PIC on MinGW to reduce warnings
Use long long for pointers instead of long to avoid truncation on 64-bit Windows