Skip to content

Commit ee18448

Browse files
peterjc123facebook-github-bot
authored andcommitted
Don't install PDB for Windows static build of caffe2_observers (pytorch#16420)
Summary: Fixes pytorch#16292. Pull Request resolved: pytorch#16420 Differential Revision: D13833704 Pulled By: soumith fbshipit-source-id: 482ad6ce103bed7206e924e8c82454fbb1bfac42
1 parent c863a75 commit ee18448

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/observers/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ target_include_directories(caffe2_observers PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/.
1919
target_compile_options(caffe2_observers PRIVATE "-DCAFFE2_BUILD_OBSERVER_LIB")
2020
install(TARGETS caffe2_observers DESTINATION lib)
2121
caffe2_interface_library(caffe2_observers caffe2_observers_library)
22-
if (MSVC)
22+
if (MSVC AND BUILD_SHARED_LIBS)
2323
install(FILES $<TARGET_PDB_FILE:caffe2_observers> DESTINATION lib OPTIONAL)
2424
endif()
2525

0 commit comments

Comments
 (0)