Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Linking a framework depending on 'Build' or 'Debug' mode in Xcode5?

I am building a Mac app using Xcode5 on 10.9.2. My project uses a third party framework -- for the sake of simplicity, let's call it XYZ.framework.

There are two versions of XYZ.framework provided: a debug version and a release version. The debug version of the framework is considerably larger, but it carries important functionality for debugging like printing warnings to the console, asserts, etc. The release version of the framework is smaller, faster, and is intended for production. The debug version resides at debug/XYZ.framework and the release version resides at release/XYZ.framework.

My question is: How do I include the correct version of the framework depending on my build configuration? I.E., Xcode should include debug/XYZ.framework when my build configuration is Debug, or include release/XYZ.framework when my build configuration is Release.

like image 639
jerzy Avatar asked Jun 10 '14 20:06

jerzy


1 Answers

One possibility is,create separate folder to keep the debug version of framework and release version of framework. Next step specify the framework search path according to build configuration. Below is the steps to customise framework search path:

  1. Go to build settings.
  2. Search for "framework search paths" in build settings.
  3. Edit framework search path according to your configuration.

Additionally this thread may also help you.

like image 78
Raviprakash Avatar answered Oct 26 '22 15:10

Raviprakash