sv-lang_10: fix build on darwin

Include the wrapped clang-tools on darwin so cmake picks up the wrapped
clang-scan-deps. The unwrapped clang-scan-deps cannot find the C++20
module headers while scanning dependencies, which broke the build.

With the build fixed, unbreak the package on darwin and enable the unit
tests on all platforms (they build and pass on darwin now).

Co-authored-by: Nils Cremer <nils.crmr@gmail.com>
This commit is contained in:
Karolis Stasaitis
2026-08-05 16:29:35 +02:00
parent 7ea02c461d
commit b19cb946f2

View File

@@ -8,6 +8,7 @@
cmake,
ninja,
fmt,
llvmPackages,
mimalloc,
python3,
}:
@@ -52,6 +53,10 @@ stdenv.mkDerivation (finalAttrs: {
cmake
python3
ninja
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
# needs the wrapped clang-scan-deps to find the C++20 module headers
llvmPackages.clang-tools
];
strictDeps = true;
@@ -63,15 +68,17 @@ stdenv.mkDerivation (finalAttrs: {
catch2_3
];
doCheck = !stdenv.hostPlatform.isDarwin;
doCheck = true;
meta = {
description = "SystemVerilog compiler and language services";
homepage = "https://github.com/MikePopoloski/slang";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ sharzy ];
maintainers = with lib.maintainers; [
sharzy
carlossless
];
mainProgram = "slang";
platforms = lib.platforms.all;
broken = stdenv.hostPlatform.isDarwin;
};
})