I'm trying to install a swift framework I found on GitHub along with the GoogleMaps, GooglePlaces into my Xcode project but for some reason when I try to install the pod file its giving the following error
[!] The 'Pods-project1' target has transitive dependencies that include static binaries: (/Users/user1/Desktop/project1/Pods/GoogleMaps/Base/Frameworks/GoogleMapsBase.framework, /Users/user1/Desktop/project1/Pods/GoogleMaps/Maps/Frameworks/GoogleMaps.framework, and /Users/user1/Desktop/project1/Pods/GoogleMaps/Maps/Frameworks/GoogleMapsCore.framework)
Here is my Pod File I'm trying to install:
#Uncomment the next line to define a global platform for your project
#platform :ios, '9.0'
source 'https://github.com/CocoaPods/Specs.git'
use_frameworks!
target 'project1' do
pod 'GooglePlaces'
pod 'GoogleMaps'
pod 'Google-Maps-iOS-Utils'
pod 'PopupDialog'
end
Also here is the link to the swift framework that I'm trying to install: https://github.com/Orderella/PopupDialog
I don't what to do, I've tried multiple things but non of them seem to work. Any help would be appreciated.
Cocoapod is a package dependency manager for Objective-C and Swift projects with XCode. Those Languages are used to make applications that run iOS, macOS… Swift Objective-C xcode. Cocoapod is a package dependency manager for Objective-C and Swift projects with XCode.
After you have initially installed CocoaPods into your project, you can add new dependencies (or remove unused ones) by editing the Podfile. Then simply run pod install again.
framework files) into the generated Xcode projects instead of the source code. CocoaPods Binary works by adding a pre-install phase which: Pulls out pods which you specify to be pre-compiled. Compiles those pods. Switches the Podspecs which used to refer to source code, to refer to the new compiled frameworks.
To opt into those targets generating module maps (which is necessary to import them from Swift when building as static libraries), you may set `use_modular_headers!` globally in your Podfile, or specify `:modular_headers => true` for particular dependencies.)
It is because "Google-Maps-iOS-Utils" is not a dynamic library while you used "use_frameworks!" in your Podfile. Unfortunately, for this library, we need to install it manually for a Swift project. You can check detailed explanation here:
https://github.com/googlemaps/google-maps-ios-utils/blob/master/Swift.md
I think i have found the solution, I tested myself through yourway and found the same error, So i gone through one by one pod installation, and its works and installed perfectly, but "pod 'Google-Maps-iOS-Utils'" is the reason for arising the error, instead putting this in your podfile, remove that and keep this three under your target.
pod 'GooglePlaces'
pod 'GoogleMaps'
pod ‘PopupDialog’
Install them, it will install perfectly.
Now, in terminal when all dependencies installed successfully, run "pod try Google-Maps-iOS-Utils", it will started installing, then you would get options for like:
1: samples/ObjCDemoApp/ObjCDemoApp.xcodeproj
2: samples/SwiftDemoApp/SwiftDemoApp.xcodeproj
3: workspace/GoogleMapsUtils.xcodeproj
Which project would you like to open ? select your number (eg 3) then press enter
Here you have selected your project and proceed accordingly. (y) and you have done.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With