开发者

Can't create Archive with Static Library

开发者 https://www.devze.com 2023-03-30 06:33 出处:网络
I\'m trying to create a archive for a app linking to a static library but with no luck. I can built the app in both release and debug mode just fine. I can even built it for Archiv开发者_如何学编程e

I'm trying to create a archive for a app linking to a static library but with no luck.

I can built the app in both release and debug mode just fine. I can even built it for Archiv开发者_如何学编程e (product->built for->archiving) but it fails miserably when I try to create the archive (products->Archive)

XCode can't seem to find the headers for the Static lib:

In file included from /Data/Code/iPhoneDev/ArchiveTest/ArchiveTestApp/ArchiveTestApp/ArchiveTestAppAppDelegate.m:9:
    /Data/Code/iPhoneDev/ArchiveTest/ArchiveTestApp/ArchiveTestApp/ArchiveTestAppAppDelegate.h:10:24: error: DataFetcher.h: No such file or directory
    In file included from /Data/Code/iPhoneDev/ArchiveTest/ArchiveTestApp/ArchiveTestApp/ArchiveTestAppAppDelegate.m:9:
    /Data/Code/iPhoneDev/ArchiveTest/ArchiveTestApp/ArchiveTestApp/ArchiveTestAppAppDelegate.h:13: error: cannot find protocol declaration for 'DataFetcherDelegate'

Any ideas or suggestions on what I'm missing here?


I ended up roughly following the suggestions in this Questions:

Compile, Build or Archive problems with Xcode 4 (and dependencies)

  1. Create a group call "Indexing headers" in your project and drag the headers to this group, DO NOT add to any targets when prompted. This includes any headers inside your dependency

  2. For all dependancies set "Skip Install" build setting to "Yes"

  3. Moving any "Public" headers in Build Phases to "Project" for dependency

  4. Set the Build Setting "Installation Directory" on your Target to $(LOCAL_APPS_DIR)

The archive was created with no errors with step 1-3, but for it to become a valid app step 4) was needed.

Amazing how half baked XCode4 seems

0

精彩评论

暂无评论...
验证码 换一张
取 消