From 0418be0fcbbfd3a489fa60381129102abb4937e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Fri, 21 Apr 2017 20:12:15 +0200 Subject: [PATCH 1/2] Build netstandard.dll and System.Drawing.Primitives.dll facades The old project for System.Drawing.Primitives was removed in favor of building the assembly with the existing logic in Mono. Also add them to the bundle since we can't rebuild them if we just have the bundle. --- Xamarin.Android.sln | 13 ++- build-tools/bundle/bundle-path.targets | 2 +- build-tools/bundle/bundle.mdproj | 12 +++ .../mono-runtimes/ProfileAssemblies.projitems | 9 +++ .../Properties/AssemblyInfo.cs | 10 --- .../System.Drawing.Primitives.csproj | 79 ------------------- .../System.Drawing.Primitives.mdproj | 29 +++++++ .../System.Drawing.Primitives.targets | 22 ++++++ src/netstandard/netstandard.mdproj | 29 +++++++ src/netstandard/netstandard.targets | 22 ++++++ 10 files changed, 136 insertions(+), 91 deletions(-) delete mode 100644 src/System.Drawing.Primitives/Properties/AssemblyInfo.cs delete mode 100644 src/System.Drawing.Primitives/System.Drawing.Primitives.csproj create mode 100644 src/System.Drawing.Primitives/System.Drawing.Primitives.mdproj create mode 100644 src/System.Drawing.Primitives/System.Drawing.Primitives.targets create mode 100644 src/netstandard/netstandard.mdproj create mode 100644 src/netstandard/netstandard.targets diff --git a/Xamarin.Android.sln b/Xamarin.Android.sln index 703d3c282a0..01220fe8f55 100644 --- a/Xamarin.Android.sln +++ b/Xamarin.Android.sln @@ -83,7 +83,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "OpenTK", "src\OpenTK-1.0\Op EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "libZipSharp", "external\LibZipSharp\libZipSharp.csproj", "{E248B2CA-303B-4645-ADDC-9D4459D550FD}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "System.Drawing.Primitives", "src\System.Drawing.Primitives\System.Drawing.Primitives.csproj", "{C9FF2E4D-D927-479E-838B-647C16763F64}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "System.Drawing.Primitives", "src\System.Drawing.Primitives\System.Drawing.Primitives.mdproj", "{C9FF2E4D-D927-479E-838B-647C16763F64}" EndProject Project("{9344BDBB-3E7F-41FC-A0DD-8665D75EE146}") = "libzip-windows", "build-tools\libzip-windows\libzip-windows.mdproj", "{0DE278D6-000F-4001-BB98-187C0AF58A61}" EndProject @@ -109,6 +109,8 @@ Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "Xamarin.Android.Build.Tests EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "create-vsix", "build-tools\create-vsix\create-vsix.csproj", "{94756FEB-1F64-411D-A18E-81B5158F776A}" EndProject +Project("{9344BDBB-3E7F-41FC-A0DD-8665D75EE146}") = "netstandard", "src\netstandard\netstandard.mdproj", "{93614CB8-4564-43B9-93B0-4AF4B3B16AAE}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|AnyCPU = Debug|AnyCPU @@ -499,6 +501,14 @@ Global {94756FEB-1F64-411D-A18E-81B5158F776A}.XAIntegrationDebug|AnyCPU.Build.0 = Debug|Any CPU {94756FEB-1F64-411D-A18E-81B5158F776A}.XAIntegrationRelease|AnyCPU.ActiveCfg = Debug|Any CPU {94756FEB-1F64-411D-A18E-81B5158F776A}.XAIntegrationRelease|AnyCPU.Build.0 = Debug|Any CPU + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE}.Debug|AnyCPU.ActiveCfg = Debug|Any CPU + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE}.Debug|AnyCPU.Build.0 = Debug|Any CPU + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE}.Release|AnyCPU.ActiveCfg = Release|Any CPU + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE}.Release|AnyCPU.Build.0 = Release|Any CPU + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE}.XAIntegrationDebug|AnyCPU.ActiveCfg = Debug|Any CPU + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE}.XAIntegrationDebug|AnyCPU.Build.0 = Debug|Any CPU + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE}.XAIntegrationRelease|AnyCPU.ActiveCfg = Debug|Any CPU + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE}.XAIntegrationRelease|AnyCPU.Build.0 = Debug|Any CPU EndGlobalSection GlobalSection(NestedProjects) = preSolution {8FF78EB6-6FC8-46A7-8A15-EBBA9045C5FA} = {E351F97D-EA4F-4E7F-AAA0-8EBB1F2A4A62} @@ -551,6 +561,7 @@ Global {A87352E6-CE7F-4346-B6B1-586AE931C0A7} = {864062D3-A415-4A6F-9324-5820237BA058} {BD1D66BF-5AC7-4926-8EBE-B2198A112EB0} = {CAB438D8-B0F5-4AF0-BEBD-9E2ADBD7B483} {94756FEB-1F64-411D-A18E-81B5158F776A} = {E351F97D-EA4F-4E7F-AAA0-8EBB1F2A4A62} + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE} = {04E3E11E-B47D-4599-8AFC-50515A95E715} EndGlobalSection GlobalSection(MonoDevelopProperties) = preSolution Policies = $0 diff --git a/build-tools/bundle/bundle-path.targets b/build-tools/bundle/bundle-path.targets index 530ca7e20f9..0e5bcf5ec66 100644 --- a/build-tools/bundle/bundle-path.targets +++ b/build-tools/bundle/bundle-path.targets @@ -24,7 +24,7 @@ - bundle-v17-$(Configuration)-$(HostOS)-libzip=$(_LibZipHash),llvm=$(_LlvmHash),mono=$(_MonoHash).zip + bundle-v18-$(Configuration)-$(HostOS)-libzip=$(_LibZipHash),llvm=$(_LlvmHash),mono=$(_MonoHash).zip diff --git a/build-tools/bundle/bundle.mdproj b/build-tools/bundle/bundle.mdproj index 18118232e81..b6e359cfce1 100644 --- a/build-tools/bundle/bundle.mdproj +++ b/build-tools/bundle/bundle.mdproj @@ -49,5 +49,17 @@ False Never + + {C9FF2E4D-D927-479E-838B-647C16763F64} + System.Drawing.Primitives + False + Never + + + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE} + netstandard + False + Never + diff --git a/build-tools/mono-runtimes/ProfileAssemblies.projitems b/build-tools/mono-runtimes/ProfileAssemblies.projitems index cfc26cef68a..db880b73b71 100644 --- a/build-tools/mono-runtimes/ProfileAssemblies.projitems +++ b/build-tools/mono-runtimes/ProfileAssemblies.projitems @@ -132,6 +132,15 @@ + + + diff --git a/src/System.Drawing.Primitives/Properties/AssemblyInfo.cs b/src/System.Drawing.Primitives/Properties/AssemblyInfo.cs deleted file mode 100644 index 9dbf5a4bee4..00000000000 --- a/src/System.Drawing.Primitives/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,10 +0,0 @@ -using System.Reflection; -using System.Runtime.CompilerServices; - -// Assembly forwards -[assembly: TypeForwardedTo (typeof (System.Drawing.Point))] -[assembly: TypeForwardedTo (typeof (System.Drawing.PointF))] -[assembly: TypeForwardedTo (typeof (System.Drawing.Rectangle))] -[assembly: TypeForwardedTo (typeof (System.Drawing.RectangleF))] -[assembly: TypeForwardedTo (typeof (System.Drawing.Size))] -[assembly: TypeForwardedTo (typeof (System.Drawing.SizeF))] diff --git a/src/System.Drawing.Primitives/System.Drawing.Primitives.csproj b/src/System.Drawing.Primitives/System.Drawing.Primitives.csproj deleted file mode 100644 index 724f452cf61..00000000000 --- a/src/System.Drawing.Primitives/System.Drawing.Primitives.csproj +++ /dev/null @@ -1,79 +0,0 @@ - - - - Debug - AnyCPU - {EFBA0AD7-5A72-4C68-AF49-83D382785DCF};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - {C9FF2E4D-D927-479E-838B-647C16763F64} - Library - System.Drawing - System.Drawing.Primitives - true - false - Resources - Assets - false - - - - - $(MonoSourceFullPath)\mcs\class\mono.pub - - - true - full - false - ..\..\bin\$(Configuration)\lib\xbuild-frameworks\MonoAndroid\v1.0\Facades - DEBUG; - prompt - 4 - false - - - true - ..\..\bin\$(Configuration)\lib\xbuild-frameworks\MonoAndroid\v1.0\Facades - prompt - 4 - false - - - - $(OutputPath)..\mscorlib.dll - False - - - $(OutputPath)..\System.dll - False - - - $(OutputPath)..\System.Core.dll - False - - - $(OutputPath)..\System.Xml.dll - False - - - $(OutputPath)..\Java.Interop.dll - False - - - - - - - - - - {66CF299A-CE95-4131-BCD8-DB66E30C4BF7} - Mono.Android - False - - - {3F1F2F50-AF1A-4A5A-BEDB-193372F068D7} - Xamarin.Android.Build.Tasks - False - False - - - \ No newline at end of file diff --git a/src/System.Drawing.Primitives/System.Drawing.Primitives.mdproj b/src/System.Drawing.Primitives/System.Drawing.Primitives.mdproj new file mode 100644 index 00000000000..f231340f7cc --- /dev/null +++ b/src/System.Drawing.Primitives/System.Drawing.Primitives.mdproj @@ -0,0 +1,29 @@ + + + Debug + AnyCPU + GenericProject + {C9FF2E4D-D927-479E-838B-647C16763F64} + ..\..\bin\$(Configuration)\lib\xbuild-frameworks\MonoAndroid\v1.0\Facades + + + + + + + + + + ResolveReferences; + _BuildSystemDrawingPrimitivesFacade + + + + + + {66CF299A-CE95-4131-BCD8-DB66E30C4BF7} + Mono.Android + False + + + diff --git a/src/System.Drawing.Primitives/System.Drawing.Primitives.targets b/src/System.Drawing.Primitives/System.Drawing.Primitives.targets new file mode 100644 index 00000000000..00b4e787e97 --- /dev/null +++ b/src/System.Drawing.Primitives/System.Drawing.Primitives.targets @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + diff --git a/src/netstandard/netstandard.mdproj b/src/netstandard/netstandard.mdproj new file mode 100644 index 00000000000..bb156e6d507 --- /dev/null +++ b/src/netstandard/netstandard.mdproj @@ -0,0 +1,29 @@ + + + Debug + AnyCPU + GenericProject + {93614CB8-4564-43B9-93B0-4AF4B3B16AAE} + ..\..\bin\$(Configuration)\lib\xbuild-frameworks\MonoAndroid\v1.0\Facades + + + + + + + + + + ResolveReferences; + _BuildNetstandardFacade + + + + + + {66CF299A-CE95-4131-BCD8-DB66E30C4BF7} + Mono.Android + False + + + diff --git a/src/netstandard/netstandard.targets b/src/netstandard/netstandard.targets new file mode 100644 index 00000000000..8349a475724 --- /dev/null +++ b/src/netstandard/netstandard.targets @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + From 533a19174fb8515e8bdd3431de6763047e1accff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Fri, 21 Apr 2017 19:01:42 +0200 Subject: [PATCH 2/2] [Xamarin.Android.Build.Tasks] Update facades list in MobileProfile netstandard.dll and System.ValueTuple.dll were missing. --- .../Linker/Mobile.Tuner/MobileProfile.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Xamarin.Android.Build.Tasks/Linker/Mobile.Tuner/MobileProfile.cs b/src/Xamarin.Android.Build.Tasks/Linker/Mobile.Tuner/MobileProfile.cs index c0fd026c417..1df80e5543c 100644 --- a/src/Xamarin.Android.Build.Tasks/Linker/Mobile.Tuner/MobileProfile.cs +++ b/src/Xamarin.Android.Build.Tasks/Linker/Mobile.Tuner/MobileProfile.cs @@ -179,6 +179,7 @@ public abstract class MobileProfile : Profile { "System.Threading.ThreadPool", "System.Threading.Timer", "System.Threading", + "System.ValueTuple", "System.Xml.ReaderWriter", "System.Xml.XDocument", "System.Xml.XPath.XDocument", @@ -186,6 +187,7 @@ public abstract class MobileProfile : Profile { "System.Xml.XmlDocument", "System.Xml.XmlSerializer", "System.Xml.Xsl.Primitives", + "netstandard", }; protected override bool IsSdk (string assemblyName)