[英]Workspace does not build after pod install
I have two swift projects, application
and library
, where library
is a dependency of application
. 我有两个快速项目,
application
和library
,其中library
是application
的依赖项。 I have a Podfile
configured as so; 我已经配置了一个
Podfile
;
workspace 'myworkspace'
platform :ios, '9.0'
use_frameworks!
target :library do
project 'library/library.xcproject'
pod 'GCDWebServer', '~> 3.0'
target :application do
project 'application/application.xcproject'
end
end
After running pod install
successfully, I open myworkspace
in Xcode, and find application
as the currently selected scheme. 成功运行
pod install
后,我在Xcode中打开myworkspace
,并找到application
作为当前选定的方案。 Immediately building results in failure, due to; 由于以下原因,立即构建会导致失败:
No such module 'library'
没有这样的模块“库”
To solve this I need to change the current scheme to library
, build, then switch the scheme back to application
and it will successfully build. 为了解决这个问题,我需要将当前方案更改为
library
,build,然后将该方案切换回application
,它将成功构建。
Questions; 问题;
library
anytime library
source changes occur to reflect those changes in application
builds? library
源更改以反映application
构建中的更改时分别构建library
吗? Xcode 7.3, CocoaPods 1.0.1, repo 的Xcode 7.3的CocoaPods 1.0.1, 回购
Try do the followings: 请尝试执行以下操作:
1.Open the 'xxx.xcworkspace' file to run your project.
1.打开“ xxx.xcworkspace”文件以运行您的项目。 Do not open 'xxx.xcodeproj' to run your project again.
不要打开“ xxx.xcodeproj”再次运行您的项目。
2.Product->Clean->Run
2.产品->清洁->运行
3.Add all the pod targets to 'Linked Frameworks and Libraries' in Project -> General
3,将所有pod目标添加到Project-> General中的'Linked Frameworks and Libraries'
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.