使用 iphonesimulator gcc 4.2 构建 Mac 目标
在混合 3.2.5 iOS/MacOS 项目中,有一个现有的 iOS 静态库目标,我正在添加一个 MacOS 静态库。在目标构建设置(所有配置)中,我
- 将 Base SDK 设置为“Latest Mac OS X”,
- 将 Architectures 设置为 $(NATIVE_ARCH),
- 将 Valid Architectures 设置为 i386 仅
- 使用我自己的 PCH 文件
- 将标头拖到 Copy Headers,Mac 目标
- 将源拖到编译源,Mac 目标
- 添加在 /System/Library/Frameworks/Foundation.framework 中找到的 Foundation.framework,将其设置为新的 Mac 目标
(/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.2.sdk/System/Library/Frameworks/Foundation.framework 也存在,但设置为 iOS 目标静态库)
目标编译但产品显示不在“调试”中,但在“调试-iphonesimulator”中。我假设这是链接到 iOS 基金会?无论它在做什么,我都不能认为这是安全的。
改变我添加东西的顺序似乎没有效果。
有什么建议吗?
In a Mixed 3.2.5 iOS/MacOS project, there is an existing iOS static library target, and I'm adding a MacOS static library. In the target build settings(all configurations) I
- set the Base SDK to "Latest Mac OS X"
- set Architectures to $(NATIVE_ARCH)
- set Valid Architectures to i386 only
- use my own PCH file
- drag headers into Copy Headers, Mac target
- drag source into Compile Sources, Mac target
- add the Foundation.framework found at /System/Library/Frameworks/Foundation.framework, set it to the new Mac target
(/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.2.sdk/System/Library/Frameworks/Foundation.framework is also present, but set to the iOS target static lib)
the target compiles but the product appears NOT in "Debug" but in "Debug-iphonesimulator" instead. I'm assuming this is linking to the iOS Foundation? Whatever it's doing I can't assume that's safe.
changing the order of how I add things seems to have no effect.
any suggestions?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我建议升级到 Xcode 4。我有构建 Mac 和 iOS 库的项目,并且都按预期工作。
I suggest upgrading to Xcode 4. I have projects that build Mac and iOS libraries and both work as expected.