Error:Attribute "theme" has already been defined
just use latest (21)
appCompat and
google play services library
For example:
compile 'com.android.support:support-v4:21.0.0'compile 'com.android.support:appcompat-v7:21.0.0'compile 'com.android.support:recyclerview-v7:21.0.0' compile 'com.android.support:cardview-v7:21.0.0'compile 'com.google.android.gms:play-services:6.1.11'
then everything works :)
Just check, whether you have a file named attrs.xml. In that file replace the following line
<attr name="theme" format="reference" />
with
<attr name="apptheme" format="reference" />
That is, rename the theme name.Now clean the project.This solved my issue.
I had the same issue developing in Eclipse after updating content via the SDK manager.
I had to completely remove the Google Play Services library from the Workspace and then copy and import the updated version following the instructions here.
No updating of the referenced jars helped me - Only a full fresh import. This included updating the android-support-v7-appcompat import.