0

I'm trying to import a .NET project from iOS native project.

During build time I'm getting linker error: ld: __DATA_CONST segment missing SG_READ_ONLY flag in .../Build/Products/Debug-iphoneos/[TheFramework].framework/[TheFrameworkBinary]

The chain is:

  • dotnet publish (9.0) to produce .dylib
  • wrap it in .framework (and sign it)
  • wrap it in .xcframework (sign again)
  • use it as a binary dependency of SPM
  • which is used by the iOS project

Any idea how to solve that missing flag? According to AI I should be using ld during publish, which seems to be correct.

EDIT: this seems to happen when targetting net9.0, but reverting to <TargetFramework>net8.0</TargetFramework> fixes it atm.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.