Bug 56192 - csproj loses multidex support on upgrade to 4.5
Summary: csproj loses multidex support on upgrade to 4.5
Status: VERIFIED FIXED
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: Android (show other bugs)
Version: 4.5.0 (15.2)
Hardware: PC Windows
: --- normal
Target Milestone: 15.2.2
Assignee: Bugzilla
URL:
: 56204 56219 56391 (view as bug list)
Depends on:
Blocks:
 
Reported: 2017-05-10 18:59 UTC by Jeremy Kolb
Modified: 2017-05-24 09:52 UTC (History)
12 users (show)

Tags: 15.2R
Is this bug a regression?: Yes
Last known good build: 7.2

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 Jeremy Kolb 2017-05-10 18:59:41 UTC
Previous csproj had <AndroidEnableMultiDex>.  It looks like in 4.5 that's changed to <AndroidEnableMultipleDex>.  This migration is not performed automatically meaning the user has to go in and check the multidex option after upgrading.

Microsoft Visual Studio Professional 2017 
Version 15.2 (26430.4) Release
VisualStudio.15.Release/15.2.0+26430.4
Microsoft .NET Framework
Version 4.7.02053

Installed Version: Professional

Visual Basic 2017   00369-60000-00001-AA771
Microsoft Visual Basic 2017

Visual C# 2017   00369-60000-00001-AA771
Microsoft Visual C# 2017

Visual C++ 2017   00369-60000-00001-AA771
Microsoft Visual C++ 2017

Visual F# 4.1   00369-60000-00001-AA771
Microsoft Visual F# 4.1

Application Insights Tools for Visual Studio Package   8.6.00404.2
Application Insights Tools for Visual Studio

ASP.NET and Web Tools 2017   15.0.30503.0
ASP.NET and Web Tools 2017

Common Azure Tools   1.9
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

JavaScript Language Service   2.0
JavaScript Language Service

JavaScript Project System   2.0
JavaScript Project System

JavaScript UWP Project System   2.0
JavaScript UWP Project System

JetBrains ReSharper Ultimate 2017.1.2    Build 108.0.20170428.75743
JetBrains ReSharper Ultimate package for Microsoft Visual Studio. For more information about ReSharper Ultimate, visit http://www.jetbrains.com/resharper. Copyright © 2017 JetBrains, Inc.

Merq   1.1.17-rc (cba4571)
Command Bus, Event Stream and Async Manager for Visual Studio extensions.

Microsoft Visual Studio VC Package   1.0
Microsoft Visual Studio VC Package

Mono Debugging for Visual Studio   Mono.Debugging.VisualStudio
Support for debugging Mono processes with Visual Studio.

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

TypeScript   2.2.2.0
TypeScript tools for Visual Studio

Visual Studio tools for CMake   1.0
Visual Studio tools for CMake

Visual Studio Tools for Universal Windows Apps   15.0.26430.01
The Visual Studio Tools for Universal Windows apps allow you to build a single universal app experience that can reach every device running Windows 10: phone, tablet, PC, and more. It includes the Microsoft Windows 10 Software Development Kit.

Xamarin   4.5.0.443 (c871575)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin.Android SDK   7.3.0.13 (448f54f)
Xamarin.Android Reference Assemblies and MSBuild support.

Xamarin.iOS and Xamarin.Mac SDK   10.10.0.30 (30b6e87)
Xamarin.iOS and Xamarin.Mac Reference Assemblies and MSBuild support.
Comment 1 Jeremy Kolb 2017-05-10 19:10:21 UTC
Actually it looks like the Xamarin in VS 15.2 is setting <AndroidEnableMultipleDex> when you set the checkbox in the project settings but is only looking at <AndroidEnableMuliDex> when deciding whether to multidex or not.
Comment 2 Joaquin Jares 2017-05-10 19:28:03 UTC
Fixed. This will likely make it in our next release. Thanks for the report!
Comment 3 Brendan Zagaeski (Xamarin Team, assistant) 2017-05-11 00:33:44 UTC
*** Bug 56204 has been marked as a duplicate of this bug. ***
Comment 4 Ruben Buniatyan 2017-05-11 10:56:29 UTC
When will the fix be available? Currently, I'm stuck as my multidex projects throw a bunch of errors because of missing code parts.
Comment 5 dean.ellis 2017-05-11 12:46:59 UTC
*** Bug 56219 has been marked as a duplicate of this bug. ***
Comment 6 Joaquin Jares 2017-05-12 01:29:47 UTC
@Ruben It will be available in the next update. As a temporary workaround, you can manually add <AndroidEnableMultiDex>true</AndroidEnableMultiDex> (or false) manually wherever <AndroidEnableMultipleDex>true</AndroidEnableMultipleDex> (or false) appears in the csproj file for your Android application. That should fix any issues you may heve
Comment 7 Brendan Zagaeski (Xamarin Team, assistant) 2017-05-13 18:13:10 UTC
*** Bug 56391 has been marked as a duplicate of this bug. ***
Comment 9 Jacky Waswani 2017-05-24 09:51:35 UTC
Have verified the bug in 4.5.0.475 & issues is seems to be fixed.

Environment: Xamarin 4.5.0.475 (70f1268)
Xamarin.Android 7.3.1.1 (bc24645)
Xamarin.iOS 10.10.0.35 (4cffddf)

Have validated below scenario's:

1. Created Android proj & have checked Enable multidex option displayed.
2. Check / Uncheck Mutli-Dex box & have Verified that the csproj file is modified with expected values.
3. Have added the AndroidEnableMultipleDex flag in .csproj file & have validated that nothing gets changed with adding that flag.
4. Have crosscheck with deleting the AndroidEnableMultiDex flag from the file & adding AndroidEnableMultipleDex in that file, Mutli-Dex box checkbox displayed as unchecked.