Skip to content

Commit

Permalink
build-llvm: Don't hardcode default choices of linker/stdlib
Browse files Browse the repository at this point in the history
This should help with using clangd for other mingw toolchain
installs.
  • Loading branch information
mstorsjo committed Sep 20, 2024
1 parent 426dc0a commit ecbcf7d
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions build-llvm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -242,17 +242,6 @@ if [ -n "$COMPILER_LAUNCHER" ]; then
CMAKEFLAGS="$CMAKEFLAGS -DCMAKE_CXX_COMPILER_LAUNCHER=$COMPILER_LAUNCHER"
fi

if [ -n "$TARGET_WINDOWS" ]; then
# Custom, llvm-mingw specific defaults. We normally set these in
# the frontend wrappers, but this makes sure they are enabled by
# default if that wrapper is bypassed as well.
CMAKEFLAGS="$CMAKEFLAGS -DCLANG_DEFAULT_RTLIB=compiler-rt"
CMAKEFLAGS="$CMAKEFLAGS -DCLANG_DEFAULT_UNWINDLIB=libunwind"
CMAKEFLAGS="$CMAKEFLAGS -DCLANG_DEFAULT_CXX_STDLIB=libc++"
CMAKEFLAGS="$CMAKEFLAGS -DCLANG_DEFAULT_LINKER=lld"
CMAKEFLAGS="$CMAKEFLAGS -DLLD_DEFAULT_LD_LLD_IS_MINGW=ON"
fi

if [ -n "$LTO" ]; then
CMAKEFLAGS="$CMAKEFLAGS -DLLVM_ENABLE_LTO=$LTO"
fi
Expand Down

0 comments on commit ecbcf7d

Please sign in to comment.