Bug 23990 - Error when building a project with a TargetFramework < v2.3 should be improved and standardized
Summary: Error when building a project with a TargetFramework < v2.3 should be improve...
Status: VERIFIED FIXED
Alias: None
Product: Android
Classification: Xamarin
Component: General ()
Version: 5.0
Hardware: PC Windows
: Normal normal
Target Milestone: 5.0
Assignee: Jonathan Pryor
URL:
: 24810 ()
Depends on:
Blocks:
 
Reported: 2014-10-22 11:13 UTC by Peter Collins
Modified: 2014-12-01 18:03 UTC (History)
3 users (show)

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

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 on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
VERIFIED FIXED

Description Peter Collins 2014-10-22 11:13:19 UTC
Note that this issue only occurs on Windows. On OSX the project compiles successfully, with a warning displayed that "API-10" was used for ACW compilation.

C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(400,2): error XA0000: Could not determine API level for $(TargetFrameworkVersion) of 'v5.2.3'. [C:\Users\XamarinQA\monodroid-samples\Button\DroidButton.csproj]


Diagnostic build output of failure (windows):
https://gist.github.com/pjcollins/c76ed6962a2d59d4535e 

Diagnostic build output of "success" (OSX):
https://gist.github.com/pjcollins/b02c939fc27f214f569f



=== Xamarin Studio ===
Version 5.6.2 (build 5)
Installation UUID: 0a846c8f-f4f7-44a8-9ab1-8dccd7e02db0
Runtime:
	Microsoft .NET 4.0.30319.34014
	GTK+ 2.24.22 (MS-Windows theme)
	GTK# 2.12.26

=== Xamarin.Android ===
Version: 4.99.0 (Business Edition) (0-144)
Android SDK: C:\Users\XamarinQA\AppData\Local\Android\android-sdk
	Supported Android versions:
		2.3    (API level 10)
		3.0    (API level 11)
		3.1    (API level 12)
		3.2    (API level 13)
		4.0    (API level 14)
		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)
Java SDK: C:\Program Files\Java\jdk1.7.0_51
java version "1.7.0_51"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)

=== Build Information ===
Release ID: 506020005
Git revision: 19bc3b64b70332bfab18faf9cf1ce7d3aa191b36
Build date: 2014-10-17 12:42:33-04
Xamarin addins: 9733ae2c344131c7b8a9b83680dfc64e80a60db0

=== Operating System ===
Windows 6.2.9200.0 (64-bit)
Comment 1 Nischal 2014-11-03 00:41:15 UTC
I am also able to reproduce this Issue with mentioned builds. This is the build output for the same: https://gist.github.com/saurabh360/9c1bbfb3c0b07ab189f1

=== Xamarin Studio ===

Version 5.6.2 (build 5)
Installation UUID: 917f9508-3cad-494a-8fd9-cc9e3683ecc5
Runtime:
	Microsoft .NET 4.0.30319.34014
	GTK+ 2.24.22 (MS-Windows theme)
	GTK# 2.12.26

=== Xamarin.Android ===

Version: 4.99.0 (Trial Edition)
Android SDK: D:\SDKndk\AndroidSDK\android-sdk
	Supported Android versions:
		2.1    (API level 7)
		2.2    (API level 8)
		2.3    (API level 10)
		3.1    (API level 12)
		4.0    (API level 14)
		4.0.3  (API level 15)
		4.3    (API level 18)
		4.4    (API level 19)
		4.4.87 (API level 20)
		4.5    (API level 21)
Java SDK: C:\Program Files\Java\jdk1.7.0_60
java version "1.7.0_60-ea"
Java(TM) SE Runtime Environment (build 1.7.0_60-ea-b15)
Java HotSpot(TM) Client VM (build 24.60-b09, mixed mode, sharing)

=== Build Information ===

Release ID: 506020005
Git revision: 19bc3b64b70332bfab18faf9cf1ce7d3aa191b36
Build date: 2014-10-17 12:42:33-04
Xamarin addins: 9733ae2c344131c7b8a9b83680dfc64e80a60db0

=== Operating System ===

Windows 6.2.9200.0
Comment 2 Jonathan Pryor 2014-11-21 12:38:15 UTC
Does this still repro monodroid/37bc0ff3, The Great $(TargetFrameworkVersion) Schema Revert?
Comment 5 Peter Collins 2014-11-25 17:14:56 UTC
*** Bug 24810 has been marked as a duplicate of this bug. ***
Comment 6 PJ 2014-11-25 18:12:50 UTC
To move forward, I think we have some consensus on option 1 here. 

Moving back to confirmed. The issue now is improving and standardizing the error message.
Comment 7 Jonathan Pryor 2014-12-01 12:50:53 UTC
Fixed in monodroid/faaaad27 and monodroid-5.0-branch/bfc383b0.