Ionic Native : Google Maps - build error after install the plugin


After installed the Google Map plugin.

ionic cordova plugin add cordova-plugin-googlemaps --variable API_KEY_FOR_ANDROID="MY_KEY" --variable API_KEY_FOR_IOS="MY_KEY"

npm install --save @ionic-native/google-maps

I got these errors when building with both ionic cordova or XCode

Copy String File Error:
error: failed to remove /Users/xxx/Library/Developer/Xcode/DerivedData/xxx-hhualsifpvbgcedfdmvedteqcvdf/Build/Products/Debug-iphoneos/ “pgm_Localizable.strings” couldn’t be removed.
error: couldn't remove '/Users/xxx/Library/Developer/Xcode/DerivedData/xxx-hhualsifpvbgcedfdmvedteqcvdf/Build/Products/Debug-iphoneos/' after command failed: No such file or directory

I’ve try cordova clean, XCode > product > clean and removing and re-adding everything but still get the same error.

After removing the Google Map plugin the error is gone.

Does anyone has any idea on how to solve this issue? thank you in advance.

My Ionic Info

@ionic/cli-utils  : 1.19.1
ionic (Ionic CLI) : 3.19.1
mac: latest version

You might try

ionic cordova platform rm ios
ionic cordova platform add ios
ionic cordova prepare ios

Then open in Xcode and try again.

It looks like there’s some issue with localization, so you can also check the Info tab in Xcode to see if there are strings or translations that need to be removed/updated.

Hi @ebellempire ,

Thank you for your reply. I tried the remove/add method you mentioned but still failed (same error). How to check and for string and translation that you mentioned? I don’t quite understand.


Thank you. Problem solved by removing every other pgm_Localizable.strings other than english in xcode. Not sure if done it the right way.

1 Like
$> cordova plugin rm cordova-plugin-googlemaps

$> cordova plugin add cordova-plugin-googlemaps@2.2.8 --variable ...
1 Like

Thank you it solved my problem. It came from that the play_services_version wasn’t the same than the one used in other plugin (google plus)