yizhiguo
yizhiguo
  • 发布:2018-09-14 10:42
  • 更新:2019-12-02 16:45
  • 阅读:2162

引入第三方库(ZipArchive)报错

分类:5+ SDK
SDK

项目是使用mui和原生混合开发的,现需要引入一个第三方库 用原生进行解压文件,但是引入后编译时报错,该如何解决?

或者说原生代码如何才能使用到libcoreSupport.a 解压压缩文件的方法

duplicate symbol _OBJC_CLASS_$_ZipArchive in:  
    /Users/yzg/Library/Developer/Xcode/DerivedData/xcfw-heawhbywpghqpkbtawhivarpdecs/Build/Intermediates.noindex/xcfw.build/Debug-iphoneos/xcfw.build/Objects-normal/arm64/ZipArchive.o  
    /Users/yzg/Desktop/iOS/xcfw-ios/xcfw/libs/libcoreSupport.a(ZipArchive.o)  
duplicate symbol _OBJC_METACLASS_$_ZipArchive in:  
    /Users/yzg/Library/Developer/Xcode/DerivedData/xcfw-heawhbywpghqpkbtawhivarpdecs/Build/Intermediates.noindex/xcfw.build/Debug-iphoneos/xcfw.build/Objects-normal/arm64/ZipArchive.o  
    /Users/yzg/Desktop/iOS/xcfw-ios/xcfw/libs/libcoreSupport.a(ZipArchive.o)  
duplicate symbol _OBJC_IVAR_$_ZipArchive._delegate in:  
    /Users/yzg/Library/Developer/Xcode/DerivedData/xcfw-heawhbywpghqpkbtawhivarpdecs/Build/Intermediates.noindex/xcfw.build/Debug-iphoneos/xcfw.build/Objects-normal/arm64/ZipArchive.o  
    /Users/yzg/Desktop/iOS/xcfw-ios/xcfw/libs/libcoreSupport.a(ZipArchive.o)  
duplicate symbol _OBJC_IVAR_$_ZipArchive._unzFile in:  
    /Users/yzg/Library/Developer/Xcode/DerivedData/xcfw-heawhbywpghqpkbtawhivarpdecs/Build/Intermediates.noindex/xcfw.build/Debug-iphoneos/xcfw.build/Objects-normal/arm64/.o  
    /Users/yzg/Desktop/iOS/xcfw-ios/xcfw/libs/libcoreSupport.a(ZipArchive.o)  
duplicate symbol _OBJC_IVAR_$_ZipArchive._zipFile in:  
    /Users/yzg/Library/Developer/Xcode/DerivedData/xcfw-heawhbywpghqpkbtawhivarpdecs/Build/Intermediates.noindex/xcfw.build/Debug-iphoneos/xcfw.build/Objects-normal/arm64/ZipArchive.o  
    /Users/yzg/Desktop/iOS/xcfw-ios/xcfw/libs/libcoreSupport.a(ZipArchive.o)  
duplicate symbol _OBJC_IVAR_$_ZipArchive._password in:  
    /Users/yzg/Library/Developer/Xcode/DerivedData/xcfw-heawhbywpghqpkbtawhivarpdecs/Build/Intermediates.noindex/xcfw.build/Debug-iphoneos/xcfw.build/Objects-normal/arm64/ZipArchive.o  
    /Users/yzg/Desktop/iOS/xcfw-ios/xcfw/libs/libcoreSupport.a(ZipArchive.o)  
ld: 6 duplicate symbols for architecture arm64  
clang: error: linker command failed with exit code 1 (use -v to see invocation)

2018-09-14 10:42 负责人:无 分享
已邀请:
海之杰China

海之杰China

https://zhuanlan.zhihu.com/p/94770774 已经解决

该问题目前已经被锁定, 无法添加新回复