-
Notifications
You must be signed in to change notification settings - Fork 537
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Xamarin.Android.Build.Tasks] ignore mdbs and non-portable pdbs
Fixes: #2230 We currently spend some time during builds converting symbol files if `DebugType=Full` or `DebugType=PdbOnly` is used. These are older symbol formats, and we have already done the work to use `DebugType=Portable` everywhere in the Xamarin templates. My thought is to just remove support for these symbols by default unless `$(AndroidLegacySymbols)` is set to `True`. This way if a problem comes up, developers can opt-in to the old behavior. Eventually we may phase out support completely, but it may not matter to leave it in. I updated various tests here to make sure we continue to test both `Full` and `Portable` in `DebuggingTest.cs`. ~~ XA0122 ~~ I added a new warning, for cases where a PCL `<ProjectReference/>` have `DebugType=Full` set. This seems like the only likely cause a user could hit an issue. I added a test for this scenario. Other changes: * I found the `_CollectMdbFiles` MSBuild target is completely unused. It should have been removed in 2ea31e6, but we can remove it now. * I found a place `$(AllowedReferenceRelatedFileExtensions)` was adding duplicate values. We should have removed this in e390702.
- Loading branch information
1 parent
9e1837e
commit db98442
Showing
18 changed files
with
235 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
--- | ||
title: Xamarin.Android warning XA0122 | ||
description: XA0122 warning code | ||
ms.date: 11/01/2019 | ||
--- | ||
# Xamarin.Android warning XA0122 | ||
|
||
## Issue | ||
|
||
In Xamarin.Android 10.2, Windows-specific symbol formats were | ||
deprecated. These are specified by the `$(DebugType)` MSBuild property | ||
in `.csproj` files, such as: | ||
|
||
* `<DebugType>full</DebugType>` | ||
* `<DebugType>pdbonly</DebugType>` | ||
|
||
Xamarin.Android's build system has to convert these symbols to a | ||
format supported by the Mono runtime. This hurts build performance. | ||
|
||
Since these symbol formats are now deprecated, debugging and | ||
breakpoints will not work for any referenced projects using | ||
`DebugType=full` or `DebugType=pdbonly`. | ||
|
||
See the [msbuild documentation][msbuild_common] for details about | ||
`$(DebugType)`. | ||
|
||
[msbuild_common]: https://docs.microsoft.com/en-us/visualstudio/msbuild/common-msbuild-project-properties | ||
|
||
## Solution | ||
|
||
Any projects referenced by a Xamarin.Android project should use: | ||
|
||
```xml | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | ||
<!-- ... --> | ||
<DebugType>portable</DebugType> | ||
</PropertyGroup> | ||
``` | ||
|
||
Alternatively, you could set `$(AndroidLegacySymbols)`: | ||
|
||
```xml | ||
<PropertyGroup> | ||
<!-- ... --> | ||
<AndroidLegacySymbols>True</AndroidLegacySymbols> | ||
</PropertyGroup> | ||
``` | ||
|
||
This will restore the legacy symbol behavior, at the cost of longer | ||
build times. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.