Google-Maps-iOS-Utils with google maps missing GMSGeometryUtils.h - ios

I been struguling with this for hours now, I can't understand what is wrong. I followed googles iOS cluster setup carefully, but no mater what I do it doesn't work. I'm getting this error:
.../Pods/Google-Maps-iOS-Utils/src/Clustering/Algo/GMUNonHierarchicalDistanceBasedAlgorithm.m:22:9: 'GoogleMaps/GMSGeometryUtils.h' file not found
I have installed the following:
Using Alamofire (3.4.1)
Using Google-Maps-iOS-Utils (1.0.0)
Using GoogleMaps (1.9.2)
Pod file:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.3'
use_frameworks!
pre_install do |installer|
def installer.verify_no_static_framework_transitive_dependencies; end
end
target 'Happevents' do
pod 'GoogleMaps' # Objective-C pod
pod 'Google-Maps-iOS-Utils' # Objective-C pod
pod 'Alamofire', '~> 3.4' # Swift pod
end

I installed Google-Maps-iOS-Utils in my project by pod installation. Please update your pod file
target 'Happevents' do
pod 'GoogleMaps' # Objective-C pod
pod 'Google-Maps-iOS-Utils', :git => 'https://github.com/googlemaps/google-maps-ios-utils'
pod 'Alamofire', '~> 3.4' # Swift pod
end

You should remove use_frameworks! from your pod file

There is a manual from Google how to use their library with Swift and use_frameworks! you could also check this one.

Related

RxMoya downgrade Alamofire to 4.9.1, but i need to use Alamofire 5+

The main problem is am using currently Moya on my app, but I want to use some functions from "Moya/RxSwift" pod, the problem I am having is when i change the pod the Alamofire downgrades to 4.9.1 and produce a lot of error in the code, there is a way to edit the pod file to keep using Alamofire 5?
My PODS in the podfile:
# Uncomment this line to define a global platform for your project
# platform :ios, ’10.0’
platform :ios, '10.0'
use_frameworks!
inhibit_all_warnings!
def core_pods
#core
pod 'ZXingObjC'
pod 'Moya/RxSwift'
pod 'RxSwift'
pod 'RxCocoa'
pod 'RxViewModel'
pod 'XCGLogger', '~> 6.1.0'
pod 'SwiftyJSON'
pod 'CryptoSwift', :git => "https://github.com/krzyzanowskim/CryptoSwift", :branch => "master"
pod 'AFDateHelper'
#pod 'Fabric'
#pod 'Crashlytics'
end
def ui_pods
pod 'SVProgressHUD'
pod 'CropViewController'
pod 'lottie-ios'
end
examples of some errors i got on the code because of the downgrade:

After installing Firebase with CocoaPod, I can no longer build

