xcode 7 pods:找不到-lAFNetworking

时间:2016-05-05 16:43:55

标签: ios objective-c xcode cocoapods

我一直在尝试使用pod将Auth0集成到Telegram app一段时间(两者都是Objective-C项目)。

首先,我们将pod文件从Auth0复制到Telegram:

Auth0的podfile:

platform :ios, "8.0"

inhibit_all_warnings!

target "basic-sample" do
    pod "Lock", "~> 1.24"
    pod "Lock-Facebook", "~> 2.0"
    pod "JWTDecode", "~> 0.2.0"
    pod "SimpleKeychain", "~> 0.3"
    pod "MBProgressHUD", "~> 0.9"
end

复制到Telegram的podfile:

platform :ios, '8.0'
# use_frameworks!

target 'Telegraph' do
    pod "Lock", "~> 1.24"
    pod "Lock-Facebook", "~> 2.0"
    pod "JWTDecode", "~> 0.2.0"
    pod "SimpleKeychain", "~> 0.3"
    pod "MBProgressHUD", "~> 0.9"
end

target 'Share' do

end

target 'watchkitapp' do

end

target 'watchkitapp Extension' do

end

pod install后,我收到了这个废话警告:

[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `Share` to `Pods/Target Support Files/Pods-Share/Pods-Share.debug.xcconfig` or include the `Pods/Target Support Files/Pods-Share/Pods-Share.debug.xcconfig` in your build configuration.

[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `Share` to `Pods/Target Support Files/Pods-Share/Pods-Share.release.xcconfig` or include the `Pods/Target Support Files/Pods-Share/Pods-Share.release.xcconfig` in your build configuration.

[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `Telegraph` to `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.debug.xcconfig` or include the `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.debug.xcconfig` in your build configuration.

[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `Telegraph` to `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.release.xcconfig` or include the `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.release.xcconfig` in your build configuration.

[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `watchkitapp` to `Pods/Target Support Files/Pods-watchkitapp/Pods-watchkitapp.debug.xcconfig` or include the `Pods/Target Support Files/Pods-watchkitapp/Pods-watchkitapp.debug.xcconfig` in your build configuration.

[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `watchkitapp` to `Pods/Target Support Files/Pods-watchkitapp/Pods-watchkitapp.release.xcconfig` or include the `Pods/Target Support Files/Pods-watchkitapp/Pods-watchkitapp.release.xcconfig` in your build configuration.

[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `watchkitapp Extension` to `Pods/Target Support Files/Pods-watchkitapp Extension/Pods-watchkitapp Extension.debug.xcconfig` or include the `Pods/Target Support Files/Pods-watchkitapp Extension/Pods-watchkitapp Extension.debug.xcconfig` in your build configuration.

[!] CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target `watchkitapp Extension` to `Pods/Target Support Files/Pods-watchkitapp Extension/Pods-watchkitapp Extension.release.xcconfig` or include the `Pods/Target Support Files/Pods-watchkitapp Extension/Pods-watchkitapp Extension.release.xcconfig` in your build configuration.

[!] The `Telegraph [Debug]` target overrides the `HEADER_SEARCH_PATHS` build setting defined in `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.debug.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `Telegraph [Debug]` target overrides the `OTHER_CFLAGS` build setting defined in `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.debug.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `Telegraph [Debug]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.debug.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `Telegraph [Release]` target overrides the `HEADER_SEARCH_PATHS` build setting defined in `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `Telegraph [Release]` target overrides the `GCC_PREPROCESSOR_DEFINITIONS` build setting defined in `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `Telegraph [Release]` target overrides the `OTHER_CFLAGS` build setting defined in `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `Telegraph [Release]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods-Telegraph/Pods-Telegraph.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `Share [Debug]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods-Share/Pods-Share.debug.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `Share [Release]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods-Share/Pods-Share.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `watchkitapp Extension [Debug]` target overrides the `HEADER_SEARCH_PATHS` build setting defined in `Pods/Target Support Files/Pods-watchkitapp Extension/Pods-watchkitapp Extension.debug.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `watchkitapp Extension [Debug]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods-watchkitapp Extension/Pods-watchkitapp Extension.debug.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `watchkitapp Extension [Release]` target overrides the `HEADER_SEARCH_PATHS` build setting defined in `Pods/Target Support Files/Pods-watchkitapp Extension/Pods-watchkitapp Extension.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

[!] The `watchkitapp Extension [Release]` target overrides the `OTHER_LDFLAGS` build setting defined in `Pods/Target Support Files/Pods-watchkitapp Extension/Pods-watchkitapp Extension.release.xcconfig'. This can lead to problems with the CocoaPods installation
    - Use the `$(inherited)` flag, or
    - Remove the build settings from the target.

我也在Xcode中得到了我无法解决的错误(缺少目录)。

在尝试解决这些问题之后,我遇到了this answer,它告诉我将$(inherited)添加到我的其他链接器标志中。而且我这样做了:

enter image description here

值得注意的是,'Share'目标还有一个额外的链接器标志lc++。我向所有目标添加了$(inherited)

然后我收到此错误:

  

ld:找不到-lAFNetworking clang的库:错误:链接器命令

     退出代码1

失败(使用-v查看调用)

我添加了-l“AFNetworking”,但这并未改变任何内容。

还有什么我可以尝试的吗?是的,我正在使用.xcworkspace应用程序。

0 个答案:

没有答案