Ich habe einen Arbeitsbereich mit mehreren Framework-Zielen und einem Anwendungsziel. Alle diese Ziele hängen von einem gemeinsamen Cocoapod ab (in diesem Fall Google Maps). Wie soll ich mein Podfile schreiben, damit all diese Ziele Google Maps verwenden können, ohne dass sie über diese Ziele dupliziert werden?Verknüpfen eines Ziel-C-Frameworks mit mehreren Zielen im selben Arbeitsbereich mit Cocoapods
Mein aktuelles Podfile ist wie folgt:
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
target 'FrameworkA' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for FrameworkA
pod 'GoogleMaps'
end
target 'FrameworkB' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
pod 'GoogleMaps'
# Pods for FrameworkB
end
target 'FrameworkTest' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
pod 'GoogleMaps'
# Pods for FrameworkTest
end
Dies ermöglicht es mir Googlemaps in allen Zielen zu verwenden, aber es endet in diesen Zielen dupliziert werden. Ich kann Fehler wie diese in der Konsole protokolliert sehen:
Class GMSReverseGeocodeResponse is implemented in both /Users/harshad/Library/Developer/Xcode/DerivedData/FrameworkTest-ccpoenicmupoxyadfsxniyjogcjk/Build/Products/Debug-iphonesimulator/FrameworkA.framework/FrameworkA (0x104b73a30) and /Users/harshad/Library/Developer/Xcode/DerivedData/FrameworkTest-ccpoenicmupoxyadfsxniyjogcjk/Build/Products/Debug-iphonesimulator/FrameworkB.framework/FrameworkB (0x1043b0a30). One of the two will be used. Which one is undefined.
Wie kann ich das beheben?
Edit: Hier ist die link to the Github project
Das ändert nichts. Ich bekomme diese Warnungen immer noch traurig in der Konsole. – spider2048