Open alexrp opened 3 years ago
Goals:
Zig.Sdk
projects.
Zig.Sdk
projects should not be seen as managed (i.e. don't pass it to csc /reference:...
).Zig.Sdk
projects must never be seen as RID-agnostic.Zig.Sdk
project to the root of the output directory.Zig.Sdk
project for all of its supported RIDs to runtimes/<rid>/native/
(tools/<rid>/native/
for an executable project) in the output directory.
Zig.Sdk
project.Zig.Sdk
packages.
runtimes/<rid>/native/
.Managed -> NativePackage1 -> NativePackage2
graph, NuGet flows NativePackage2
to Managed
.Zig.Sdk
projects should be able to reference other Zig.Sdk
projects.
Zig.Sdk
projects should be able to reference managed projects.
ReferenceOutputAssembly=false
).Zig.Sdk
projects should be able to reference managed packages.
Nerdbank.GitVersioning
).Zig.Sdk
projects should be able to reference Zig.Sdk
packages.
runtimes/<rid>/native/
), include directory (include/
), and Zig package directory (zig/
).
tools/<rid>/native/
in the package).Notes:
Zig.Sdk
project references will need to use this pattern.Part of this work is going to be blocked by https://github.com/dotnet/runtime/issues/54645.
This is going to depend on ~https://github.com/ziglang/zig/pull/9251~ https://github.com/ziglang/zig/pull/9347. Hopefully it (in some form) can be included in Zig 0.8.1.
To make consumption of Zig.Sdk
packages work, we will need to resolve their extracted location on disk to discover their C/C++ include directory and Zig package directory. This can only be done reliably by reading project.assets.json
. We can either do that directly or by using the NuGet.ProjectModel.LockFileFormat
API.
Changing milestone since https://github.com/ziglang/zig/pull/9347 didn't make Zig 0.8.1.
Things should be in place to start work on this in Zig 0.9.0.
Tracking issue for
ProjectReference
/PackageReference
support.