Nidhoegger
Nidhoegger

Reputation: 5232

Compile for Mac 10.9 under 10.11

We want our software to support OSX Versions down to 10.9. In XCode you can set the target version, that is no problem, but we have another lib that gets linked in the projekt which is built using cmake. Now XCode complains that the lib is build for 10.11, but our project is 10.9. Can I somehow tell clang on the command line to compile for an older version?

The only information I have found is to set OSX_VERSION as variable, but it seems to have no effect.

Thanks in advance!

Upvotes: 3

Views: 1269

Answers (1)

Flash Sheridan
Flash Sheridan

Reputation: 1689

From clang --help:

-mmacosx-version-min=<value>
                      Set Mac OS X deployment target

Do be on the lookout for gotchas with earlier deployment targets, and make sure you test all the OS versions you support.

Upvotes: 6

Related Questions