lib.systems: Add examples & helpers for MSVC

This commit is contained in:
Ross Smyth 2025-07-31 11:23:13 -04:00
parent 63e24fbc20
commit 4af7c6bdee
3 changed files with 17 additions and 0 deletions

View File

@ -120,6 +120,8 @@ let
libc =
if final.isDarwin then
"libSystem"
else if final.isMsvc then
"ucrt"
else if final.isMinGW then
"msvcrt"
else if final.isWasi then

View File

@ -372,6 +372,17 @@ rec {
useLLVM = true;
};
# Target the MSVC ABI
x86_64-windows = {
config = "x86_64-pc-windows-msvc";
useLLVM = true;
};
aarch64-windows = {
config = "aarch64-pc-windows-msvc";
useLLVM = true;
};
# BSDs
aarch64-freebsd = {

View File

@ -344,6 +344,10 @@ rec {
kernel = kernels.windows;
abi = abis.gnu;
};
isMsvc = {
kernel = kernels.windows;
abi = abis.msvc;
};
isWasi = {
kernel = kernels.wasi;
};