boxmoe_header_banner_img

Hello! 欢迎来到我的博客!

加载中

文章导读

CocoaPods 导入 QQ互联 SDK 后编译报错 Redefinition of “XXX”


avatar
博主大大 2022年3月12日 2.84k

CocoaPods 导入 QQ互联 SDK 后编译报错

Redefinition of 'TencentAuthorizeState'
Redefinition of enumerator 'kTencentNotAuthorizeState'
Redefinition of enumerator 'kTencentSSOAuthorizeState'
Redefinition of enumerator 'kTencentWebviewAuthorzieState'
...

解决方法

1、找到以下路径

项目文件夹->Pods->TencentOpenAPI-iOS->TencentOpenAPI->TencentOpenAPI.framework->Headers->module.modulemap

2、编辑 module.modulemap 文件,将 module.modulemap 里的内容替换为以下

framework module TencentOpenAPI {
  header "QQApiInterface.h"
  header "QQApiInterfaceObject.h"
  header "TencentOAuth.h"
  header "TencentOpenApiUmbrellaHeader.h"
  header "sdkdef.h"

  export *
}


评论(已关闭)

评论已关闭