-
Notifications
You must be signed in to change notification settings - Fork 5.2k
[browser][coreCLR] runtime pack #121174
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
[browser][coreCLR] runtime pack #121174
Conversation
|
Tagging subscribers to 'arch-wasm': @lewing, @pavelsavara |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds CoreCLR WASM support to the runtime build system. The changes enable building CoreCLR for browser targets alongside the existing Mono support.
- Adds
CORERUN_LIBS_ONLYconditional gates to prevent installing runtime-specific native libraries to the sharedFramework when building for test scenarios - Includes CoreCLR WASM-specific native files in the platform manifest for browser targets
- Disables crossgen/R2R for browser/WASI targets and implements a copy-only strategy for CoreLib
- Updates the default CoreCLR subset for browser targets to include
clr.nativecorelib - Modifies CI pipeline to build packs in addition to clr+libs for WASM
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/native/libs/System.Native/CMakeLists.txt | Adds CORERUN_LIBS_ONLY guards around install commands for System.Native-Static and TimeZoneData libraries |
| src/native/libs/System.Native.Browser/CMakeLists.txt | Adds CORERUN_LIBS_ONLY guard around install command for System.Native.Browser-Static |
| src/native/libs/System.Globalization.Native/CMakeLists.txt | Adds CORERUN_LIBS_ONLY guards around install commands for globalization libraries and ICU files |
| src/native/libs/Common/JavaScript/CMakeLists.txt | Adds CORERUN_LIBS_ONLY guard around install commands for JavaScript rollup outputs |
| src/installer/pkg/sfx/Microsoft.NETCore.App/Microsoft.NETCore.App.Runtime.CoreCLR.sfxproj | Disables PublishReadyToRun for browser and wasi targets |
| src/installer/pkg/sfx/Microsoft.NETCore.App/Directory.Build.props | Adds CoreCLR WASM-specific native library files to platform manifest entries |
| src/coreclr/crossgen-corelib.proj | Adds browser-specific target that copies CoreLib instead of running crossgen |
| eng/pipelines/runtime.yml | Updates browser_wasm build to include packs subset |
| eng/Subsets.props | Adds clr.nativecorelib to default CoreCLR subsets for browser targets |
| <Copy SourceFiles="@(CoreLib)" DestinationFiles="$(CoreLibOutputPath)" UseHardlinksIfPossible="true" /> | ||
| </Target> | ||
|
|
||
|
|
Copilot
AI
Oct 31, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the extra blank line (line 109) between the InvokeCrossgenBrowser and InvokeCrossgen targets to maintain consistent spacing throughout the file.
| <!-- Disable crossgen on NetBSD, illumos, Solaris, Haiku and WASM for now. This can be revisited when we have full support. --> | ||
| <PublishReadyToRun Condition="'$(TargetOS)' == 'netbsd' or '$(TargetOS)' == 'illumos' or '$(TargetOS)' == 'solaris' or '$(TargetOS)' == 'haiku' or '$(TargetOS)' == 'browser' or '$(TargetOS)' == 'wasi'">false</PublishReadyToRun> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add a separate line for WASM as the reasoning there is different? (Supported platform where we actually have a plan vs community platforms where community members haven't gotten it wired up yet)
clr.nativecorelibthat just copiesSystem.Private.CoreLib.dllto expected placePlatformManifestFileEntryfor new librariesPublishReadyToRununtil [User Story] RyuJIT for WebAssembly (Wasm) #121141sharedFrameworkonly innativecmake root. Otherwise those fromcoreclrtree are duplicates when we create runtime pack.Fixes #120206