2016-06-15 61 views
1

我正在嘗試使用框架SSZipArchive。我試圖通過cocoaPods「安裝」它(我無法做到),後來,我通過迦太基嘗試。我認爲第二個選項已經安裝了它,但它沒有。它給我這個錯誤:Xcode:安裝框架時的鏈接器命令錯誤

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-在Build階段運行的腳本:

Shell: /bin/sh 
/usr/local/bin/carthage copy-frameworks 
Input Files: $(SRCROOT)/Carthage/Build/iOS/ZipArchive.framework 

5-現在我能正確地使用進口,但是當我生成項目,它列出了我的錯誤。

編輯:你知道任何工具來解壓縮下載的數據,支持iOS 7?

回答

1

最後,它的工作原理!我只是不知道我必須在構建階段指定必須複製的文件(框架)。我會借給你一個屏幕快照,也許可以幫助某人。

Screenshoot

TY