Skip to content

Enable CoreCLR for linux-bionic platforms and include singlefilehost in AppHost pack - #131115

Merged
jkoritzinsky merged 2 commits into
mainfrom
copilot/fix-linux-bionic-arm64-binaries
Jul 23, 2026
Merged

Enable CoreCLR for linux-bionic platforms and include singlefilehost in AppHost pack#131115
jkoritzinsky merged 2 commits into
mainfrom
copilot/fix-linux-bionic-arm64-binaries

Conversation

Copilot AI commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Single-file self-contained binaries for linux-bionic-arm64/x64 (Termux on Android) were silently falling back to apphost instead of singlefilehost, producing non-functional ~11MB binaries instead of the expected ~30MB bundles. Root cause: singlefilehost was explicitly excluded from the linux-bionic AppHost pack, and CoreCLR was never enabled for linux-bionic builds.

Changes

eng/Subsets.props

  • Enable CoreCLRSupported for linux-bionic on arm64 and x64 (mirrors Android pattern; excludes arm and x86)
  • Update DefaultSubsets for linux-bionic to clr+mono+libs+host+packs when CoreCLR is supported, with fallback to NativeAOT-only subsets for unsupported architectures
  • Add DefaultCoreClrSubsets for linux-bionic (matches Android/Apple Mobile: clr.native+clr.corelib+clr.tools+clr.nativecorelib+clr.packages+clr.nativeaotlibs+clr.crossarchtools)
  • Add RuntimeFlavor=CoreCLR condition for linux-bionic when clr subset is requested

src/installer/pkg/sfx/Microsoft.NETCore.App/Microsoft.NETCore.App.Host.sfxproj

  • Remove the '$(TargetsLinuxBionic)' != 'true' guard from the singlefilehost NativeRuntimeAsset item — it is now built and should ship

Copilot AI review requested due to automatic review settings July 20, 2026 23:17

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because there is no eligible user to bill. To allow Copilot reviews on bot-authored pull requests, enable direct organization billing in your organization's Copilot settings.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
16 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

…in AppHost pack

Co-authored-by: jkoritzinsky <1571408+jkoritzinsky@users.noreply.github.com>
Copilot AI review requested due to automatic review settings July 20, 2026 23:27

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because there is no eligible user to bill. To allow Copilot reviews on bot-authored pull requests, enable direct organization billing in your organization's Copilot settings.

Copilot AI changed the title [WIP] Fix self-contained binary size for linux-bionic-arm64 Enable CoreCLR for linux-bionic platforms and include singlefilehost in AppHost pack Jul 20, 2026
Copilot AI requested a review from jkoritzinsky July 20, 2026 23:27
@jkoritzinsky
jkoritzinsky marked this pull request as ready for review July 21, 2026 02:49
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 3 pipeline(s).
13 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

@elinor-fung

Copy link
Copy Markdown
Member

Is there a separate pipeline (maybe extra platforms?) we should kick off for this?

@jkoritzinsky

Copy link
Copy Markdown
Member

/azp run runtime-extra-platforms

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).

@jkoritzinsky

Copy link
Copy Markdown
Member

@elinor-fung the bionic legs passed so we should be good to go

@jkoritzinsky
jkoritzinsky enabled auto-merge (squash) July 23, 2026 22:21
@jkoritzinsky

Copy link
Copy Markdown
Member

/ba-g osx failures unrelated to Linux-bionic only change

@jkoritzinsky
jkoritzinsky merged commit 22c5825 into main Jul 23, 2026
189 of 212 checks passed
@jkoritzinsky
jkoritzinsky deleted the copilot/fix-linux-bionic-arm64-binaries branch July 23, 2026 22:22
@github-project-automation github-project-automation Bot moved this to Done in AppModel Jul 23, 2026
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-rc1 milestone Jul 24, 2026
hez2010 pushed a commit to hez2010/runtime that referenced this pull request Jul 26, 2026
akoeplinger added a commit to dotnet/dotnet that referenced this pull request Jul 30, 2026
The linux-bionic line in _CoreCLRSupportedOS was added by
dotnet/runtime#131115 by copying the Android line, but it picked up a
'arm' exclusion that Android had already dropped two months earlier.

Android excluded arm in April 2026 with the comment "Android 32-bit
builds blocked by dotnet/runtime#111665", then re-enabled it on
2026-05-21 once that was resolved. Issue 111665 (fseeko/ftello not
supported on arm32 and x86 below API level 24) was closed as completed
on 2026-07-20, and eng/native/build-commons.sh pins ANDROID_API_LEVEL
to 24, so the restriction never applied here in the first place.

Drop the stale exclusion so bionic matches Android. x86 stays excluded
for both. The arm exclusions in _MonoSupportedArch and in
_BuildHostPack/_BuildBundle are unrelated, predate this, and are left
alone.

This flips CoreCLRSupported to true for bionic-arm, moving its default
subsets from clr.nativeaotruntime+clr.nativeaotlibs+libs+packs to
clr+libs+host+packs, since Mono remains unsupported there.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: d6553736-6f22-41f2-9bd4-7223785d09e6
@github-actions github-actions Bot locked and limited conversation to collaborators Aug 23, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

singlefile and selfcontained linux-bionic-arm64 (aka in Termux on Android ) binaries aren't actually selfcontained properly

4 participants