Re: per-project dependent project build settings
Re: per-project dependent project build settings
- Subject: Re: per-project dependent project build settings
- From: Damian Carrillo <email@hidden>
- Date: Sun, 13 Apr 2014 08:47:40 -0500
Try this:
Add a new build configuration by selecting your project in the Project Navigator, selecting your project again under PROJECT, and then selecting the Info tab.
Select your static library target under TARGETS, and then select OS X Deployment target under the Deployment section of the target’s Build Settings.
Duplicate the scheme you use to build the library when you target OS X 10.9, but set it to use the build configuration that you just added.
Since you will have diverged from Release and Debug build configurations at this point, you may have to repeat the steps in the parent project in order to have the active build settings propagate down. You could also just build your static libraries - one that targets 10.7 and one that targets 10.9 - and then from the application’s project add the library’s headers to the Header Search Path, and then just link the binary with your static library. That way you don’t need to worry about the rigmarole of having all of your settings line up all the way down.
On Apr 13, 2014, at 6:39 AM, Roland King <email@hidden> wrote:
> I have a huge library I've built up over time containing all my fun bits of code. That's in its own project. When I want to use the library I add the xcodeproj file into the project I want to use it in, set up a few build variables and make it a dependency and everything is fine. This is a static library, I started using it for iOS originally so static it has stayed. The final binary just links in whatever bits it needed.
>
> The library project is set to build to 'latest OSX', so currently 10.9, with a Deployment Target default, so again 10.9.
>
> I have a project I want to use the library for which needs to build with a Deployment Target of 10.7. I've imported the library project in the usual way and set all the target deployment stuff to 10.7 however the library dependency is still building with its own settings, of 10.9, which means it uses _objc_setProperty_atomic which then fails deployed on 10.7.
>
> Is there a way I can get the library project to build with a different Deployment Target in this one overall project? It's building its own copy of the library in the project build directory, not like it needs to share it with any other piece of code. I obviously don't want to change the deployment target of the library in the library project as that changes it for everyone, nor do I want to keep toggling it up and down when I build different projects.
>
> I could add a separate target, library_10_7 but that seems really hokey and unscalable. I poked around with Workspaces a bit but that didn't seem to offer more options and indeed projects there sit side-by-side with each other as top-level objects, at least in the current case the library project is 'inside' the outer one which gave me so home the 'outer' project settings could be forced into the dependencies.
>
> Any way I can do this?
>
> _______________________________________________
> 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
_______________________________________________
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