Pods 更新后提示Bundle资源找不到
- 当前Podfile运行正常
rubytekiMacBook-Pro:DecorationBus ruby$ cat Podfile platform :ios, '7.0' pod 'MWPhotoBrowser', '~> 2.1.1' pod 'UMengAnalytics-NO-IDFA', '~> 3.4.7' pod 'MJRefresh', '~> 3.0.4' pod 'MDRadialProgress', '~> 1.3.2' pod 'MOBFoundation_IDFA', '~> 1.3.1' pod 'SMSSDK', '~> 2.0.0'
- 升级Pod到1.0.0.beta.4
rubytekiMacBook-Pro:DecorationBus ruby$ pod --version 1.0.0.beta.4
- 更新Pod资源(由于Pods升级,引入了target的概念,必须在Podfile中指定target, 此步必失败)
rubytekiMacBook-Pro:DecorationBus ruby$ pod install Re-creating CocoaPods due to major version update. Updating local specs repositories CocoaPods 1.0.0.beta.6 is available. To update use: `sudo gem install cocoapods --pre` [!] This is a test version we'd love you to try. For more information, see https://blog.cocoapods.org and the CHANGELOG for this version at https://github.com/CocoaPods/CocoaPods/releases/tag/1.0.0.beta.6 Analyzing dependencies [!] The dependency `MWPhotoBrowser (~> 2.1.1)` is not used in any concrete target. The dependency `UMengAnalytics-NO-IDFA (~> 3.4.7)` is not used in any concrete target. The dependency `MJRefresh (~> 3.0.4)` is not used in any concrete target. The dependency `MDRadialProgress (~> 1.3.2)` is not used in any concrete target. The dependency `MOBFoundation_IDFA (~> 1.3.1)` is not used in any concrete target. The dependency `SMSSDK (~> 2.0.0)` is not used in any concrete target.
- 按照官方guide修改Podfile
rubytekiMacBook-Pro:DecorationBus ruby$ cat Podfile platform :ios, '7.0' target 'DecorationBus' do pod 'MWPhotoBrowser', '~> 2.1.1' pod 'UMengAnalytics-NO-IDFA', '~> 3.4.7' pod 'MJRefresh', '~> 3.0.4' pod 'MDRadialProgress', '~> 1.3.2' pod 'MOBFoundation_IDFA', '~> 1.3.1' pod 'SMSSDK', '~> 2.0.0' end
- 更新Pods
rubytekiMacBook-Pro:DecorationBus ruby$ pod update Update all pods Re-creating CocoaPods due to major version update. Updating local specs repositories CocoaPods 1.0.0.beta.6 is available. To update use: `sudo gem install cocoapods --pre` [!] This is a test version we'd love you to try. For more information, see https://blog.cocoapods.org and the CHANGELOG for this version at https://github.com/CocoaPods/CocoaPods/releases/tag/1.0.0.beta.6 Analyzing dependencies Downloading dependencies Installing DACircularProgress (2.3.1) Installing MBProgressHUD (0.9.2) Installing MDRadialProgress (1.3.2) Installing MJRefresh (3.0.8) Installing MOBFoundation_IDFA (1.3.1) Installing MWPhotoBrowser (2.1.1) Installing SDWebImage (3.7.5) Installing SMSSDK (2.0.4) Installing UMengAnalytics-NO-IDFA (3.4.7) Generating Pods project Integrating client project Sending stats Pod installation complete! There are 6 dependencies from the Podfile and 9 total pods installed.
- 编包提示MWPhotoBrowser.bundle找不到
PhaseScriptExecution Copy Pods Resources /Users/ruby/Library/Developer/Xcode/DerivedData/DecorationBus-ewahmhbzzgyytwefamtwlzktzjpt/Build/Intermediates/DecorationBus.build/Debug-iphonesimulator/DecorationBus.build/Script-1B153D9A39078434770F20CE.sh cd /Users/ruby/horen/gitHub/DecorationBus /bin/sh -c /Users/ruby/Library/Developer/Xcode/DerivedData/DecorationBus-ewahmhbzzgyytwefamtwlzktzjpt/Build/Intermediates/DecorationBus.build/Debug-iphonesimulator/DecorationBus.build/Script-1B153D9A39078434770F20CE.sh /Users/ruby/horen/gitHub/DecorationBus/Pods/MJRefresh/MJRefresh/MJRefresh.bundle /Users/ruby/horen/gitHub/DecorationBus/Pods/SMSSDK/SMSSDKUI.bundle error: Resource "/Users/ruby/Library/Developer/Xcode/DerivedData/DecorationBus-ewahmhbzzgyytwefamtwlzktzjpt/Build/Products/Debug-iphonesimulator/MWPhotoBrowser.bundle" not found. Run 'pod install' to update the copy resources script.
- 按照指示再次”pod install“, 问题依然存在
有朋友提示,怀疑是我使用的beta版pods的缘故,正在尝试降级。有结果回来更新.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(6)
请问我的项目不是swift项目也出现这个问题,是什么原因?
1.use_frameworks!
如果是swift项目,则必须写这句
-》旧的ObjectC的项目,不需要写这句
2.target 'DecorationBus' do 中的DecorationBus
是你的项目的名字。
target '这是是项目的target名称 再简单点就是项目名称 但是不一定' do
回复
更准确的说应该是target名称。一个项目中可以有多个target。
想问下:下面的“DecorationBus”是什么呀?
platform :ios, '8.0'
use_frameworks!
target 'DecorationBus' do
pod 'MWPhotoBrowser', '~> 2.1.1'
pod 'UMengAnalytics-NO-IDFA', '~> 3.4.7'
pod 'MJRefresh', '~> 3.0.4'
pod 'MDRadialProgress', '~> 1.3.2'
pod 'MOBFoundation_IDFA', '~> 1.5.1'
pod 'SMSSDK', '~> 2.0.4'
pod 'KMPlaceholderTextView', '~> 1.1.2'
end
自己回来结贴。更新Podfile
rubytekiMacBook-Pro:DecorationBus ruby$ cat Podfile
platform :ios, '8.0'
use_frameworks!
target 'DecorationBus' do
pod 'MWPhotoBrowser', '~> 2.1.1'
pod 'UMengAnalytics-NO-IDFA', '~> 3.4.7'
pod 'MJRefresh', '~> 3.0.4'
pod 'MDRadialProgress', '~> 1.3.2'
pod 'MOBFoundation_IDFA', '~> 1.5.1'
pod 'SMSSDK', '~> 2.0.4'
pod 'KMPlaceholderTextView', '~> 1.1.2'
end
注意标红色的必填!