Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

strange linking issue: the dependent framework won't be linked into app after modification #32

Open
leoncheng opened this Issue · 2 comments

3 participants

@leoncheng

Hi, Karl

Firstly, thanks for your great job. but when I thought every thing was fine and perfect, I found a little problem.

I created two projects A and B. A is an app project which depends on B framework project.
as your solution, I add -framework B in A project, and it works fine, but not perfect. after I modified B project,
the A.app won't link the updated B.framework again. Unless I deleted the B.framework and generate it again.

so, it seems that the linker only use the framework's creation time to decide if re-linking, but not the framework's modified time.
it's really annoy. I haven't found any good solution for this except add delete operation in the pre-build action.
Do you have any good solution for this?

Thanks
Leon

@kstenerud
Owner

Hmm yeah I tried it and am getting the same thing. It looks like Xcode isn't checking subprojects properly. I was able to get it to recognize the change by doing a clean first and then a rebuild.

Unfortunately, this looks like an Xcode problem. I don't think I can change anything in the template to mitigate the problem.

@kemenaran

I (finally !) found a way to fix this issue.

The trick is to ensure that all file references to the Framework file are relative to the Built products directory.

In the above example, that would mean opening the project A, find the reference to B.framework, and change its path to be relative to the built products. Ideally, the path should display the least slashes as possible: it should be a raw name.

I took the informations from this article, which gives a lot of clues to solve this kind of issues : http://www.kihongames.com/blog/labs/2011/06/labs-xcode-static-library-pitfalls/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.