我正在尝试使用框架 SSZipArchive。我尝试通过 cocoaPods“安装”它(我无法成功),后来我尝试通过 Carthage。我以为第二个选项已经安装了它,但它没有。它给了我这个错误:
ld /Users/alumno/Library/Developer/Xcode/DerivedData/webR-enbsuevwixwhtweyjzzmrsectubh/Build/Products/Debug-iphonesimulator/webR.app/webR normal x86_64 cd /Users/alumno/Documents/iosProj/webR export IPHONEOS_DEPLOYMENT_TARGET=7.0 export PATH ="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/ bin:/bin:/usr/sbin:/sbin" /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer /Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator9.3。sdk -L/Users/alumno/Library/Developer/Xcode/DerivedData/webR-enbsuevwixwhtweyjzzmrsectubh/Build/Products/Debug-iphonesimulator -L/Users/alumno/Documents/iosProj/webR/Pods/GGLInstanceID/Libraries -L/Users/ alumno/Documents/iosProj/webR/Pods/Google/Libraries-L/Users/alumno/Documents/iosProj/webR/Pods/GoogleCloudMessaging/Libraries-L/Users/alumno/Documents/iosProj/webR/Pods/GoogleIPhoneUtilities/Libraries- L/Users/alumno/Documents/iosProj/webR/Pods/GoogleInterchangeUtilities/Libraries-L/Users/alumno/Documents/iosProj/webR/Pods/GoogleNetworkingUtilities/Libraries-L/Users/alumno/Documents/iosProj/webR/Pods/ GoogleSymbolUtilities/Libraries -L/Users/alumno/Documents/iosProj/webR/Pods/GoogleUtilities/Libraries -F/Users/alumno/Library/Developer/Xcode/DerivedData/webR-enbsuevwixwhtweyjzzmrsectubh/Build/Products/Debug-iphonesimulator-F/Users/alumno/Documents/iosProj/webR/Carthage/Build/iOS -filelist /Users/alumno/Library/Developer/Xcode/DerivedData/webR-enbsuevwixwhtweyjzzmrsectubh/Build/Intermediates/webR.build/Debug-iphonesimulator/webR .build/Objects-normal/x86_64/webR.LinkFileList -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -Xlinker -rpath -Xlinker @executable_path/Frameworks -mios-simulator-version-min =7。0 -Xlinker -no_deduplicate -Xlinker -objc_abi_version -Xlinker 2 -ObjC -lGGLCloudMessaging -lGGLCore -lGGLInstanceIDLib -lGIP_Locale -lGIP_Reachability -lGSDK_Overload_external -lGTMSessionFetcher_core_external -lGTMSessionFetcher_full_external -lGTMStackTrace_external -lGTM_AddressBook_external -lGTM_DebugUtils_external -lGTM_GTMURLBuilder_external -lGTM_KVO_external -lGTM_NSData+zlib -lGTM_NSDictionary+URLArguments_external -lGTM_NSScannerJSON_external -lGTM_NSStringHTML_external -lGTM_NSStringXML_external -lGTM_Regex_external -lGTM_RoundedRectPath_external -lGTM_StringEncoding_external -lGTM_SystemVersion_external -lGTM_UIFont+LineHeight_external -lGTM_core_external -lGTM_iPhone_external -lGcmLib -lProtocolBuffers_external -lsqlite3 -lstdc++ -lz -framework AddressBook -framework AssetsLibrary -framework CoreFoundation -framework CoreGraphics-framework CoreLocation -framework CoreMotion -framework MessageUI -framework SSZipArchive -framework Security -framework SystemConfiguration -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator -Xlinker -force_load -Xlinker /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_iphonesimulator.a -Xlinker -add_ast_path -Xlinker /Users/alumno/Library/Developer/Xcode/DerivedData/webR-enbsuevwixwhtweyjzzmrsectubh/Build /Intermediates/webR.build/Debug-iphonesimulator/webR.build/Objects-normal/x86_64/webR.swiftmodule -framework ZipArchive -Xlinker -dependency_info -Xlinker /Users/alumno/Library/Developer/Xcode/DerivedData/webR-enbsuevwixwhtweyjzzmrsectubh/构建/中间体/webR.build/Debug-iphonesimulator/webR。build/Objects-normal/x86_64/webR_dependency_info.dat -o /Users/alumno/Library/Developer/Xcode/DerivedData/webR-enbsuevwixwhtweyjzzmrsectubh/Build/Products/Debug-iphonesimulator/webR.app/webR
ld:未找到框架 SSZipArchive clang:错误:链接器命令失败,退出代码为 1(使用 -v 查看调用)
这些是我所做的步骤:
1- 创建 carpfile 并添加以下行:
github "ZipArchive/ZipArchive"
2-通过以下命令通过终端安装它:
carthage update --platform iOS
3-链接项目选项上的框架和库。
4- 在构建阶段运行脚本:
Shell: /bin/sh
/usr/local/bin/carthage copy-frameworks
Input Files: $(SRCROOT)/Carthage/Build/iOS/ZipArchive.framework
5-现在我可以正确使用导入,但是当我构建项目时,它给了我下面的错误。
编辑:你知道有什么工具可以解压支持 iOS 7 的下载数据吗?