• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Compiling for 10.9 through 10.12
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Compiling for 10.9 through 10.12


  • Subject: Re: Compiling for 10.9 through 10.12
  • From: Rich Siegel <email@hidden>
  • Date: Thu, 21 Jul 2016 09:45:37 -0400

On Thursday, July 21, 2016, Charles Francoise <email@hidden> wrote:

I’m trying to find a way to either build for 10.12 from 10.11, or build from 10.12 and run for lower versions.

There are two relevant settings: the SDK and the "Deployment Target". There used to be multiple options for the SDK, but lately Xcode has started putting the SDK and the OS version in lock step, so that Xcode 7 includes only the 10.11 SDK and (I presume) Xcode 8 includes only the 10.12 SDK. This can be annoying sometimes, but is not a serious problem in most cases.

The "Deployment Target" setting is more relevant here, I think. That setting should be set to the lowest OS version which you plan to support. (In this case, 10.9.)

Even with all of this, you still have to code to the minimum supported OS. If you have to run on 10.9, you can't call APIs that don't exist there. Neither the OS nor the tool chain will stop you from doing so.

In the specific case, I see that clock_gettime() doesn't exist on 10.11, which means it probably doesn't exist on prior OS versions either, and that means that you can't call it unless you do a runtime test to see if it's there. (The address of a weak-linked function is NULL if the function is unavailable at runtime.)

Good luck,

R.
--
Rich Siegel                                 Bare Bones Software, Inc.
<email@hidden>                      <http://www.barebones.com/>

Someday I'll look back on all this and laugh... until they sedate me.


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Follow-Ups:
    • Re: Compiling for 10.9 through 10.12
      • From: Charles Francoise <email@hidden>
  • Prev by Date: Re: where to get an example of list of countries and cities
  • Next by Date: Re: Compiling for 10.9 through 10.12
  • Previous by thread: Re: where to get an example of list of countries and cities
  • Next by thread: Re: Compiling for 10.9 through 10.12
  • Index(es):
    • Date
    • Thread