I'm trying to build Javascript source code as an iOS app using Cordova.
I have introduced firebase with CocoaPods, and I am very troubled because I can not build.
this is wannings
Ignoring file /Users/MYNAME/Library/Developer/Xcode/DerivedData/ProductName/Build/Products/Debug-iphonesimulator/CocoaLumberjack/CocoaLumberjack.framework/CocoaLumberjack, building for iOS Simulator-i386 but attempting to link with file built for iOS Simulator-x86_64
This is Error
Undefined symbols occur in large numbers
This is my Cocoapod profile.
platform :ios, '10.0'
use_frameworks!
target 'product_name' do
use_frameworks!
project 'product_name.xcodeproj'
use_frameworks!
pod 'Firebase/Analytics'
pod 'Firebase/Core'
pod 'Firebase/Firestore'
pod 'FirebaseFirestoreSwift', '~> 0.2'
# ID Instance
pod 'Firebase/Messaging'
# config
pod 'CocoaLumberjack/Swift'
# Pods for PodTest
pod 'Fabric', '~> 1.10.2'
pod 'Crashlytics', '~> 3.14.0'
# Bluetooth
pod 'RxBluetoothKit'
# debug
pod 'SimulatorStatusMagic', :configurations => ['Debug']
# design pattern
pod 'Swinject'
# zip
pod 'Zip'
# Protect UI
pod 'iOSDFULibrary'
pod 'libb2s'
end
target 'shareExtension' do
use_frameworks!
pod 'Firebase/Analytics'
pod 'Firebase/Core'
pod 'Firebase/Firestore'
pod 'FirebaseFirestoreSwift', '~> 0.2'
# ID Instance
pod 'Firebase/Messaging'
# config
pod 'CocoaLumberjack/Swift'
# Pods for PodTest
pod 'Fabric', '~> 1.10.2'
pod 'Crashlytics', '~> 3.14.0'
# Bluetooth
pod 'RxBluetoothKit'
# debug
pod 'SimulatorStatusMagic', :configurations => ['Debug']
# design pattern
pod 'Swinject'
# zip
pod 'Zip'
# Protect UI
pod 'iOSDFULibrary'
pod 'libb2s'
end
My Enviroment:
XCode Version 11.5
CocoaPods Version 1.9.3
What I have done so far.
STEP 1 : Solved CocoaPods Warnnings.
STEP 2 : Error Id: library Not Found XXXX
→ I installed the Not Found framework with CocoaPod(And decided to install a lot)
STEP3 : Modify Library Search Paths
STEP4 : Set Build Active Architecture Only explicitly to No
If anyone has experienced a similar error, I would like some advice on the current error.
Thanks.
I solved my problem.
I found an explanation in the condition of the build using the simulator.
Premise:
Why does the iOS simulator require i386 and x86_64 symbols even though I'm on an x86_64 system only?
Implementation example:
Could not find module for target 'x86_64-apple-ios-simulator'
In my project, I have to cleat Cordiva - Firebase relationship.
After,question,I did two Implementation.
STEP1: Find out why I can't build
Refer to the above article or build on the our iPhone.
STEP2: Organize compatibility
Make CORDOVA a parent element and make other targets child elements
THANKS!!

CleverTapSDK module not found

I am using various Swift and Objective-C libraries in my (Swift) project. My Podfile looks as follows:
platform :ios, '8.0'
use_frameworks!
pod 'Alamofire', '~> 3.0'
pod 'SwiftyJSON', :git => 'https://github.com/SwiftyJSON/SwiftyJSON.git'
pod 'FBSDKCoreKit'
pod 'FBSDKShareKit'
pod 'FBSDKLoginKit'
pod 'Fabric'
pod 'TwitterKit'
pod 'SimpleAuth/Instagram'
pod 'AFNetworking', '~> 3.0'
pod 'Parse'
To have support for using both (Swift and Objective-C) libraries, I use use_framework! directive in Podfile to install and use them. If we use directive use_framework! for Objective-C libraries, we are not required to create any kind of bridging-header.h and we can use it directly by import ModuleName. I am having no issues with any of the above mentioned pods/frameworks while installing or using them.
But there is this one framework which is written in Objective-C and I install it by adding its entry in Podfile as pod 'CleverTap-iOS-SDK'. The installations goes well but when I try to import CleverTapSDK or import CleverTap to use the library, it is giving me no such module error.
Just in case: My Xcode version is - 7.3 (7D175)

Cocoapods Test Issue - Duplicate "one of the two will be used. which one is undefined."

I've been trying to solve this issue for a couple days and haven't found a solution. Whenever I try to run a test I receive the error shown below that there are duplicate classes.
I tried these answers but I'm still receiving the duplicate error and my tests won't run
Cocoapods Warning - CocoaPods did not set the base configuration of your project because because your project already has a custom config set
My pod file looks like this:
platform :ios, "8.0"
def project_pods
pod "Braintree"
pod "AFNetworking", "~> 3.0"
pod "MBProgressHUD"
pod "ActionSheetPicker-3.0", "~> 2.0.1"
pod "SCLAlertView-Objective-C", "~> 0.7"
pod "GoogleMaps"
pod "MPSHorizontalMenu"
pod "Fabric"
pod "Crashlytics"
pod "RateView"
pod "QBImagePickerController"
pod "GLCalendarView", "~> 1.0.0"
pod "Heap"
pod "AWSS3"
end
target “iOS_project” do
project_pods
end
target “iOS_projectTests” do
project_pods
end
This is what the error looks like and it is for every cocoapod class:
Class GMSAutocompleteResultsViewController is implemented in both /Users/john/Library/Developer/CoreSimulator/Devices/27CF0470-07AC-4575-8907-A27EE9B357A7/data/Containers/Bundle/Application/7AFB0886-9ED1-464D-8B02-067CDD07511D/iOS_project.app/iOS_project and /Users/john/Library/Developer/Xcode/DerivedData/iOS_projectTests-hezbkjqviaiitthcrrnwetvcojcb/Build/Products/Debug-iphonesimulator/iOS_projectTests.xctest/iOS_projectTests. One of the two will be used. Which one is undefined.
All of the pods are Objective C and I am using a bridging header
Reformat your podfile like this:
platform :ios, "8.0"
def project_pods
pod "Braintree"
pod "AFNetworking", "~> 3.0"
pod "MBProgressHUD"
pod "ActionSheetPicker-3.0", "~> 2.0.1"
pod "SCLAlertView-Objective-C", "~> 0.7"
pod "GoogleMaps"
pod "MPSHorizontalMenu"
pod "Fabric"
pod "Crashlytics"
pod "RateView"
pod "QBImagePickerController"
pod "GLCalendarView", "~> 1.0.0"
pod "Heap"
pod "AWSS3"
target "iOS_projectTests" do
inherit! :search_paths
end
end
target "iOS_project" do
project_pods
end
Source: CocoaPods issue #4626
The error indicates that '
GMSAutocompleteResultsViewController' is integrated two time and only one is used from it
If you are not using unit testing case target for now you can remove that portion from the podfile and check again by pod install or pod update
Remove this portion from your podfile
target “iOS_projectTests” do
project_pods
end
For swift it will be good if you set use_frameworks! below the platform version
so your top portion can be like
platform :ios, "8.0"
use_frameworks!
so your new podfile can look like this
platform :ios, "8.0"
use_frameworks!
def project_pods
pod "Braintree"
pod "AFNetworking", "~> 3.0"
pod "MBProgressHUD"
pod "ActionSheetPicker-3.0", "~> 2.0.1"
pod "SCLAlertView-Objective-C", "~> 0.7"
pod "GoogleMaps"
pod "MPSHorizontalMenu"
pod "Fabric"
pod "Crashlytics"
pod "RateView"
pod "QBImagePickerController"
pod "GLCalendarView", "~> 1.0.0"
pod "Heap"
pod "AWSS3"
end
target “iOS_project” do
project_pods
end
target “iOS_projectTests” do
project_pods
end
Hope this helps, if it still shows the error you may put pods directly on the target instead of putting in def at top
Note: For the Google map you can also directly import the framework like import GoogleMaps instead of adding google maps in the bridging header
now, modify Podfile by commenting use_frameworks! ,like below:
platform :ios, '8.0'
#use_frameworks!
target 'ShiBa' do
pod 'SDWebImage'
pod 'AFNetworking'
pod 'MBProgressHUD'
pod 'MJRefresh', '3.1.0'
pod 'UMengAnalytics'
pod 'YYModel'
pod 'AMapLocation'
pod 'pop'
end

FBSDKs installed via Pods - No such module on Swift

I installed the following pods to my Swift project:
platform :ios, '8.0'
pod 'ParseUI', '~> 1.1.4'
pod 'Parse', '~> 1.7.5'
pod 'FBSDKCoreKit', '4.3.0'
pod 'FBSDKLoginKit', '4.3.0'
pod 'FBSDKShareKit', '4.3.0'
pod 'ParseFacebookUtilsV4', '~>1.7.5'
pod 'AFNetworking', '~> 2.5.4'
I added a Bridging Header for all the pods except the 3 FBSDKs. On https://developers.facebook.com/docs/ios/getting-started , it says...
"Swift
v4.1 of the SDK supports modules natively so no bridging headers are required. Simply import the appropriate kit module in your .swift files"
Problem is when I try to import those 3 frameworks to AppDelegate, I get the error message "No such module 'FBSDKCoreKit'"
Anyone encounter this issue before?
Thanks in advance.
Try adding use_frameworks! to the top of your podfile. It solved my problem. Initialy it is shown as #use_frameworks! in podfile . Remove the # infront of use_frameworks!. This blog explains about it.

Resources