在 Xcode 3 中构建依赖项和静态库

发布于 2024-11-10 15:55:55 字数 949 浏览 5 评论 0原文

我正在尝试使用 XCode 3 获取 SoundCloud API 包装器的示例项目。有一些 开始时有一些基本说明,但我遇到了麻烦:

快速入门

在您的终端中:

  • git clone
  • git://github.com/soundcloud/cocoa-api-wrapper.git
  • SoundCloudAPI cd SoundCloudAPI git submodule update --recursive --init

在您的 Xcode 项目中:

  • 将 SoundCloudAPI.xcodeproj 拖到您的项目中,
  • 将其添加为构建依赖项,
  • 将静态库添加为 喜欢的目标
  • 添加“[相对路径 SoundCloudAPI]/来源/SoundCloudAPI” 到您的标头搜索路径 构建设置
  • 您还可以包括 通过添加 OAuth2Client 标头 “[相对路径 SoundCloudAPI]/Outsourced/OAuth2Client/Sources/OAuth2Client" 也是(虽然你可能不需要 他们)

我完全忽略了 In Your Xcode 项目之前的部分。我认为我已经正确完成了在这篇文章之后添加构建依赖项的所有操作,框架仍然标记为红色,就好像它们丢失了一样。有什么建议吗?

还有后面的三点也不是很清楚?有人可以更详细地解释一下这些吗?例如,标题搜索路径在哪里?构建设置在哪里?

非常感谢!

I'm trying to get the example project for an SoundCloud API wrapper working using XCode 3. There are some few basic instructions at the start, but I'm having trouble:

QuickStart

In your terminal:

  • git clone
  • git://github.com/soundcloud/cocoa-api-wrapper.git
  • SoundCloudAPI cd SoundCloudAPI git
    submodule update --recursive --init

In your Xcode project:

  • drag SoundCloudAPI.xcodeproj into your project
  • add it as a build dependency
  • add the static library as
    a liked target
  • add "[relative path to
    SoundCloudAPI]/Sources/SoundCloudAPI"
    to your header search path in the
    build settings
  • you can also include
    the OAuth2Client headers by adding
    "[relative path to
    SoundCloudAPI]/Outsourced/OAuth2Client/Sources/OAuth2Client"
    too (although you might not need
    them)

I've completely ignored the part before In Your Xcode project. I think I've done everything correctly to add the build dependency following this post, the frameworks are still marked in red as if they were missing. Any advice?

Also the three points after that are also not very clear? Could someone explain these in a bit more detail? For example, where is the header search path? and where are the build settings?

Thanks so much!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

何以笙箫默 2024-11-17 15:55:55

提示:鉴于您已使用 iphone 标记此问题,我假设您正在构建 iPhone 应用程序。在这种情况下,您需要添加 libSoundCloudAPI.a 作为直接依赖项,而不是 SoundCloudAPI.framework。

要在 Xcode 3 中设置标头搜索路径:

  1. 按住 Ctrl 键单击应用程序的目标(在左侧“组和文件”面板中的“目标”内),然后选择“获取信息”
  2. 单击“构建” /strong> 选项卡 - 这些是构建设置! :-)
  3. 将配置:设置为所有配置,显示:设置为所有设置
  4. 搜索路径部分中,更新标题搜索路径

Tip: Given that you've tagged this question with iphone, I'll assume you're building an iPhone app. In that case, you need to add libSoundCloudAPI.a as a direct dependency, but not SoundCloudAPI.framework.

To set the header search path in Xcode 3:

  1. Ctrl-click your app's target (inside Targets in the Group & Files panel on the left hand side) and choose Get Info
  2. Click the Build tab - these are the build settings! :-)
  3. Set Configuration: to All Configurations, Show: to All Settings
  4. In the Search Paths section, update Header Search Paths
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文