This repository was archived by the owner on Aug 8, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
SMCalloutView has caused the conflict at the time of build, when I have already integrate it by CocoaPods on iOS #1757
Copy link
Copy link
Closed
Description
I have already integrate 'SMCalloutView' in Xcode project by CocoaPods on iOS. It has integrated for displaying calloutview in other map library.
I want to include in together Mapbox GL and other map library.
How do I can solve this problem?
The following is the error message of conflict.
duplicate symbol _OBJC_IVAR_$_SMCalloutView._backgroundView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._delegate in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._title in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._subtitle in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._leftAccessoryView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._rightAccessoryView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._permittedArrowDirection in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._currentArrowDirection in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._constrainedInsets in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._titleView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._subtitleView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._contentView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._contentViewInset in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._calloutOffset in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._presentAnimation in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._dismissAnimation in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._containerView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._titleLabel in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._subtitleLabel in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutView._popupCancelled in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutMaskedBackgroundView._containerView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutMaskedBackgroundView._containerBorderView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutMaskedBackgroundView._arrowView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutMaskedBackgroundView._arrowImageView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutMaskedBackgroundView._arrowHighlightedImageView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutMaskedBackgroundView._arrowBorderView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutBackgroundView._arrowPoint in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutBackgroundView._highlighted in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutBackgroundView._contentMask in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutBackgroundView._anchorHeight in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_IVAR_$_SMCalloutBackgroundView._anchorMargin in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _kSMCalloutViewRepositionDelayForUIScrollView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_CLASS_$_SMCalloutView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_METACLASS_$_SMCalloutView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_CLASS_$_SMCalloutMaskedBackgroundView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_METACLASS_$_SMCalloutMaskedBackgroundView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_CLASS_$_SMCalloutBackgroundView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
duplicate symbol _OBJC_METACLASS_$_SMCalloutBackgroundView in:
/Users/tette/PathToProject/Pods/MapboxGL/libMapboxGL.a(SMCalloutView.o)
/Users/tette/Library/Developer/Xcode/DerivedData/myproject-ghpyhvccoqkfgngwmtkdjsofxcdk/Build/Products/Debug(DevEnv)-iphonesimulator/libPods-SMCalloutView.a(SMCalloutView.o)
ld: 38 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Activity
1ec5 commentedon Jun 19, 2015
Interesting. We're pulling SMCalloutView in via a submodule, which is why CocoaPods is allowing a second copy to be placed in the project. I think we'll have to add an MGL prefix to all SMCalloutView's classes like we did to our copy of Reachability.
incanus commentedon Jun 20, 2015
Related: nfarina/calloutview#88
You should be able to just include the header where you need it and use the already built-in version for now.
jfirebaugh commentedon Jul 2, 2015
I believe #898 is the proper fix for this issue and others of its ilk.
1ec5 commentedon Jul 2, 2015
Even with #898, you’d probably get warnings at runtime – and non-deterministic behavior if we ever use a different version of SMCalloutView than the developer. The Objective-C runtime has no namespacing, and
NSClassFromString("SMCalloutView")would return unpredictable results.incanus commentedon Jul 5, 2015
This really comes down to a build process issue for us, since installing via CocoaPods is supposed to resolve dependency issues, but we distribute a binary which includes it already. Until we hit #1437 we can't fix this.
1ec5 commentedon Jul 5, 2015
But we can work around it by prefixing our copy of
SMCalloutView,SMCalloutArrowDirection, etc. in a fork of nfarina/calloutview.friedbunny commentedon Jul 29, 2016
We’re replacing SMCalloutView with a homegrown solution, per #4392.
friedbunny commentedon Oct 11, 2017
The duplicate symbol compilation errors are gone after #898, but objc still doesn’t appreciate that there are two SMCalloutView implementations:
friedbunny commentedon Oct 11, 2017
Fixed in #10183 and v3.7.0-beta.2.