pod》error:The dependency `` is not used in any concrete target

weixin_34253539發表於2016-06-26

內容提要:

podfile升級之後到最新版本,pod裡的內容必須明確指出所用第三方庫的target,否則會出現The dependency `` is not used in any concrete target這樣的錯誤。

以下從三個步驟陳述:

1. Podfile升級

檢視pod版本:

pod --version

pod 升級(此時是升級到1.0.0.beta.2版本):

sudo gem install cocoapods --pre

2. 錯誤內容:

我的Podfile的內容是:

platform :ios, '7.0'

pod 'ReactiveCocoa', '2.1.8'

pod 'objectiveflickr', '2.0.4'

pod 'LinqToObjectiveC', '2.0.0'

pod 'SDWebImage', '3.6'

pod install後出現錯誤The dependency `` is not used in any concrete target

複製程式碼

pod install

/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/universal-darwin14/rbconfig.rb:213: warning: Insecure world writable dir /Applications/Cocos/tools/ant/bin in PATH, mode 040777

Re-creating CocoaPods due to major version update.

Updating local specs repositories

Analyzing dependencies

[!] The dependency `ReactiveCocoa (= 2.1.8)` is not used in any concrete target.

The dependency `objectiveflickr (= 2.0.4)` is not used in any concrete target.

The dependency `LinqToObjectiveC (= 2.0.0)` is not used in any concrete target.

The dependency `SDWebImage (= 3.6)` is not used in any concrete target.

複製程式碼

3. 修改方法:

Podfile內容更改:

複製程式碼

platform :ios, '7.0'

target "RWTFlickrSearch" do

pod 'ReactiveCocoa', '2.1.8'

pod 'objectiveflickr', '2.0.4'

pod 'LinqToObjectiveC', '2.0.0'

pod 'SDWebImage', '3.6'

end

複製程式碼

這樣再執行pod install,就會成功了。

相關文章