forked from dotnet/macios
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[d16-2] [msbuild] Add reference to
System.Drawing.Common.dll
to XI …
…projects. (dotnet#6035) * [msbuild] Add reference to `System.Drawing.Common.dll` to XI projects. Fixes mono/mono#13483 : ``` @akoeplinger: Since we moved types from Mono.Android.dll and Xamarin.iOS/WatchOS/TVOS.dll to System.Drawing.Common.dll user projects would fail to compile. We need to add some msbuild logic to add a reference to the assembly automatically. ``` * [msbuild] Implement the same fix for XM projects as well. * [msbuild] Update Xamarin.iOS.Tasks.TargetTests.GetReferencedAssemblies_* tests. We're including a new assembly, which means the Xamarin.iOS.Tasks.TargetTests.GetReferencedAssemblies_* must be updated accordingly. Also modify these tests so that test assert that fails lists the actual assembly that's missing, i.e. instead of this: 1) Test Failure : Xamarin.iOS.Tasks.TargetTests.GetReferencedAssemblies_Executable #1 Expected: 6 But was: 7 we now print: 1) Test Failure : Xamarin.iOS.Tasks.TargetTests.GetReferencedAssemblies_Executable References Expected: equivalent to < "mscorlib.dll", "MyLibrary.dll", "System.Core.dll", "System.dll", "System.Xml.dll", "Xamarin.iOS.dll" > But was: < "mscorlib.dll", "MyLibrary.dll", "System.Core.dll", "System.dll", "System.Drawing.Common.dll", "System.Xml.dll", "Xamarin.iOS.dll" > * [tests] Adjust Xamarin.MMP.Tests.AssemblyReferencesTests.ShouldNotAllowReference_ToSystemDrawing. The test was verifying that referencing System.Drawing.dll and trying to use System.Drawing.RectangleF would fail to compile (because System.Drawing.dll shouldn't be resolved in this case). The addition of System.Drawing.Common.dll breaks this assumption, because now we ship System.Drawing.RectangleF, so the code that was supposed to fail to compile works just fine instead. So modify the test to verify that there's no System.Drawing.dll in the final bundle. * Remove workarounds for mono/mono#13483. * [msbuild] Create a way out if automatically referencing System.Drawing.Common.dll causes problems. * [msbuild] Adjust variable name and boolean logic according to review.
- Loading branch information
1 parent
557d435
commit daf5006
Showing
8 changed files
with
57 additions
and
21 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
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