CMakeLists.txt 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_SOURCE_DIR}/CMakeModules)
  2. add_executable(yuzu-cmd
  3. config.cpp
  4. config.h
  5. default_ini.h
  6. emu_window/emu_window_sdl2_gl.cpp
  7. emu_window/emu_window_sdl2_gl.h
  8. emu_window/emu_window_sdl2.cpp
  9. emu_window/emu_window_sdl2.h
  10. emu_window/emu_window_sdl2_gl.cpp
  11. emu_window/emu_window_sdl2_gl.h
  12. resource.h
  13. yuzu.cpp
  14. yuzu.rc
  15. )
  16. if (ENABLE_VULKAN)
  17. target_sources(yuzu-cmd PRIVATE
  18. emu_window/emu_window_sdl2_vk.cpp
  19. emu_window/emu_window_sdl2_vk.h)
  20. target_include_directories(yuzu-cmd PRIVATE ../../externals/Vulkan-Headers/include)
  21. target_compile_definitions(yuzu-cmd PRIVATE HAS_VULKAN)
  22. endif()
  23. create_target_directory_groups(yuzu-cmd)
  24. target_link_libraries(yuzu-cmd PRIVATE common core input_common)
  25. target_link_libraries(yuzu-cmd PRIVATE inih glad)
  26. if (MSVC)
  27. target_link_libraries(yuzu-cmd PRIVATE getopt)
  28. endif()
  29. target_link_libraries(yuzu-cmd PRIVATE ${PLATFORM_LIBRARIES} SDL2 Threads::Threads)
  30. if(UNIX AND NOT APPLE)
  31. install(TARGETS yuzu-cmd RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}/bin")
  32. endif()
  33. if (MSVC)
  34. include(CopyYuzuSDLDeps)
  35. copy_yuzu_SDL_deps(yuzu-cmd)
  36. endif()