Bug 20200 - Android Library project type is based on was not found when building from command line
Summary: Android Library project type is based on was not found when building from com...
Status: RESOLVED ANSWERED
Alias: None
Product: Android
Classification: Xamarin
Component: MSBuild ()
Version: 4.12.4
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2014-05-30 10:20 UTC by Allie Miller
Modified: 2016-12-29 20:41 UTC (History)
4 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:
RESOLVED ANSWERED

Description Allie Miller 2014-05-30 10:20:05 UTC
When attempting to build an Android Library project in Visual Studio 2013, the project builds successfully. However, when you attempt to build the project from the command line, the following error appears:

"The application which this project type is based on was not found"

*Steps to Reproduce*
1) Open attached library project in Visual Studio.
2) Observe that the project builds successfully.
3) Open the command line prompt and attempt to build the project.

*Expected Results*
Project builds successfully from command line.

*Actual Results*
The error message listed above appears

*Version Information*
Microsoft Visual Studio Ultimate 2013
Version 12.0.30501.00 Update 2
Microsoft .NET Framework
Version 4.5.50938

Installed Version: Ultimate

Architecture and Modeling Tools   06181-004-0449004-02740
Microsoft Architecture and Modeling Tools
    
UML® and Unified Modeling Language™ are trademarks or registered trademarks of the Object Management Group, Inc. in the United States and other countries.

LightSwitch for Visual Studio 2013   06181-004-0449004-02740
Microsoft LightSwitch for Visual Studio 2013

Office Developer Tools - May 2014 Update ENU   06181-004-0449004-02740
Microsoft Office Developer Tools for Visual Studio 2013 - May 2014 Update ENU

Team Explorer for Visual Studio 2013   06181-004-0449004-02740
Microsoft Team Explorer for Visual Studio 2013

Visual Basic 2013   06181-004-0449004-02740
Microsoft Visual Basic 2013

Visual C# 2013   06181-004-0449004-02740
Microsoft Visual C# 2013

Visual C++ 2013   06181-004-0449004-02740
Microsoft Visual C++ 2013

Visual F# 2013   06181-004-0449004-02740
Microsoft Visual F# 2013

Visual Studio 2013 Code Analysis Spell Checker   06181-004-0449004-02740
Microsoft® Visual Studio® 2013 Code Analysis Spell Checker

Portions of International CorrectSpell™ spelling correction system © 1993 by Lernout & Hauspie Speech Products N.V. All rights reserved.

The American Heritage® Dictionary of the English Language, Third Edition Copyright © 1992 Houghton Mifflin Company. Electronic version licensed from Lernout & Hauspie Speech Products N.V. All rights reserved.

ASP.NET and Web Tools   2013.2.50425
Microsoft Web Developer Tools contains the following components:
Support for creating and opening ASP.NET web projects
Browser Link: A communication channel between Visual Studio and browsers
Editor extensions for HTML, CSS, and JavaScript
Page Inspector: Inspection tool for ASP.NET web projects
Scaffolding: A framework for building and running code generators
Server Explorer extensions for Windows Azure Web Sites
Web publishing: Extensions for publishing ASP.NET web projects to hosting providers, on-premises servers, or Windows Azure

ASP.NET Web Frameworks and Tools 2012.2   4.1.21001.0
For additional information, visit http://go.microsoft.com/fwlink/?LinkID=309563

ASP.NET Web Frameworks and Tools 2013   5.1.20409.0
For additional information, visit http://www.asp.net/

Common Azure Tools   1.1
Provides common services for use by Azure Mobile Services and Windows Azure Tools.

NuGet Package Manager   2.8.50313.46
NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.

PreEmptive Analytics Visualizer   1.2
Microsoft Visual Studio extension to visualize aggregated summaries from the PreEmptive Analytics product.

SQL Server Data Tools   12.0.30919.1
Microsoft SQL Server Data Tools

Windows Azure Mobile Services Tools   1.1
Windows Azure Mobile Services Tools

Windows Phone 8.1 SDK Integration   1.0
This package integrates the tools for the Windows Phone 8.1 SDK into the menus and controls of Visual Studio.

Workflow Manager Tools 1.0   1.0
This package contains the necessary Visual Studio integration components for Workflow Manager.

Xamarin   3.0.54.0 (d3cf238e3845e930e312b6ec9b4c6c5437c33067)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android

Xamarin.Android   4.12.4.20 (b5dc5ce91305e19de51d71a1122c109719c4bc34)
Visual Studio plugin to enable development for Xamarin.Android.

Xamarin.iOS   3.0.54.0 (d3cf238e3845e930e312b6ec9b4c6c5437c33067)
Visual Studio extension to enable development for Xamarin.iOS
Comment 2 Mohit Kheterpal 2014-06-02 11:02:36 UTC
I have tried to reproduce this issue but unable to reproduce it.

I am able to build the attached sample in VS 2013 and via command prompt as shown in screencast : http://screencast.com/t/rUtOChscaDO
Comment 3 PJ 2014-06-02 16:17:12 UTC
Mohit, it does look like Allie in comment 1 mentions that this does not happen with every attempt for the user. Also, you may not be building the exact same way. You're building by just passing the solution to msbuild, and the user may be building the project instead.

Allie, any other description of the frequency or reproducibility of the issue? What exactly did you run to reproduce?
Comment 4 Allie Miller 2014-06-02 16:51:13 UTC
One thing to note is that the reported user is running the devenv from the command line (not msbuild as shown in the screencast) with the following:

devenv /Rebuild Debug "projectnamehere.sln"

I know the differences aren't much, but I also used the devenv command from VS2013 with the build switch which resulted in the reported error.

However, in regards to how reproducible it is, is questionable. I haven't gotten this error consistently on every build attempt. I will ask the reported user how often it happens to them and see if I can get more specifics on exact steps to take.
Comment 6 Jonathan Pryor 2014-06-04 16:36:35 UTC
If it works with MSBuild and fails with devenv, then I would suggest using MSBuild. ;-)

That said...

Kzu: Lord of all things VS, do you have any ideas why a build would consistently work with MSBuild and fail with devenv?
Comment 7 Daniel Cazzulino 2016-12-26 18:58:57 UTC
Since we haven't received any further info, we're tentatively closing the issue since this works with the recommended way of building from command-line, which is to use msbuild, rather than devenv.

Please do reopen the issue if that scenario isn't working.

Thanks