Bug 34125 - Adding "GooglePlayServices.Wearable" causes attribute errors, unable to build
Summary: Adding "GooglePlayServices.Wearable" causes attribute errors, unable to build
Alias: None
Product: Android
Classification: Xamarin
Component: General ()
Version: unspecified
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: ---
Assignee: dean.ellis
Depends on:
Reported: 2015-09-21 13:30 UTC by Tyler_hartwig
Modified: 2015-09-22 17:19 UTC (History)
3 users (show)

Is this bug a regression?: ---
Last known good build:

Sample Wear project (77 bytes, text/plain)
2015-09-21 13:34 UTC, Tyler_hartwig

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report for Bug 34125 on Developer Community or GitHub if you have new information to add and do not yet see a matching new report.

If the latest results still closely match this report, you can use the original description:

  • Export the original title and description: Developer Community HTML or GitHub Markdown
  • Copy the title and description into the new report. Adjust them to be up-to-date if needed.
  • Add your new information.

In special cases on GitHub you might also want the comments: GitHub Markdown with public comments

Related Links:

Description Tyler_hartwig 2015-09-21 13:30:52 UTC
When creating an Android Wear Project, and adding the Xamarin.GooglePlayServices.Wearable causes 3 "Attribute has already been defined" errors.  The attributes listed are imageAspectRatioAdjust, imageAspectRation, and circleCrop.  These exist inside of /res/values/common_attrs.xml

Steps to reproduce:

Open XS and create a new Wear project
Add the Xamarin.GooglePlayServices.Wearable package to the project (through Nuget).
Attempt to build project.

Sample project has been included, demonstrating the issue.
Comment 1 Tyler_hartwig 2015-09-21 13:34:37 UTC
Created attachment 12996 [details]
Sample Wear project
Comment 2 Ashley Gazich [MSFT] 2015-09-22 17:18:38 UTC
Adding "GooglePlayServices.Wearable" causes attribute errors, unable to build.

## Steps to reproduce

1. Create new blank Android Wear project in Xamarin Studio on Mac
2. Add Xamarin.GooglePlayServices.Wearable to project
3. Build
4. Observe `Attribute has already been defined` errors for:

## Workaround

1. Go to Project > Add NuGet Packages
2. Enable “Show pre-release packages” in lower left-hand corner [checkbox]
3. Add the following: 
    Xamarin Android Wear version
    Xamarin GooglePlayServices Base version 26.0.0-rc4
    Xamarin GooglePlayServices Wearable version 26.0.0-rc4

Using pre-release versions allows app to build.

## Version information [Xamarin support]

=== Xamarin Studio ===

Version 5.9.7 (build 9)
Installation UUID: c442567b-f0ca-4cb3-b826-d4d99f1d8a93
	Mono 4.0.4 ((detached/cb6d6b2)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 400040002

=== Apple Developer Tools ===

Xcode 7.0 (8227)
Build 7A220

=== Xamarin.iOS ===

Version: (Enterprise Edition)
Hash: d8e9592
Branch: master
Build date: 2015-09-18 23:22:05-0400

=== Xamarin.Android ===

Version: (Enterprise Edition)
Android SDK: /Users/ashleyg/Library/Developer/Xamarin/android-sdk-macosx
	Supported Android versions:
		2.3    (API level 10)
		4.0.3  (API level 15)
		4.1    (API level 16)
		4.2    (API level 17)
		4.3    (API level 18)
		4.4    (API level 19)
		4.4.87 (API level 20)
		5.0    (API level 21)
		5.1    (API level 22)
Java SDK: /usr
java version "1.7.0_71"
Java(TM) SE Runtime Environment (build 1.7.0_71-b14)
Java HotSpot(TM) 64-Bit Server VM (build 24.71-b01, mixed mode)

=== Xamarin Android Player ===

Version: Unknown version
Location: /Applications/Xamarin Android Player.app

=== Xamarin.Mac ===

Version: (Enterprise Edition)

=== Build Information ===

Release ID: 509070009
Git revision: 31fa64709030b3edb971237780a452a4c69943c4
Build date: 2015-09-17 11:44:37-04
Xamarin addins: b105d33d8cd72911ff2cf3ee0b7715d37e5f19a6

=== Operating System ===

Mac OS X 10.10.5
Darwin ashleyg.local 14.5.0 Darwin Kernel Version 14.5.0
    Wed Jul 29 02:26:53 PDT 2015
    root:xnu-2782.40.9~1/RELEASE_X86_64 x86_64
Comment 3 Ashley Gazich [MSFT] 2015-09-22 17:19:18 UTC
Hi Tyler,

As a workaround, please go to Project > Add Nuget Packages, and check the box for “Show pre-release packages.”

Then add the following:
Xamarin Android Wear version
Xamarin GooglePlayServices Base version 26.0.0-rc4
Xamarin GooglePlayServices Wearable version 26.0.0-rc4

You should be able to build your project after those changes.