Skip to content

Fix osx-x64 cross compilation - #83

Open
smoogipoo wants to merge 1 commit into
VSadov:mainfrom
smoogipoo:fix-osx-x64-compile
Open

Fix osx-x64 cross compilation#83
smoogipoo wants to merge 1 commit into
VSadov:mainfrom
smoogipoo:fix-osx-x64-compile

Conversation

@smoogipoo

@smoogipoo smoogipoo commented Jun 8, 2026

Copy link
Copy Markdown

I'm not entirely sure about the change to CMakeLists - running into a clang++ error: unsupported option -mcx16 for target arm64-apple-darwin25.3.0. Just referencing surrounding code which relates to the host.

While I'm PRing this to main (i.e. .NET 11), I've tested compilation on .NET 10 (our target SDK) here: https://github.com/ppy/Satori/actions/runs/27126600038 If this is accepted I can either backport to each of the branches as required or wait for you to do it.

Compile args: ./build.sh clr -c Release --cross -a x64

@smoogipoo

smoogipoo commented Jun 9, 2026

Copy link
Copy Markdown
Author

While it builds (and runs a simple hello world), it looks like there's something more to this because it segfaults at startup on our full-fledged app. Will try to debug further.

@smoogipoo

smoogipoo commented Jun 9, 2026

Copy link
Copy Markdown
Author

I'm a bit lost on how to debug this further for the moment, it looks like it dies in JITted code and only in release builds of Satori - debug works fine. LLDB is also currently crashing when loading SOS >_<


Reproduction steps:

  1. Clone https://github.com/smoogipoo/osu-framework/tree/net10.0
  2. Build osu.Framework.Tests (dotnet publish --self-contained -r osx-x64 osu.Framework.Tests/osu.Framework.Tests.csproj)
  3. Replace output libs with Satori ones (10.0-based + this patch to fix compile).
  4. Run osu.Framework.Tests (./osu.Framework.Tests/bin/Release/net10.0/osx-x64/publish/osu.Framework.Tests).

@hez2010

hez2010 commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

I'm a bit lost on how to debug this further for the moment, it looks like it dies in JITted code and only in release builds of Satori - debug works fine. LLDB is also currently crashing when loading SOS >_<

Reproduction steps:

  1. Clone https://github.com/smoogipoo/osu-framework/tree/net10.0
  2. Build osu.Framework.Tests (dotnet publish --self-contained -r osx-x64 osu.Framework.Tests/osu.Framework.Tests.csproj)
  3. Replace output libs with Satori ones (10.0-based + this patch to fix compile).
  4. Run osu.Framework.Tests (./osu.Framework.Tests/bin/Release/net10.0/osx-x64/publish/osu.Framework.Tests).

Some discussion happened in discord that might be related:

just recently realized it didn't spill all registers it should have inside the WB

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