CocoaPods错误pod安装HEADER_SEARCH_PATHS

时间:2014-11-05 05:48:40

标签: ios xcode xcode6 cocoapods

首次涉足CocoaPods(我对此并不满意!)。我按照所有说明进行操作。当我做pod install这就是我得到的:

  

分析依赖关系
  下载依赖关系
使用AFNetworking(2.4.1)
使用Braintree   (3.4.0)
生成Pods项目集成客户端项目

     

[!] MyProject [Debug]目标会覆盖。{   HEADER_SEARCH_PATHS $(继承)`标志中定义的Pods/Target Support Files/Pods-MyProject/Pods-MyProject.debug.xcconfig'. This can lead to problems with the CocoaPods installation - Use the构建设置,或者        - 从目标中删除构建设置。

     

[!] MyProject [Debug]目标会覆盖OTHER_LDFLAGS   在Pods/Target Support Files/Pods-MyProject/Pods-MyProject.debug.xcconfig'. This can lead to problems with the CocoaPods installation - Use the $(继承)`标志或
中定义的构建设置        - 从目标中删除构建设置。

     

[!] MyProject [Release]目标会覆盖。{   HEADER_SEARCH_PATHS $(继承)`标志中定义的Pods/Target Support Files/Pods-MyProject/Pods-MyProject.release.xcconfig'. This can lead to problems with the CocoaPods installation - Use the构建设置,或者        - 从目标中删除构建设置。

     

[!] MyProject [Release]目标会覆盖OTHER_LDFLAGS   在Pods/Target Support Files/Pods-MyProject/Pods-MyProject.release.xcconfig'. This can lead to problems with the CocoaPods installation - Use the $(继承)`标志或
中定义的构建设置        - 从目标中删除构建设置。

这是我的Podfile:

  

来源'https://github.com/CocoaPods/Specs.git'

     

目标'ActivFocus'确实           pod'Braintree'#Over:pod'Braintree','〜> 3.0.0'
          pod“AFNetworking”,“〜> 2.0”
结束
  
  目标'ActivFocusTests'做           pod'Braintree'#Over:pod'Braintree','〜> 3.0.0'
          pod“AFNetworking”,“〜> 2.0”
结束

我不知道如何遵循这个建议:

- Use the '$(inherited)' flag, or
- Remove the build settings from the target.

编辑:这是我在尝试构建项目时得到的Xcode错误:

  

Ld的   /Users/randy/Library/Developer/Xcode/DerivedData/MyProject-epuhpnvywesozcamslrdbksivzae/Build/Products/Debug-iphonesimulator/MyProject.app/MyProject   正常的i386       cd / Users / randy / Development / MyProject / iOSApp / MyProject       export IPHONEOS_DEPLOYMENT_TARGET = 7.1       export PATH =“/ Applications / Xcode.app / Contents / Developer / Platforms / iPhoneSimulator.platform / Developer / usr / bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/ usr / bin:/ bin: / usr / sbin目录:/ sbin目录”       /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang   -arch i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.1.sdk   -L /用户/兰迪/库/开发商/ Xcode中/ DerivedData / MyProject的-epuhpnvywesozcamslrdbksivzae /编译/产品/调试,iphonesimulator   -L /用户/兰迪/开发/ MyProject的/ iOSApp / MyProject的/荚/布伦特里/布伦特里/贝宝/ MSDK   -L / Users / randy / Development / MyProject / iOSApp / MyProject -L / Users / randy / Development / MyProject / iOSApp / MyProject / MyProject / libs / ios_libs / simplify / vendor / ocmock   -F /用户/兰迪/库/开发商/ Xcode中/ DerivedData / MyProject的-epuhpnvywesozcamslrdbksivzae /编译/产品/调试,iphonesimulator   -F /用户/好色/开发/ MyProject的/ iOSApp / MyProject的/ MyProject的/库/ ios_libs /简化   -F / Users / randy / Development / MyProject / iOSApp / MyProject / MyProject -F / Users / randy / Development / MyProject / iOSApp / MyProject -filelist / Users / randy / Library / Developer / Xcode / DerivedData / MyProject-epuhpnvywesozcamslrdbksivzae / Build /Intermediates/MyProject.build/Debug-iphonesimulator/MyProject.build/Objects-normal/i386/MyProject.LinkFileList   -Xlinker -objc_abi_version -Xlinker 2 -ObjC -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min = 7.1 -framework AVFoundation -framework CoreData -framework QuartzCore -framework MediaPlayer -framework   CoreGraphics -framework UIKit -framework Foundation -lPods-MyProject   -Xlinker -dependency_info -Xlinker /Users/randy/Library/Developer/Xcode/DerivedData/MyProject-epuhpnvywesozcamslrdbksivzae/Build/Intermediates/MyProject.build/Debug-iphonesimulator/MyProject.build/Objects-normal/i386/MyProject_dependency_info.dat   -o /Users/randy/Library/Developer/Xcode/DerivedData/MyProject-epuhpnvywesozcamslrdbksivzae/Build/Products/Debug-iphonesimulator/MyProject.app/MyProject

     

ld:找不到-lPods-ActivFocus clang的库:错误:链接器
  命令失败,退出代码为1(使用-v查看调用)

1 个答案:

答案 0 :(得分:5)

如果标题搜索路径没有手动覆盖,请尝试删除添加到项目中的pod配置文件。这可以在YourProject\Pods找到(而不是在pods项目中,请查看图像)。尝试再次运行pod安装并检查。

Pod Config File

如果您手动添加了标题路径,请忽略该警告并在搜索路径中添加一个继承的标志,如下所示

Inherited Flag to the header search path