Monday, March 14, 2011

Application not picking up changes in a static library

I recently wasted a lot of time, I was attempting to modify a class in a static library, and no matter what I did, it would NOT work.   Eventually I added some log statements and they didn't show up, although old ones did.

I found that when I made modifications to my static library the main application was not relinked.

For my WallPaperEdit application, I found that the main executable was WallPaperEdit in the directory

/Users/myusername/Library/Developer/Xcode/DerivedData/WallPaperEDit_randomLetters/Build/Products/Debug-iphonesimulator/WallPaperEdit.app

When I made a change in my static library, it was not being picked up for this, and it was not being relinked.  Even doing a clean did not work.

If I modify a file in my main library, then it recompiles and relinks this, and my new change is picked up.  I'm going to use that as a workaround for now, and then try and find the build setting that makes this behavior as it properly does.

While XCode4 says it supports automated dependencies between multiple projects, I've found that it can sometimes be painful.

No comments:

Post a Comment