Accepted answer

Well, there might be another way of solving this problem, but I ended up removing the line in the file that was making reference to the google-play-services_lib library.


The easiest and simple solution is to copy google-play-services_lib folder from another project or SDK folder and past it to the location which is address in the error. By removing or commenting line in the will create errors in the project and won't allow you to build unless you take necessary steps and fix.


I think "removing the line in the file that was making reference to the google-play-services_lib library" is not a good fix. To really fix it do either of these : Just edit the location of the path to google-play-services_lib in file in your Eclipse project root directory.


Note:If you are on windows path\comes\like\this you have to replace the backward slash with the forward slash and your path/will/become/like/this.

e.g :


or replace "\" with "\" like below :


otherway is - just look at the last portion of the last line of the error ....which resolves to ...folder_name/google-play-services_lib

just create a folder at that location and paste google-play-services_lib from your google_play_services\libproject\google-play-services_lib


I just changed it works for me

android.library.reference.2../google-play-services_lib which changed to



An alternative is to simply set the path. You'll need to have installed play services via the Android SDK to use it with Android studio anyway.

Once play services are installed, if you highlight the Google play services entry in the Android SDK manager it will show you the path to the install location. On MAC this is normally something like /Users/[homedir]/android-sdks/extras/google/google_play_services/libproject

Edit the path in to point to this file and it will import. You can then update your gradle build file as necessary.


The simplest solutions is remove this line of code , android.library.reference.2=../google-play-services_lib,from project file (you will find it in project's root folder ) rest android studio will handle itself enter image description here

Find the file: enter image description here

Related Query

More Query from same tag