tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
llvmPackages_16.libcxx: fix wasi32 build
Randy Eckenrode
2 years ago
485ae91f
71a74151
+2
-1
1 changed file
expand all
collapse all
unified
split
pkgs
development
compilers
llvm
16
libcxx
default.nix
+2
-1
pkgs/development/compilers/llvm/16/libcxx/default.nix
···
62
62
63
63
buildInputs =
64
64
lib.optionals (!headersOnly) [ cxxabi ]
65
65
-
++ lib.optionals (stdenv.hostPlatform.useLLVM or false) [ libunwind ];
65
65
+
++ lib.optionals (stdenv.hostPlatform.useLLVM or false && !stdenv.hostPlatform.isWasm) [ libunwind ];
66
66
67
67
cmakeFlags = let
68
68
# See: https://libcxx.llvm.org/BuildingLibcxx.html#cmdoption-arg-libcxx-cxx-abi-string
···
87
87
"-DLIBCXX_ENABLE_THREADS=OFF"
88
88
"-DLIBCXX_ENABLE_FILESYSTEM=OFF"
89
89
"-DLIBCXX_ENABLE_EXCEPTIONS=OFF"
90
90
+
"-DUNIX=ON" # Required otherwise libc++ fails to detect the correct linker
90
91
] ++ lib.optional (!enableShared) "-DLIBCXX_ENABLE_SHARED=OFF"
91
92
# If we're only building the headers we don't actually *need* a functioning
92
93
# C/C++ compiler: