Skip to content

Add macOS ARM64 NuGet packages - #293

Open
jsturtevant wants to merge 5 commits into
jsturtevant-macos-python-wheelsfrom
jsturtevant-macos-dotnet-packages
Open

jsturtevant wants to merge 5 commits into
jsturtevant-macos-python-wheelsfrom
jsturtevant-macos-dotnet-packages

Conversation

@jsturtevant

@jsturtevant jsturtevant commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Package the macOS ARM64 native library, signed developer helper, and AOT guests alongside the existing Linux and Windows assets. Resolve native libraries and guests by portable OS/CPU identifiers.

Installed NuGet packages run on HVF before release assets are combined. The helper owns the hypervisor entitlement, so dotnet and application executables do not need to be re-signed. macOS support is developer-only.

Depends on #291; native stack: #296 → #291 → #293.

@jsturtevant
jsturtevant added this pull request to stack #292 November 11, 2026 20:09
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from 9c101d3 to e362b9a Compare November 11, 2026 21:40
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch 2 times, most recently from f4cd6db to 69c4dcd Compare November 11, 2026 22:43
@jsturtevant
jsturtevant removed this pull request from stack #292 November 11, 2026 23:57
@jsturtevant
jsturtevant added this pull request to stack #295 November 11, 2026 23:57
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch 2 times, most recently from c727282 to f738842 Compare November 12, 2026 03:27
@jsturtevant
jsturtevant removed this pull request from stack #295 November 12, 2026 03:28
@jsturtevant
jsturtevant added this pull request to stack #297 November 12, 2026 03:28
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from f738842 to 1825ebe Compare November 12, 2026 03:33
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch 2 times, most recently from 6a4829b to 0c25d8b Compare November 12, 2026 05:55
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from 0c25d8b to dbb83b0 Compare November 12, 2026 17:15
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch 2 times, most recently from 5fa321a to e63fdf9 Compare November 12, 2026 22:04
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from e63fdf9 to b1d9e91 Compare November 12, 2026 22:22
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from b1d9e91 to 4798a35 Compare November 12, 2026 22:37
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from 4798a35 to 7f5af13 Compare November 12, 2026 22:47
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from 7f5af13 to 8b79ac3 Compare November 12, 2026 23:11
jsturtevant added a commit that referenced this pull request Nov 12, 2026
Run macOS SDK sandboxes in a signed Rust surrogate so Python and dotnet
do not need to be re-signed. Follow HIP-0004 with one sandbox per
surrogate, a bounded reusable pool, postcard frames over an inherited
socket, proxied tools, and file-backed snapshots.

This is developer-only support. macOS SDKs use this path by default;
Linux Rust callers can opt in to the process API. Other SDK defaults
stay unchanged. Windows transport is not included.

Native stack: #296 → #291 (Python wheels) → #293 (NuGet packages).

---------

Signed-off-by: James Sturtevant <jsturtevant@gmail.com>
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from 448e68b to 3091ff7 Compare November 12, 2026 23:56
@jsturtevant
jsturtevant requested a balanced review from Copilot November 13, 2026 00:06

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.

🟡 Changes recommended

Incomplete Rust dependency tracking and guest asset staging can leave managed builds and examples using outdated native libraries or guest code.

2 open issues
What changed in this PR

Adds developer-only macOS ARM64 support to the .NET NuGet distribution, building on the signed helper so applications do not need hypervisor entitlements.

Changes:

  • Packages macOS native assets and architecture-specific AOT guests, with portable OS/CPU resolution.
  • Adds installed-package execution tests and isolates locally built packages from cached or published versions.
  • Integrates macOS HVF testing and artifact collection into CI and publishing.
File Description
src/​sdk/​dotnet/​README.md Documents experimental Apple Silicon support.
src/​sdk/​dotnet/​Justfile Stages guests by architecture and clears package-test caches.
src/​sdk/​dotnet/​core/​Tests/​HyperlightSandbox.PackageTests/​PackageInstallationTests.cs Tests execution through installed packages.
src/​sdk/​dotnet/​core/​Tests/​HyperlightSandbox.PackageTests/​nuget.config Routes Hyperlight packages to the local feed.
src/​sdk/​dotnet/​core/​Tests/​HyperlightSandbox.PackageTests/​HyperlightSandbox.PackageTests.csproj Isolates the package-test restore cache.
src/​sdk/​dotnet/​core/​PInvoke/​SafeNativeMethods.cs Resolves macOS libraries and portable runtime paths.
src/​sdk/​dotnet/​core/​PInvoke/​HyperlightSandbox.PInvoke.csproj Packages the macOS library and selects platform-specific build outputs.
src/​sdk/​dotnet/​core/​NativePlatform.cs Provides shared OS/CPU runtime identifiers.
src/​sdk/​dotnet/​core/​Guest.Python/​PythonGuestModule.cs Resolves Python guests using portable runtime identifiers.
src/​sdk/​dotnet/​core/​Guest.Python/​HyperlightSandbox.Guest.Python.csproj Packages separately staged x64 and ARM64 Python guests.
src/​sdk/​dotnet/​core/​Guest.JavaScript/​JavaScriptGuestModule.cs Resolves JavaScript guests using portable runtime identifiers.
src/​sdk/​dotnet/​core/​Guest.JavaScript/​HyperlightSandbox.Guest.JavaScript.csproj Packages separately staged x64 and ARM64 JavaScript guests.
.github/​workflows/​publish.yml Collects macOS artifacts and checks package contents.
.github/​workflows/​dotnet-macos.yml Builds and tests installed packages on an ARM64 HVF runner.
.github/​workflows/​ci.yml Adds the reusable macOS package workflow to CI.

Review effort: Balanced

Comment thread src/sdk/dotnet/Justfile Resolved
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from 04f143b to 777df27 Compare November 13, 2026 00:36
Signed-off-by: James Sturtevant <jsturtevant@gmail.com>
Signed-off-by: James Sturtevant <jsturtevant@gmail.com>
Signed-off-by: James Sturtevant <jsturtevant@gmail.com>
Signed-off-by: James Sturtevant <jsturtevant@gmail.com>
Signed-off-by: James Sturtevant <jsturtevant@gmail.com>
@jsturtevant
jsturtevant force-pushed the jsturtevant-macos-dotnet-packages branch from 777df27 to ebabb33 Compare November 13, 2026 07:51

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants