0
votes

I need to use Afnetworking and google-maps-ios-utils both in my project but using pods it is not possible. because Afnetworking don't work if I comment # use framework! in my pod file and google-maps-ios-utils don't work if I uncomment it. I tried manually installing google-maps-ios-utils but it still give me error related to bridging header. Is there any way to use both library together. Or how to install AFnetworking or google-maps-ios-utils manually to avoid this clash. I need some alternative for google-maps-ios-utils because it is only works if I comment #use_frameworks! in pod file , and if I comment it most of other library such as FBSDKLoginKit and SDWebimage get error. Xcode 10, swift 4.

1
Try Alamofire (github.com/Alamofire/Alamofire) rather than AFNetworking - it’s from the same author, but written in Swift - Chris
ok I tried it but didn't worked, actually I need some alternative for google-maps-ios-utils because it is only works if I comment #use_frameworks! in pod file , and if I comment it most of other library used get error. - Rj19
@user11596918 You must try this - stackoverflow.com/a/41115279/3683408. Hope it's save your time! - Ram
Yes I was trying the same approach from the very beginning. Actually it was just a header thing from this approach that was handling in wrong way. By the way its solved now. Thanks. - Rj19

1 Answers

0
votes

Have you try this on your pod file like below,

 source 'https://github.com/CocoaPods/Specs.git'
    platform :ios, '10.0'

    use_frameworks!

    def share_pods

      # Pods for your target name

      pod 'AFNetworking', '~> 3.0'
      pod 'GoogleMaps'

    end


    target 'your target name' do
      share_pods
    end

Hope it's help you:)