mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2024-11-25 23:25:41 +00:00
Fix CMake build
This commit is contained in:
parent
aa792da823
commit
e68cddf017
|
@ -19,6 +19,7 @@ if(WIN32)
|
|||
|
||||
set(SDL2_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/dep/msvc/include/SDL")
|
||||
set(SDL2_LIBRARIES "SDL2")
|
||||
set(SDL2_FOUND TRUE)
|
||||
else()
|
||||
find_package(SDL2 REQUIRED)
|
||||
endif()
|
||||
|
|
|
@ -1,11 +1,7 @@
|
|||
add_subdirectory(glad)
|
||||
add_subdirectory(googletest)
|
||||
add_subdirectory(imgui)
|
||||
add_subdirectory(inih)
|
||||
add_subdirectory(libsamplerate)
|
||||
add_subdirectory(nativefiledialog)
|
||||
add_subdirectory(softfloat)
|
||||
add_subdirectory(xxhash)
|
||||
add_subdirectory(stb)
|
||||
|
||||
###################### YBaseLib ############################
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ if(WIN32)
|
|||
target_sources(imgui PRIVATE include/imgui_impl_dx11.h src/imgui_impl_dx11.cpp)
|
||||
endif()
|
||||
|
||||
if(ENABLE_SDL_FRONTEND)
|
||||
if(SDL2_FOUND)
|
||||
target_sources(imgui PRIVATE
|
||||
include/imgui_impl_opengl3.h
|
||||
include/imgui_impl_sdl.h
|
||||
|
|
8
dep/stb/CMakeLists.txt
Normal file
8
dep/stb/CMakeLists.txt
Normal file
|
@ -0,0 +1,8 @@
|
|||
set(SRCS
|
||||
src/stb_image_write.c
|
||||
)
|
||||
|
||||
add_library(stb ${SRCS})
|
||||
target_include_directories(stb PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/include" "${CMAKE_CURRENT_SOURCE_DIR}/src")
|
||||
target_include_directories(stb INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}/include")
|
||||
target_link_libraries(stb Threads::Threads "${CMAKE_DL_LIBS}")
|
|
@ -1,7 +1,13 @@
|
|||
set(SRCS
|
||||
audio.cpp
|
||||
audio.h
|
||||
audio_stream.cpp
|
||||
audio_stream.h
|
||||
bitfield.h
|
||||
cd_image.cpp
|
||||
cd_image.h
|
||||
cd_xa.cpp
|
||||
cd_xa.h
|
||||
display.cpp
|
||||
display.h
|
||||
display_renderer.cpp
|
||||
|
@ -9,6 +15,10 @@ set(SRCS
|
|||
display_timing.cpp
|
||||
display_timing.h
|
||||
fastjmp.h
|
||||
gl_program.cpp
|
||||
gl_program.h
|
||||
gl_texture.cpp
|
||||
gl_texture.h
|
||||
hdd_image.cpp
|
||||
hdd_image.h
|
||||
jit_code_buffer.cpp
|
||||
|
|
|
@ -1,16 +1,54 @@
|
|||
add_library(core
|
||||
cpu_bus.cpp
|
||||
cpu_bus.h
|
||||
cpu_bus.inl
|
||||
bus.cpp
|
||||
bus.h
|
||||
bus.inl
|
||||
cdrom.cpp
|
||||
cdrom.h
|
||||
cpu_core.cpp
|
||||
cpu_core.h
|
||||
cpu_core.inl
|
||||
cpu_disasm.cpp
|
||||
cpu_disasm.h
|
||||
cpu_types.h
|
||||
digital_controller.cpp
|
||||
digital_controller.h
|
||||
dma.cpp
|
||||
dma.h
|
||||
gpu.cpp
|
||||
gpu.h
|
||||
gpu_hw.cpp
|
||||
gpu_hw.h
|
||||
gpu_hw_opengl.cpp
|
||||
gpu_hw_opengl.h
|
||||
gte.cpp
|
||||
gte.h
|
||||
gte.inl
|
||||
gte_types.h
|
||||
host_interface.cpp
|
||||
host_interface.h
|
||||
interrupt_controller.cpp
|
||||
interrupt_controller.h
|
||||
mdec.cpp
|
||||
mdec.h
|
||||
memory_card.cpp
|
||||
memory_card.h
|
||||
pad.cpp
|
||||
pad.h
|
||||
pad_device.cpp
|
||||
pad_device.h
|
||||
save_state_version.h
|
||||
settings.cpp
|
||||
settings.h
|
||||
spu.cpp
|
||||
spu.h
|
||||
system.cpp
|
||||
system.h
|
||||
timers.cpp
|
||||
timers.h
|
||||
types.h
|
||||
)
|
||||
|
||||
target_include_directories(core PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/..")
|
||||
target_include_directories(core PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/..")
|
||||
target_link_libraries(core Threads::Threads YBaseLib common)
|
||||
target_link_libraries(core Threads::Threads YBaseLib common imgui stb)
|
||||
|
||||
|
|
|
@ -2,6 +2,8 @@ set(SRCS
|
|||
main.cpp
|
||||
sdl_audio_mixer.cpp
|
||||
sdl_audio_mixer.h
|
||||
sdl_audio_stream.cpp
|
||||
sdl_audio_stream.h
|
||||
sdl_interface.cpp
|
||||
sdl_interface.h
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue