Skip to content
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

Explore static library support (for e.g. iOS) #9

Open
Tracked by #26
alexrp opened this issue Jun 20, 2021 · 2 comments
Open
Tracked by #26

Explore static library support (for e.g. iOS) #9

alexrp opened this issue Jun 20, 2021 · 2 comments
Labels
area: samples Issues related to sample projects. area: sdk Issues related to the MSBuild SDK. state: blocked Issues that are blocked on some other issue or work.
Milestone

Comments

@alexrp
Copy link
Member

alexrp commented Jun 20, 2021

This isn't terribly useful right now, but will become useful once the .NET SDK gains full support for Apple platforms like iOS and watchOS that only support static linking.

This will require significant work in Zig, especially for cross-compilation.

See: ziglang/zig#5145

@alexrp alexrp added type: feature state: blocked Issues that are blocked on some other issue or work. area: sdk Issues related to the MSBuild SDK. area: samples Issues related to sample projects. labels Jun 20, 2021
@alexrp alexrp self-assigned this Jun 20, 2021
@alexrp alexrp modified the milestones: 3.0.0, 3.0, 4.0 Jun 30, 2021
@alexrp alexrp modified the milestones: v4.0, v5.0 Sep 7, 2021
@alexrp alexrp modified the milestones: v5.0, Future Jan 1, 2024
@alexrp alexrp removed their assignment Jan 27, 2024
@alexrp
Copy link
Member Author

alexrp commented Apr 30, 2024

As far as how this should work from the user perspective, I think there should just be an MSBuild property that informs the SDK which kind of library to build. NativeAOT has already introduced the NativeLib property for this; the name is a bit unfortunate, but there is probably value in standardizing on it. It accepts Shared (default) and Static. We might extend it to also accept Both.

@alexrp
Copy link
Member Author

alexrp commented Nov 28, 2024

This is complicated somewhat by needing to invoke zig ar/zig lib to actually create the static library for C/C++ projects. For Zig code, zig build-lib -static takes care of it automatically.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: samples Issues related to sample projects. area: sdk Issues related to the MSBuild SDK. state: blocked Issues that are blocked on some other issue or work.
Development

No branches or pull requests

1 participant