1、报错内容
Undefined symbols for architecture arm64:
"_inflate", referenced from:
+[WXOMTAHelper GUnzip:Out:] in libWeChatSDK.a(MTAHelper.o)
"_inflateEnd", referenced from:
+[WXOMTAHelper GUnzip:Out:] in libWeChatSDK.a(MTAHelper.o)
"_deflate", referenced from:
+[WXOMTAHelper GZip:Out:] in libWeChatSDK.a(MTAHelper.o)
"_deflateInit2_", referenced from:
+[WXOMTAHelper GZip:Out:] in libWeChatSDK.a(MTAHelper.o)
"_inflateInit2_", referenced from:
+[WXOMTAHelper GUnzip:Out:] in libWeChatSDK.a(MTAHelper.o)
"_deflateEnd", referenced from:
+[WXOMTAHelper GZip:Out:] in libWeChatSDK.a(MTAHelper.o)
"operator new[](unsigned long)", referenced from:
+[WeChatApiUtil EncodeBase64:] in libWeChatSDK.a(WeChatApiUtil.o)
+[WeChatApiUtil NsDataEncodeBase64:] in libWeChatSDK.a(WeChatApiUtil.o)
+[WeChatApiUtil DecodeWithBase64:] in libWeChatSDK.a(WeChatApiUtil.o)
+[WeChatApiUtil DecodeBase64:] in libWeChatSDK.a(WeChatApiUtil.o)
"operator delete[](void*)", referenced from:
+[WeChatApiUtil EncodeBase64:] in libWeChatSDK.a(WeChatApiUtil.o)
+[WeChatApiUtil NsDataEncodeBase64:] in libWeChatSDK.a(WeChatApiUtil.o)
+[WeChatApiUtil DecodeWithBase64:] in libWeChatSDK.a(WeChatApiUtil.o)
+[WeChatApiUtil DecodeBase64:] in libWeChatSDK.a(WeChatApiUtil.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
2、解决办法
- 需要导入动态库libz.dylib, 导入方法