From 83752faec8965ca151842f9860d003de192eeedc Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Tue, 22 Jul 2025 13:38:31 -0700 Subject: [PATCH 1/5] Enable building runtime packs for NativeAOT for Android RIDs --- eng/Subsets.props | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/eng/Subsets.props b/eng/Subsets.props index 3c854690a1c0a9..a2bcfff682e753 100644 --- a/eng/Subsets.props +++ b/eng/Subsets.props @@ -47,7 +47,7 @@ true - <_NativeAotSupportedOS Condition="'$(TargetOS)' == 'windows' or '$(TargetOS)' == 'linux' or '$(TargetOS)' == 'osx' or '$(TargetOS)' == 'maccatalyst' or '$(TargetOS)' == 'iossimulator' or '$(TargetOS)' == 'ios' or '$(TargetOS)' == 'tvossimulator' or '$(TargetOS)' == 'tvos' or '$(TargetOS)' == 'freebsd'">true + <_NativeAotSupportedOS Condition="'$(TargetOS)' == 'windows' or '$(TargetOS)' == 'linux' or '$(TargetOS)' == 'osx' or '$(TargetOS)' == 'maccatalyst' or '$(TargetOS)' == 'iossimulator' or '$(TargetOS)' == 'ios' or '$(TargetOS)' == 'tvossimulator' or '$(TargetOS)' == 'tvos' or '$(TargetOS)' == 'freebsd' or '$(TargetOS)' == 'android'">true <_NativeAotSupportedArch Condition="'$(TargetArchitecture)' == 'x64' or '$(TargetArchitecture)' == 'arm64' or '$(TargetArchitecture)' == 'arm' or '$(TargetArchitecture)' == 'loongarch64' or '$(TargetArchitecture)' == 'riscv64' or ('$(TargetOS)' == 'windows' and '$(TargetArchitecture)' == 'x86')">true true @@ -71,6 +71,7 @@ clr+mono+libs+tools+host+packs mono+libs+packs clr+mono+libs+host+packs + clr.nativeaotruntime+clr.nativeaotlibs+mono+libs+packs clr.nativeaotruntime+clr.nativeaotlibs+mono+libs+packs clr.nativeaotruntime+clr.nativeaotlibs+mono+libs+host+packs clr.nativeaotruntime+clr.nativeaotlibs+libs+packs @@ -153,7 +154,7 @@ $(BootstrapSubsets)+clr.nativeaotlibs+clr.nativeaotruntime+libs.native true - + clr.nativeprereqs+clr.iltools+clr.runtime+clr.native+clr.aot+clr.nativeaotlibs+clr.nativeaotruntime+clr.crossarchtools $(AllSubsetsExpansion)+clr.paltests+clr.paltestlist+clr.hosts+clr.jit+clr.alljits+clr.alljitscommunity+clr.spmi+clr.corelib+clr.nativecorelib+clr.tools+clr.toolstests+clr.packages From 6ded26e8247ea29cfeae9416986af9d2cc6c30c8 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Tue, 22 Jul 2025 15:12:47 -0700 Subject: [PATCH 2/5] Correctly handle android RIDs in the NativeAOT targets and use a linker flavor that fixes issues in the java toolchain (pulling from the dotnet/android targets) --- .../BuildIntegration/Microsoft.NETCore.Native.Unix.targets | 5 ++++- .../BuildIntegration/Microsoft.NETCore.Native.targets | 4 +++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Unix.targets b/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Unix.targets index b76e5aca25ace1..334031fe48e9dc 100644 --- a/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Unix.targets +++ b/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Unix.targets @@ -22,6 +22,7 @@ The .NET Foundation licenses this file to you under the MIT license. <_SymbolPrefix Condition="'$(_IsApplePlatform)' == 'true'">_ lld lld + lld bfd 1572864 @@ -142,7 +143,9 @@ The .NET Foundation licenses this file to you under the MIT license. - + + + diff --git a/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.targets b/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.targets index 3cc35d36af2432..c1a3aee2d3c86a 100644 --- a/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.targets +++ b/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.targets @@ -234,7 +234,9 @@ The .NET Foundation licenses this file to you under the MIT license. - + + + From ca66b64a9288f14e606e0e8ce856c7498e8e06f8 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Tue, 22 Jul 2025 15:26:19 -0700 Subject: [PATCH 3/5] Update eng/Subsets.props Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- eng/Subsets.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/Subsets.props b/eng/Subsets.props index a2bcfff682e753..10685e498788ed 100644 --- a/eng/Subsets.props +++ b/eng/Subsets.props @@ -71,7 +71,7 @@ clr+mono+libs+tools+host+packs mono+libs+packs clr+mono+libs+host+packs - clr.nativeaotruntime+clr.nativeaotlibs+mono+libs+packs + clr.nativeaotruntime+clr.nativeaotlibs+mono+libs+packs clr.nativeaotruntime+clr.nativeaotlibs+mono+libs+packs clr.nativeaotruntime+clr.nativeaotlibs+mono+libs+host+packs clr.nativeaotruntime+clr.nativeaotlibs+libs+packs From c6b3dda5da7d0013f7c943f7d08f833a5aa25e46 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Wed, 23 Jul 2025 09:05:18 -0700 Subject: [PATCH 4/5] Apply suggestions from code review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Michal Strehovský --- .../BuildIntegration/Microsoft.NETCore.Native.Unix.targets | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Unix.targets b/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Unix.targets index 334031fe48e9dc..3c997799362abd 100644 --- a/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Unix.targets +++ b/src/coreclr/nativeaot/BuildIntegration/Microsoft.NETCore.Native.Unix.targets @@ -142,9 +142,8 @@ The .NET Foundation licenses this file to you under the MIT license. - + - From 4d35d5cc0b05dfef1a5c7b1277023f832cd59fa4 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Wed, 23 Jul 2025 09:39:46 -0700 Subject: [PATCH 5/5] Update Subsets.props Co-authored-by: Adeel Mujahid <3840695+am11@users.noreply.github.com> --- eng/Subsets.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/Subsets.props b/eng/Subsets.props index 10685e498788ed..5770eec315eb4d 100644 --- a/eng/Subsets.props +++ b/eng/Subsets.props @@ -47,7 +47,7 @@ true - <_NativeAotSupportedOS Condition="'$(TargetOS)' == 'windows' or '$(TargetOS)' == 'linux' or '$(TargetOS)' == 'osx' or '$(TargetOS)' == 'maccatalyst' or '$(TargetOS)' == 'iossimulator' or '$(TargetOS)' == 'ios' or '$(TargetOS)' == 'tvossimulator' or '$(TargetOS)' == 'tvos' or '$(TargetOS)' == 'freebsd' or '$(TargetOS)' == 'android'">true + <_NativeAotSupportedOS Condition="'$(TargetOS)' != 'browser' and '$(TargetOS)' != 'haiku' and '$(TargetOS)' != 'illumos' and '$(TargetOS)' != 'netbsd' and '$(TargetOS)' != 'solaris'">true <_NativeAotSupportedArch Condition="'$(TargetArchitecture)' == 'x64' or '$(TargetArchitecture)' == 'arm64' or '$(TargetArchitecture)' == 'arm' or '$(TargetArchitecture)' == 'loongarch64' or '$(TargetArchitecture)' == 'riscv64' or ('$(TargetOS)' == 'windows' and '$(TargetArchitecture)' == 'x86')">true true