Skip to content

Commit acd34d9

Browse files
authored
[Clang][CMake][MSVC] Install PDBs alongside executables (#126675)
* Follows up on #120683 enabling PDBs for `clang`.
1 parent a0fbc19 commit acd34d9

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

clang/cmake/modules/AddClang.cmake

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,10 @@ macro(add_clang_library name)
138138
ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX}
139139
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}")
140140

141+
if (LLVM_ENABLE_PDB)
142+
install(FILES $<TARGET_PDB_FILE:${name}> DESTINATION "${CMAKE_INSTALL_BINDIR}" COMPONENT ${name} OPTIONAL)
143+
endif()
144+
141145
if (NOT LLVM_ENABLE_IDE)
142146
add_llvm_install_targets(install-${lib}
143147
DEPENDS ${lib}

0 commit comments

Comments
 (0)