在 Xcode4 项目中包含 C 工具
我有一个项目构建两个目标,主应用程序和工具。
如何正确将该工具包含在应用程序包中?我已经导航到目标依赖项并添加了该工具;但是,当将构建的可执行文件添加到“复制捆绑资源”阶段时,我得到了构建产品的路径,例如:
.../.../awieuhfaowasldijfsalkdj/Build/Debug/tool
是否有任何方法可以动态地将工具添加到捆绑包中,我的意思是无需对此类路径进行硬编码?理想情况下,我想将该工具添加到“资源”捆绑文件夹内的一个特殊文件夹(例如“工具”)中,但我什至不知道这是否可能。
除此之外,我还需要做些什么才能完成将其添加为资源的过程吗?
I have a project which builds two targets, the main app and a tool.
How can I correctly include the tool in the app bundle? I have already navigated to target dependencies and added the tool; however when adding the built executable to the "Copy Bundle Resources" phase, I get a path to the builded product like:
.../.../awieuhfaowasldijfsalkdj/Build/Debug/tool
Is there any way to add the tool to the bundle dynamically, I mean without hardcoding such path? Ideally, I'd like to add the tool in a special folder (say "Tools") inside the "Resources" bundle folder, but I don't even know if that's possible.
Apart from this, is there something else I need to do in order to complete the process of adding it as a resource?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
避免奇怪路径的一种简单方法是指定构建位置应该是目标指定的位置(默认情况下项目下的
build/Debug
或build/Release
文件夹):One simple way to avoid the weird path is to specify that the build location should be the one specified by the targets (by default
build/Debug
orbuild/Release
under the project folder):