From e5b146f6a393662e499cb8ea40b5641e3199d2e5 Mon Sep 17 00:00:00 2001 From: Jonathan Pryor Date: Mon, 11 Dec 2023 21:38:52 -0500 Subject: [PATCH 1/2] Empty commit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Context: https://github.com/xamarin/xamarin-android/pull/8580 Does It Build™? It *should* build, it *used* to build (on 2023-09-02), but #8580 *doesn't* build, as it's trying to reference `android-toolchain/sdk/build-tools/34.0.0/mainDexClasses.rules`, which doesn't exist. Furthermore, AFAICT `xaprepare` uses `$(XABuildToolsVersion)` to specify which build-tools package is installed, which has been `34` since 326ac889d5, so… how did it build then and why is it failing to build now? What am I missing? From d2f3f928d121f8523022b4ad19a890dd6e42e16f Mon Sep 17 00:00:00 2001 From: Peter Collins Date: Mon, 18 Dec 2023 11:08:25 -0700 Subject: [PATCH 2/2] Build classic tests with build-tools 30.0.3 Commit d954ff63 likely should have broken the d17-5 build in the same way that it is currently failing: "/Users/builder/azdo/_work/4/s/xamarin-android/tests/Mono.Android-Tests/Runtime-MultiDex/Mono.Android-TestsMultiDex.csproj" (default target) (32:6) -> (_CompileToDalvik target) -> MSBUILD : java error JAVA0000: Error in /Users/builder/android-toolchain/sdk/build-tools/34.0.0/mainDexClasses.rules: [/Users/builder/azdo/_work/4/s/xamarin-android/tests/Mono.Android-Tests/Runtime-MultiDex/Mono.Android-TestsMultiDex.csproj] MSBUILD : java error JAVA0000: Failed to read file: /Users/builder/android-toolchain/sdk/build-tools/34.0.0/mainDexClasses.rules [/Users/builder/azdo/_work/4/s/xamarin-android/tests/Mono.Android-Tests/Runtime-MultiDex/Mono.Android-TestsMultiDex.csproj] MSBUILD : java error JAVA0000: Compilation failed [/Users/builder/azdo/_work/4/s/xamarin-android/tests/Mono.Android-Tests/Runtime-MultiDex/Mono.Android-TestsMultiDex.csproj] However, I believe builds including d954ff63 succeeded because the build machines likely still had build-tools 32.0.0 packages installed. Our build pools are re-imaged and refreshed somewhat regularly, and they seemingly no longer have build-tools 32.0.0 as we do not provision it. The d17-5 branch does however still provision build tools 30.0.3 for certain tests, and we can hopefully build our test projects with this version to avoid the error highlighted above. --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index e04b80c64fa..f93e2c31ff3 100644 --- a/Makefile +++ b/Makefile @@ -96,7 +96,7 @@ endif all-tests:: $(call MSBUILD_BINLOG,build-xabuild) /restore tools/xabuild/xabuild.csproj /p:Configuration=$(CONFIGURATION) $(_MSBUILD_ARGS) - MSBUILD="$(MSBUILD)" $(call MSBUILD_BINLOG,all-tests,tools/scripts/xabuild) /restore $(MSBUILD_FLAGS) Xamarin.Android-Tests.sln + MSBUILD="$(MSBUILD)" $(call MSBUILD_BINLOG,all-tests,tools/scripts/xabuild) /restore $(MSBUILD_FLAGS) Xamarin.Android-Tests.sln /p:AndroidSdkBuildToolsVersion=30.0.3 pack-dotnet:: $(call DOTNET_BINLOG,pack-dotnet) $(MSBUILD_FLAGS) -m:1 $(SOLUTION) -t:PackDotNet