Cocoapods 1.3.1 + XPC服务

时间:2017-11-24 07:12:39

标签: cocoapods xpc

在版本1.2.1之前,XPC服务目标在cocoapods上运行良好,但是在更新到1.3.1时,我收到以下错误:

[!] Unable to find host target(s) for Renderer. Please add the host targets for the embedded targets to the Podfile. Certain kinds of targets require a host target. A host target is a "parent" target which embeds a "child" target. These are example types of targets that need a host target: - Framework - App Extension - Watch OS 1 Extension - Messages Extension (except when used with a Messages Application)

相关的podspec线是:

target 'Renderer' do project 'Renderer/Renderer.xcodeproj' platform :osx, '10.10' pod 'HTMLKit', :git => 'https://github.com/iabudiab/HTMLKit.git' end

有什么建议吗?

我尝试将此目标作为我主要目标的孩子,但这并不起作用。

1 个答案:

答案 0 :(得分:0)

如前所述:https://github.com/CocoaPods/CocoaPods/issues/6256,您需要将XPC服务指定为主项目中的目标依赖项。