0
我已经通过CocoaPods将Tesseract iOS库添加到我的Swift项目中,但是我想关闭模拟器上的开发代码签名。我已经在项目和我的目标上添加了“不要签名”,但构建仍然有一个代码签名步骤。我的Podfile中还有一些代码试图关闭代码签名。如何关闭使用CocoaPods在第三方iOS框架上的代码签名?
在生成日志,我看到
Code Signing /Users/ME/Library/Developer/Xcode/DerivedData/PROJECT-fchynlbfcpjfbcfaplehdrryfpqn/Build/Products/Debug-iphonesimulator/PROJECT.app/Frameworks/TesseractOCR.framework with Identity -
/usr/bin/codesign --force --sign - --preserve-metadata=identifier,entitlements "/Users/ME/Library/Developer/Xcode/DerivedData/PROJECT-fchynlbfcpjfbcfaplehdrryfpqn/Build/Products/Debug-iphonesimulator/PROJECT.app/Frameworks/TesseractOCR.framework"
的podfile看起来是这样的:
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
target 'PROJECT' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
pod 'TesseractOCRiOS', :git => "[email protected]:gali8/Tesseract-OCR-iOS.git"
target 'PROJECTTests' do
inherit! :search_paths
# Pods for testing
end
end
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['EXPANDED_CODE_SIGN_IDENTITY'] = ""
config.build_settings['CODE_SIGNING_REQUIRED'] = "NO"
config.build_settings['CODE_SIGNING_ALLOWED'] = "NO"
end
end
end
你确定你试图在模拟器或iPhone上运行吗?你不需要对你的项目进行代码签名。如果你在模拟器中运行.code签名只需要当你在device.i中测试你的项目时,我假设你使用Xcode 8.如果是,你必须手动为代码签名你的pod项目。苹果政策在Swift 3中改变了。当你使用豆荚时)。希望这有助于... – Joe
谢谢,乔。是的,它是Xcode 8和模拟器。它也是Swift的最新版本,正如我所提到的那样,我使用了pod。我也认为模拟器不需要代码签名,但我想我的Tesseract框架依赖性可能会强制它?这可能吗?如果是这样,我该如何关闭它? – karansag
检查我的帖子。它可能会给你一个提示http://stackoverflow.com/questions/39945377/no-code-signature-found-after-pod-installed-in-xcode-8 – Joe