Search code examples
iosgoogle-mapsxcframework

Build failure for Google Maps xcframework


On building an app containing Google Maps using Cocoapods, I get these build errors:

error: Failed to load XCFramework at '[...]/Pods/GoogleMaps/Base/Frameworks/GoogleMapsBase.xcframework': 'HeadersPath' is not supported for a 'framework' in library 'ios-arm64'.

error: Failed to load XCFramework at '[...]/Pods/GoogleMaps/Maps/Frameworks/GoogleMaps.xcframework': 'HeadersPath' is not supported for a 'framework' in library 'ios-arm64'.

I can't find any relevant reference to "HeadersPath" either in project nor via web search. I've tried rebooting Xcode, rebooting machine, clearing DerivedData, uninstalled Google Maps pod and reinstalled it again, and played with lots of Build Settings - nothing gets rid of these errors. The app used to build ok, and I am attempting to build an update with new iOS deployment version 14 and new Google Maps version 8.4.0. Also XCode has just been updated to v15.4. Any ideas what I should be checking or changing?


Solution

  • After much experimentation, I found that by reverting to Google Maps SDK v8.0.0, the project builds and runs ok again. Hence I believe there is some SDK issue introduced since then which is causing the problem. I have posted the issue to Google Maps support.