Skip to content

Commit ecfff42

Browse files
dellis1972jonathanpeppers
authored andcommitted
Context: 86260ed Context: #8478 Context: #8895 Changes xamarin/monodroid@a574222...9ca6d9f. * xamarin/monodroid@9ca6d9f64: [tools/msbuild] fix fastdev of Localization assemblies (xamarin/monodroid#1464) * xamarin/monodroid@418b1ece6: Remove "Xamarin" from messages (xamarin/monodroid#1468) (xamarin/monodroid#1469) * xamarin/monodroid@07803812f: Revert "Remove "Xamarin" from messages (#146xamarin/monodroid8)" * xamarin/monodroid@cf71c7e6e: Remove "Xamarin" from messages (xamarin/monodroid#1468) Commit 86260ed altered packaging so that *all* assemblies were considered to be ABI-specific, removing even the *idea* of "CPU-agnostic assemblies". This had unforeseen breakage: localization-specific `.resx` & related files were no longer fast deployed to the correct location, breaking *all* of our localization unit tests. This wasn't found in PR #8478 because the localization tests which broke were only run on *nightly* builds, and not run as part of the normal PR process. Oops. The root cause of this is that the `%(TargetPath)` metadata on Satellite assemblies is set to `%(Culture)\%(Filename)%(Extension)` by default. The code we had in place to set `%(TargetPath)` first checked to see if it was empty. In the case of `XX.resource.dll` files, it was NOT empty, and as a result the `XX.resource.dll` files would get deployed to `files/.__override__/%(Culture)` instead of `files/.__override__/%(Abi)/%(Culture)`. Because our assembly loader now *only* looks in the `%(Abi)` directory for its files, the resources were never found. xamarin/monodroid@9ca6d9f64 updates the `_ComputeFastDevFiles` target to check the value of `%(TargetPath)` to see if it is the default value, and if not then update it to use the `%(DestinationSubDirectory)` value. Update the `InstallTests.LocalizedAssemblies_ShouldBeFastDeployed()` unit test to include application-based resource.dll files, so that this failure can be caught during smoke testing.
1 parent b45929f commit ecfff42

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

.external

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
xamarin/monodroid:main@a5742221b314864636f4356173a2535a539c7b2c
1+
xamarin/monodroid:main@9ca6d9f64fce11f04d668ece50ada36de1d7efce

tests/MSBuildDeviceIntegration/Tests/InstallTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ public void LocalizedAssemblies_ShouldBeFastDeployed ()
468468
var app = new XamarinAndroidApplicationProject {
469469
EmbedAssembliesIntoApk = false,
470470
};
471-
InlineData.AddCultureResourcesToProject (lib, "Foo", "CancelButton");
471+
InlineData.AddCultureResourcesToProject (app, "Foo", "CancelButton");
472472
app.References.Add (new BuildItem.ProjectReference ($"..\\{lib.ProjectName}\\{lib.ProjectName}.csproj", lib.ProjectName, lib.ProjectGuid));
473473

474474
using (var libBuilder = CreateDllBuilder (Path.Combine (path, lib.ProjectName)))

0 commit comments

Comments
 (0)