Bug 45029 - Droid target of Xplat projects with '.' in the name fail to compile
Summary: Droid target of Xplat projects with '.' in the name fail to compile
Status: VERIFIED FIXED
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: Android ()
Version: 4.2.0 (C8)
Hardware: PC Windows
: High normal
Target Milestone: 4.3.0 (C9)
Assignee: Mohit Kheterpal
URL:
Depends on:
Blocks:
 
Reported: 2016-10-04 21:31 UTC by David Hathaway
Modified: 2016-12-27 06:55 UTC (History)
8 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 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 David Hathaway 2016-10-04 21:31:35 UTC
Steps to Reproduce

1. Launch Visual Studio with latest C8SR0 installed
2. File > New > Cross-Platform > Blank App (Native Portable), and name it “Foo.Native"
3. Wait for project to be added, and build the "Foo.Native.Droid" project

Expected Result:

Project successfully compiles

Actual Result:

Project fails to compile with following error:

Severity	Code	Description	Project	File	Line	Suppression State
Error		error: <identifier> expected
package foo.native.droid;	Foo.Native.Droid	c:\projects\dwhathaway\customer-samples\MSKCC\TestCompileJavaError\Foo.Native\Foo.Native.Droid\obj\Debug\android\src\foo\native\droid\R.java	8	
Error		error: class, interface, or enum expected
package foo.native.droid;	Foo.Native.Droid	c:\projects\dwhathaway\customer-samples\MSKCC\TestCompileJavaError\Foo.Native\Foo.Native.Droid\obj\Debug\android\src\foo\native\droid\R.java	8	
Error		error: class, interface, or enum expected
package foo.native.droid;	Foo.Native.Droid	c:\projects\dwhathaway\customer-samples\MSKCC\TestCompileJavaError\Foo.Native\Foo.Native.Droid\obj\Debug\android\src\foo\native\droid\R.java	8	

Full build log and version information here:

https://gist.github.com/dwhathaway/930c50c818f382a1aeca8dea8dc2bb23
Comment 1 vga 2016-10-04 21:33:56 UTC
This doesn't repro when unfolding the Android->Blank App template.

So it could be we are running some specific IWizard when unfolding the XF template only.

We will take a good at the XF templates.
Comment 2 vga 2016-10-04 21:38:32 UTC
To clarify, scenarios I just tried:

Android->Blank App => works
Cross-Platform->Blank App (Native) => doesn't work
Cross-Platform->Blank App (Forms) => works

So it's the Cross-Platform (Native) that is breaking when '.' (dots) are used as part of the app name.
Comment 4 Mohit Kheterpal 2016-10-12 14:26:14 UTC
I have checked this issue and able to reproduce it if I use native in the name of application, it does not have any link with ".". 

I am also observing that this issue does not fixed with the build mention in comment 3, and with the latest build of XVS i.e. Xamarin.VisualStudio_4.3.0.23_6eb7239a9a37bfe3a97e46f03a52558f2dac486c.msi

I am not sure what was fixed in this issue.

As of now, I am reopening this issue.

thanks
Comment 5 Adrian Alonso 2016-11-30 14:55:47 UTC
Mohit, could you please specify the repro steps you followed to reproduce the issue? Also, it would be great if you could attach the solution/project you used.
Comment 6 Mohit Kheterpal 2016-12-23 04:34:15 UTC
Steps to reproduce this issue:

1. Launch Visual Studio with latest C8SR1 installed
2. File > New > Cross-Platform > Blank App (Native Portable).
3. Name the Application "Native" (Be specific with Name i.e. "Native")
4. Build the Native.Droid project

You will get the expected error. 

As bug title says that the project that contains .(dot) failed to compile but I observed that project that contains "native" in its name will failed to compile. 

Please let me know if you require more info to reproduce this issue. 

thanks
Comment 7 Daniel Cazzulino 2016-12-26 19:10:35 UTC
Mohit, that looks like an entirely different issue since it completely unrelated to the presense of a dot.

If you agree, could you close this as verified fixed (the original issue) and open a new one with the repro?

THanks
Comment 8 vga 2016-12-27 03:39:58 UTC
Mohit, this bug is about using a '.' (period) as part of the project name, and it has been fixed per Comment #3 on 10/5/16.

If, after that, you have found that there are other things like using 'native' as part of the project name, that may break the build, please log a new bug. It's very confunsing to keep using the same bug for different ones.

I'm closing this one as Resolved Fixed now.
Comment 9 Danish Akhtar 2016-12-27 06:55:09 UTC
I have checked this issue with latest C9 XVS 4.3.0.502 and with master XVS 99.1.0.392 and observed that now this issue is not exists.

Cross-Platform > Blank App (Native Portable) project with '.' is build successfully in VS. Here is the screencast for the same: https://www.screencast.com/t/1mt6Txsywk

Hence closing this issue. However if we use Native as a project name, I am getting build error. So, I have filed Bug 50911 for the same.

Thanks!