Skip to content

Commit 57a6845

Browse files
committed
Fix DirectX 12 shared library build.
Explicitly linking library to avoid linking errors.
1 parent 85ebd63 commit 57a6845

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,9 @@ target_include_directories(${PROJECT_NAME} PUBLIC
105105
${SOURCE_DIR}
106106
${SOURCE_DIR}/examples
107107
)
108+
if(IMGUI_IMPL_DX12 AND NOT IMGUI_STATIC_LIBRARY)
109+
target_link_libraries(${PROJECT_NAME} PUBLIC d3d12)
110+
endif()
108111

109112

110113
##################################################################################################################

0 commit comments

Comments
 (0)