diff --git a/Documentation/guides/messages/README.md b/Documentation/guides/messages/README.md
index 42decb96a80..bfd2c6bb54f 100644
--- a/Documentation/guides/messages/README.md
+++ b/Documentation/guides/messages/README.md
@@ -165,6 +165,7 @@ Please disable fast deployment in the Visual Studio project property pages or ed
+ [XA4310](xa4310.md): \`$(AndroidSigningKeyStore)\` file \`{keystore}\` could not be found.
+ XA4311: The application won't contain the paired Wear package because the Wear application package APK is not created yet. If building on the command line, be sure to build the "SignAndroidPackage" target.
+ [XA4312](xa4312.md): Referencing an Android Wear application project from an Android application project is deprecated.
++ [XA4313](xa4313.md): Framework assembly has been deprecated.
## XA5xxx: GCC and toolchain
diff --git a/Documentation/guides/messages/xa4313.md b/Documentation/guides/messages/xa4313.md
new file mode 100644
index 00000000000..2788866e729
--- /dev/null
+++ b/Documentation/guides/messages/xa4313.md
@@ -0,0 +1,20 @@
+---
+title: Xamarin.Android error/warning XA4313
+description: XA4313 error/warning code
+ms.date: 03/19/2021
+---
+# Xamarin.Android error/warning XA4313
+
+The specified Framework assembly has been deprecated.
+You need an upgrade to use the specified NuGet Package.
+
+For example, to upgrade `OpenTK-1.0` remove
+
+ ''
+
+from your csproj then add
+
+ ''
+
+to your project to upgrade.
+
diff --git a/build-tools/scripts/BuildEverything.mk b/build-tools/scripts/BuildEverything.mk
index ebf9b70a694..27c5d96bcb8 100644
--- a/build-tools/scripts/BuildEverything.mk
+++ b/build-tools/scripts/BuildEverything.mk
@@ -1,4 +1,4 @@
-.PHONY: leeroy jenkins leeroy-all opentk-jcw
+.PHONY: leeroy jenkins leeroy-all
.PHONY: create-vsix
#
@@ -24,15 +24,8 @@ ifneq ("$(wildcard $(topdir)/external/monodroid/Makefile)","")
endif
$(MAKE) leeroy $(ZIP_OUTPUT)
-leeroy: leeroy-all framework-assemblies opentk-jcw
+leeroy: leeroy-all framework-assemblies
leeroy-all:
$(call MSBUILD_BINLOG,leeroy-all,$(_SLN_BUILD)) /restore $(SOLUTION) /p:Configuration=$(CONFIGURATION) $(_MSBUILD_ARGS)
$(call MSBUILD_BINLOG,leeroy-all,$(_SLN_BUILD)) /restore tools/xabuild/xabuild.csproj /p:Configuration=$(CONFIGURATION) $(_MSBUILD_ARGS)
-
-opentk-jcw:
- $(foreach api_level, $(API_LEVELS), \
- touch bin/$(CONFIGURATION)/lib/xamarin.android/xbuild-frameworks/MonoAndroid/*/OpenTK-1.0.dll; \
- $(call MSBUILD_BINLOG,OpenTK-JCW,$(_SLN_BUILD)) $(MSBUILD_FLAGS) src/OpenTK-1.0/OpenTK.csproj \
- /t:GenerateJavaCallableWrappers /p:Configuration=$(CONFIGURATION) $(_MSBUILD_ARGS) \
- /p:AndroidApiLevel=$(api_level) /p:AndroidPlatformId=$(word $(api_level), $(ALL_PLATFORM_IDS)) /p:AndroidFrameworkVersion=$(word $(api_level), $(ALL_FRAMEWORKS)) || exit 1; )
diff --git a/src/OpenTK-1.0/OpenTK.csproj b/src/OpenTK-1.0/OpenTK.csproj
index be5aea87521..8bb80733e8e 100644
--- a/src/OpenTK-1.0/OpenTK.csproj
+++ b/src/OpenTK-1.0/OpenTK.csproj
@@ -540,10 +540,5 @@
MONODROID;MINIMAL;MOBILE;OPENTK_1;OPENTK_1_0
- 1.8
- 1.6
- $(JavaCallableWrapperOutputPathAbs)$(AssemblyName).dll
- $(MSBuildProjectDirectory)\$(IntermediateOutputPath)\$(AssemblyName).dll
-
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 ad526057040..f49d9492ea9 100644
--- a/src/Xamarin.Android.Build.Tasks/Linker/Mobile.Tuner/MobileProfile.cs
+++ b/src/Xamarin.Android.Build.Tasks/Linker/Mobile.Tuner/MobileProfile.cs
@@ -53,8 +53,6 @@ public abstract class MobileProfile : Profile {
"Mono.Data.Sqlite",
"Mono.Posix",
"Mono.Security",
- "OpenTK",
- "OpenTK-1.0",
// Facades assemblies (PCL)
"Microsoft.Win32.Primitives",
"Microsoft.Win32.Registry.AccessControl",
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/Resources.resx b/src/Xamarin.Android.Build.Tasks/Properties/Resources.resx
index 85b877827ce..20a4fe0ce2f 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/Resources.resx
+++ b/src/Xamarin.Android.Build.Tasks/Properties/Resources.resx
@@ -723,6 +723,15 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
Referencing the Android Wear application project '{0}' from an Android application project is deprecated and will no longer be supported in a future version of Xamarin.Android. Remove the Android Wear application project reference from the Android application project and distribute the Wear application as a standalone application instead.The following are literal names and should not be translated: Android Wear, Android, Wear.
{0} - The referenced Android Wear project.
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+ Missing Android NDK toolchains directory '{0}'. Please install the Android NDK.
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.cs.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.cs.xlf
index 2148b4cabee..1f2646def1f 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.cs.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.cs.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.de.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.de.xlf
index 757c9ddeeab..33e797d4530 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.de.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.de.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.es.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.es.xlf
index e340a559012..0bd683e4232 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.es.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.es.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.fr.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.fr.xlf
index d6fae7ae8c2..c35f8ad543b 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.fr.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.fr.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.it.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.it.xlf
index 4c40102a790..828293d14bf 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.it.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.it.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ja.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ja.xlf
index 365f133692d..2a7d4a1477d 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ja.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ja.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ko.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ko.xlf
index ea47518f928..a32958ed82c 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ko.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ko.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.pl.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.pl.xlf
index 29603dfb344..e12893a8d97 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.pl.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.pl.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.pt-BR.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.pt-BR.xlf
index 23c49ef9b05..48e3095099a 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.pt-BR.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.pt-BR.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ru.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ru.xlf
index b5bd580229f..4f6707cac06 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ru.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.ru.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.tr.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.tr.xlf
index dd7410dfeee..72396790318 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.tr.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.tr.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.zh-Hans.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.zh-Hans.xlf
index 20f031ab488..e36a508ed3c 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.zh-Hans.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.zh-Hans.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.zh-Hant.xlf b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.zh-Hant.xlf
index a5dcf86e75d..21b50c3fc08 100644
--- a/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.zh-Hant.xlf
+++ b/src/Xamarin.Android.Build.Tasks/Properties/xlf/Resources.zh-Hant.xlf
@@ -71,6 +71,18 @@ The following are literal names and should not be translated: ABI, 'libs/armeabi
The following are literal names and should not be translated: ABI, NuGet
{0} - The native library file path
{1} - Either the name of the NuGet package or a path to the native library
+
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The built-in '{0}' reference has been deprecated.
+Remove the '{0}' reference from your project and add the '{1}' NuGet package instead.
+
+ The following are literal names and should not be translated:
+{0} - The Assembly name which is deprecated
+{1} - A Nuget package name.
+
diff --git a/src/Xamarin.Android.Build.Tasks/Tasks/GenerateJavaStubs.cs b/src/Xamarin.Android.Build.Tasks/Tasks/GenerateJavaStubs.cs
index 0bc8cd00396..0cb9c56064c 100644
--- a/src/Xamarin.Android.Build.Tasks/Tasks/GenerateJavaStubs.cs
+++ b/src/Xamarin.Android.Build.Tasks/Tasks/GenerateJavaStubs.cs
@@ -163,8 +163,11 @@ void Run (DirectoryAssemblyResolver res)
Log.LogDebugMessage ($"Skipping Java Stub Generation for {asm.ItemSpec}");
continue;
}
- allTypemapAssemblies.Add (asm.ItemSpec);
- userAssemblies.Add (Path.GetFileNameWithoutExtension (asm.ItemSpec), asm.ItemSpec);
+ if (!allTypemapAssemblies.Contains (asm.ItemSpec))
+ allTypemapAssemblies.Add (asm.ItemSpec);
+ string name = Path.GetFileNameWithoutExtension (asm.ItemSpec);
+ if (!userAssemblies.ContainsKey (name))
+ userAssemblies.Add (name, asm.ItemSpec);
}
// Step 1 - Find all the JLO types
diff --git a/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/BuildTest.cs b/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/BuildTest.cs
index 562584ce94a..5f23386e5db 100644
--- a/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/BuildTest.cs
+++ b/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/BuildTest.cs
@@ -3986,6 +3986,36 @@ public void XA1018 ()
}
}
+ [Test]
+ [Category ("DotNetIgnore")] // OpenTK not even shipped for .net 6.
+ public void XA4313 ()
+ {
+ var proj = new XamarinAndroidApplicationProject () {
+ References = {
+ new BuildItem.Reference ("OpenTK-1.0")
+ },
+ };
+ using (var builder = CreateApkBuilder ()) {
+ builder.ThrowOnBuildFailure = false;
+ Assert.IsTrue (builder.Build (proj), "Build should have succeeded.");
+ string error = builder.LastBuildOutput
+ .SkipWhile (x => !x.StartsWith ("Build succeeded."))
+ .FirstOrDefault (x => x.Contains ("warning XA4313"));
+ Assert.IsNotNull (error, "Build should have failed with XA4313.");
+ }
+ }
+
+ [Test]
+ public void OpenTKNugetWorks ()
+ {
+ var proj = new XamarinAndroidApplicationProject ();
+ proj.PackageReferences.Add (KnownPackages.Xamarin_Legacy_OpenTK);
+ using (var builder = CreateApkBuilder ()) {
+ builder.ThrowOnBuildFailure = false;
+ Assert.IsTrue (builder.Build (proj), "Build should have succeeded.");
+ }
+ }
+
static readonly object [] XA1027XA1028Source = new object [] {
new object [] {
/* linkTool */ "r8",
diff --git a/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.ProjectTools/Android/KnownPackages.cs b/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.ProjectTools/Android/KnownPackages.cs
index 227c4ed9dcd..d6c44a3d1ec 100644
--- a/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.ProjectTools/Android/KnownPackages.cs
+++ b/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.ProjectTools/Android/KnownPackages.cs
@@ -550,6 +550,11 @@ public static class KnownPackages
Version = "2.4.1",
TargetFramework = "MonoAndroid10",
};
+ public static Package Xamarin_Legacy_OpenTK = new Package {
+ Id = "Xamarin.Legacy.OpenTK",
+ Version = "0.0.1-alpha",
+ TargetFramework = "MonoAndroid10",
+ };
}
}
diff --git a/src/Xamarin.Android.Build.Tasks/Utilities/MonoAndroidHelper.Linker.cs b/src/Xamarin.Android.Build.Tasks/Utilities/MonoAndroidHelper.Linker.cs
index 167c2033d06..8a7d64ea9d1 100644
--- a/src/Xamarin.Android.Build.Tasks/Utilities/MonoAndroidHelper.Linker.cs
+++ b/src/Xamarin.Android.Build.Tasks/Utilities/MonoAndroidHelper.Linker.cs
@@ -19,6 +19,7 @@ public partial class MonoAndroidHelper
"Mono.Posix.dll",
};
internal static readonly HashSet FrameworkAssembliesToTreatAsUserAssemblies = new HashSet (StringComparer.OrdinalIgnoreCase) {
+ "OpenTK-1.0.dll",
"Mono.Android.Support.v13.dll",
"Mono.Android.Support.v4.dll",
"Xamarin.Android.NUnitLite.dll",
diff --git a/src/Xamarin.Android.Build.Tasks/Xamarin.Android.Build.Tasks.targets b/src/Xamarin.Android.Build.Tasks/Xamarin.Android.Build.Tasks.targets
index 441528321d8..b622d00418a 100644
--- a/src/Xamarin.Android.Build.Tasks/Xamarin.Android.Build.Tasks.targets
+++ b/src/Xamarin.Android.Build.Tasks/Xamarin.Android.Build.Tasks.targets
@@ -189,8 +189,6 @@
<_SharedRuntimeAssemblies Include="$(_SharedRuntimeBuildPath)$(AndroidFrameworkVersion)\Mono.Android.Export.dll" />
<_SharedRuntimeAssemblies Include="$(_SharedRuntimeBuildPath)$(AndroidFrameworkVersion)\Mono.Android.dll" />
- <_SharedRuntimeAssemblies Include="$(_SharedRuntimeBuildPath)$(AndroidFrameworkVersion)\OpenTK.dll" />
- <_SharedRuntimeAssemblies Include="$(_SharedRuntimeBuildPath)$(AndroidFrameworkVersion)\OpenTK-1.0.dll" />
<_JniFrameworkAssembly Include="Mono.Android.dll" />
- <_JniFrameworkAssembly Include="OpenTK-1.0.dll" />
<_JniFrameworkAssembly Include="OpenTK.dll" />
<_JniFrameworkAssembly Include="Xamarin.Android.NUnitLite.dll" />
<_AssembliesToProcess Include="@(ResolvedUserAssemblies)" />
diff --git a/src/Xamarin.Android.Build.Tasks/Xamarin.Android.Legacy.targets b/src/Xamarin.Android.Build.Tasks/Xamarin.Android.Legacy.targets
index 57fde8ee8fb..015a9f566d8 100644
--- a/src/Xamarin.Android.Build.Tasks/Xamarin.Android.Legacy.targets
+++ b/src/Xamarin.Android.Build.Tasks/Xamarin.Android.Legacy.targets
@@ -35,6 +35,7 @@ projects. .NET 5 projects will not import this file.
_CheckProjectItems;
_CheckForContent;
_CheckTargetFramework;
+ _CheckForObsoleteFrameworkAssemblies;
_RemoveLegacyDesigner;
_ValidateAndroidPackageProperties;
$(BuildDependsOn);
@@ -70,6 +71,7 @@ projects. .NET 5 projects will not import this file.
_AddAndroidEnvironmentToCompile;
_CheckForContent;
_CheckTargetFramework;
+ _CheckForObsoleteFrameworkAssemblies;
_RemoveLegacyDesigner;
_ValidateAndroidPackageProperties;
$(BuildDependsOn);
@@ -225,6 +227,15 @@ projects. .NET 5 projects will not import this file.
+
+
+
+