duckstation/dep/imgui/CMakeLists.txt

44 lines
1.0 KiB
CMake
Raw Normal View History

2019-09-09 07:01:26 +00:00
set(SRCS
include/imconfig.h
include/imgui.h
2019-11-07 13:51:00 +00:00
include/imgui_stdlib.h
2019-09-09 07:01:26 +00:00
src/imgui.cpp
src/imgui_demo.cpp
src/imgui_draw.cpp
src/imgui_widgets.cpp
src/imgui_internal.h
src/imstb_rectpack.h
2019-11-07 13:51:00 +00:00
src/imgui_stdlib.cpp
2019-09-09 07:01:26 +00:00
src/imstb_textedit.h
src/imstb_truetype.h
)
add_library(imgui ${SRCS})
target_include_directories(imgui PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/include" "${CMAKE_CURRENT_SOURCE_DIR}/src")
target_include_directories(imgui INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}/include")
2019-11-23 08:55:13 +00:00
target_compile_definitions(imgui PRIVATE "imgui_STATIC")
2019-09-09 07:01:26 +00:00
if(WIN32)
target_sources(imgui PRIVATE include/imgui_impl_dx11.h src/imgui_impl_dx11.cpp)
endif()
2019-10-15 08:02:48 +00:00
if(SDL2_FOUND)
2019-09-09 07:01:26 +00:00
target_sources(imgui PRIVATE
include/imgui_impl_opengl3.h
include/imgui_impl_sdl.h
src/imgui_impl_opengl3.cpp
src/imgui_impl_sdl.cpp
)
2019-11-23 08:55:13 +00:00
target_link_libraries(imgui PRIVATE glad SDL2::Core)
2019-09-09 07:01:26 +00:00
endif()
if(ANDROID)
target_sources(imgui PRIVATE
include/imgui_impl_opengl3.h
src/imgui_impl_opengl3.cpp
)
target_link_libraries(imgui PRIVATE glad)
endif()