Adding a framework to Xcode project


#1

I'm working on an app in Xcode and using the "Aubio" library framework. Each time I save my Jucer project I have to import it again. Is there a way of doing this in Introjucer or having the import persist when I open IntroJucer? 

 

Thanks 


#2

Just add the name in the "Extra Frameworks" field of the Xcode exporter.


#3

Thanks - I've been trying this however it does not seem to pick up the framework after the project is saved, it shows the framework in red as if it can't find it. Do I need to include a path in the list, or does the framework need to be registered elsewhere? 

 

 


#4

Works for me. Is this a system framework or an external one not located in the usual OSX SDK directory?

You're not adding the .framework extension are you?


#5

External one - "aubio".

Thanks for the clue, so put the framework in /Library/Frameworks...  is this where it should go? Still having the same issue. 

EDIT: Found the SDK folder ! Now works thank you :)


#6

I'm having the same problem including a 3rd party framework in an Introjucer project.  Where is this SDK folder that you mentioned?  It's the first I heard of their being a user local SDK folder...


#7

I had to do this again recently after upgrading to OSX 10.10.

Took me a while to find it again; it was in:

<User-home> / Applications ▸ Xcode.app ▸ Contents ▸ Developer ▸ Platforms ▸ MacOSX.platform ▸ Developer ▸ SDKs ▸ MacOSX10.10.sdk ▸ System ▸ Library ▸ Frameworks

 

 


#8

I've been having issues with adding a custom framework again.

I copy the framework into the SDK paths as in the previous post. After I save the project I can see the framework in the list in Xcode, and all looks good, however it gives an error on compile as if it can't find the framework. To get it working I have to delete the framework referenced in the SDK and reimport it from another location. Only then will it compile.

Any tips on what might be going on here?

I'm on Xcode 6.3.2


#9

I've not tried this but instead of adding the external library to the above directory you could try setting the FRAMEWORK_SEARCH_PATHS xcode flag. That way if you have the library along side the project (for example it could be a submodule of a git repo) you can probably supply the path relative to the xcode project and always have the project build without any setup and pain (in theory).


#10

That seems to have fixed the issue for me... strange though as I put the local version of the framework in FRAMEWORK_SEARCH_PATHS and the one that comes up in the Xcode project seems to point to the one I copied to the SDK folder. 

Thank you, this will save me time and releive of me of a minor hassle each time I save the Introjucer project. 

yes