-->

GoogleMobileVision GoogleSignIn duplicate symbol u

2019-05-19 20:13发布

问题:

I am using CocoaPods to add two frameworks.

target 'TestGoogleLib' do
  # Comment the next line if you're not using Swift and don't want to use dynamic frameworks
  use_frameworks!

  # Pods for TestGoogleLib
    pod 'GoogleMobileVision'
    pod 'GoogleSignIn'


end

But when I run - I get duplicate error. It seems both framework are using same file.

My Pod version is 1.5.3

duplicate symbol _OBJC_IVAR_$_MDMPasscodeCache._localAuthenticationInfo in:


ld: 13 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

How can I install both using CocoaPods without conflicts --- I removed all conflicts logs - if needed, I can add them.

回答1:

This is an issue with the GoogleMobileVision and GoogleSignIn pods including the same symbols in their builds. See this discussion.

Until the build issue is resolved in one or both of those pods, a workaround is to back up the version of GoogleSignIn:

pod 'GoogleSignIn', '4.1.2'