fix the build to be version independent on Mac OSX