gpt4 book ai didi

ios - Xcode:安装框架时链接器命令错误

转载 作者:行者123 更新时间:2023-11-29 11:59:00 24 4
gpt4 key购买 nike

我正在尝试使用 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/Build/Intermediates/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: framework not found SSZipArchive clang: error: linker command failed with exit code 1 (use -v to see invocation)

这些是我做的步骤:

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 的解压缩下载数据的工具吗?

最佳答案

终于成功了!我只是不知道我必须在构建阶段指定必须复制的文件(框架)。我会把它的屏幕截图借给你,也许对某人有帮助。

Screenshoot

关于ios - Xcode:安装框架时链接器命令错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37831996/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com