M&M
Posts: 0
Joined: Tue Nov 11, 2014 6:59 am

error: package com.google.android.gms.common does not exist

hi,

I am using a cordova plugin in my app and I get the following error

error: package com.google.android.gms.common does not exist

I think this has to do with google play services dependency.

I found this plugin to add Google Play Services
https://github.com/MobileChromeApps/g...

But I'd need some help on this regarding where the folders / files should be put

Or is there a way I can use this: https://github.com/ptgamr/cordova-goo...

I just want google play service available in my app as my geo-fencing plugin depends on google play services.

Thanks,
M&M

Egor Kotov6832188
Posts: 0
Joined: Wed Nov 19, 2014 5:15 pm

error: package com.google.android.gms.common does not exist

Hello M&M,

Your plugin should be placed in the same folder as Toster tutorial plugin.

M&M
Posts: 0
Joined: Tue Nov 11, 2014 6:59 am

error: package com.google.android.gms.common does not exist

I do not understand the answer. I.have explained the problem quite clearly i guess. I was expecting something better than just asking to repeatedly refer to the tutorials. The.quality of answers on the forum has gone down drastically or they don't get answered at all

Egor Kotov6832188
Posts: 0
Joined: Wed Nov 19, 2014 5:15 pm

error: package com.google.android.gms.common does not exist

M&M,

Your question related to Java project structure.

error: package com.google.android.gms.common does not exist
I think this has to do with google play services dependency.

No, it is related to your file location in the Java project.
Basically, it says, that you haven't created folder structure, thus it can't find it.

M&M
Posts: 0
Joined: Tue Nov 11, 2014 6:59 am

error: package com.google.android.gms.common does not exist

all i am doing is to use a geolocation plugin and from what I understand com.google.android.gms.common is related to Google Play Services

http://developer.android.com/referenc...

I have seen other plugins also having dependency to Google Play Services. So how do I include this in my app? If you can let me know the file structure and what/where to copy to enable Google Play Service in my app

thanks,
M&M

r monisha
Posts: 0
Joined: Mon Mar 26, 2018 9:20 am

error: package com.google.android.gms.common does not exist

i too have a doubt on android studio with my quotient (import com.google.android.gms.location.LocationRequest)

r monisha
Posts: 0
Joined: Mon Mar 26, 2018 9:20 am

error: package com.google.android.gms.common does not exist

i have error on these lines which works under android studio
(import com.google.android.gms.location.LocationListener;
import com.google.android.gms.location.LocationRequest;
import com.google.android.gms.location.LocationServices;)
give me a better solution

r monisha
Posts: 0
Joined: Mon Mar 26, 2018 9:20 am

error: package com.google.android.gms.common does not exist

import com.google.android.gms.location.LocationListener;
import com.google.android.gms.location.LocationRequest;
import com.google.android.gms.location.LocationServices;

r monisha
Posts: 0
Joined: Mon Mar 26, 2018 9:20 am

error: package com.google.android.gms.common does not exist

Error:(15, 102) error: package com.google.android.gms.location does not exist
Error:(16, 47) error: package com.google.android.gms.location does not exist
Error:(17, 47) error: package com.google.android.gms.location does not exist
Error:(28, 63) error: package com.google.android.gms.nearby.messages.internal does not exist
Error:(30, 39) error: package org.apache.http.message does not exist
Error:(41, 9) error: cannot find symbol class LocationListener
Error:(47, 5) error: cannot find symbol class LocationRequest
Error:(51, 5) error: cannot find symbol class JSONParser
Error:(51, 31) error: cannot find symbol class JSONParser
Error:(89, 25) error: cannot find symbol variable LocationServices
Error:(95, 32) error: cannot find symbol class LocationRequest
Error:(98, 38) error: cannot find symbol variable LocationRequest
Error:(102, 29) error: package LocationServices does not exist
Error:(202, 28) error: cannot find symbol class BasicNameValuePair
Error:(241, 28) error: cannot find symbol class BasicNameValuePair
Error:(242, 28) error: cannot find symbol class BasicNameValuePair
Error:(244, 32) error: cannot find symbol class BasicNameValuePair
Error:(245, 32) error: cannot find symbol class BasicNameValuePair
Error:Execution failed for task ':app:compileDebugJavaWithJavac'.
Compilation failed; see the compiler error output for details.

Return to “Issues”