legacy.cmake 1.1 KB

123456789101112131415161718192021222324252627282930313233
  1. project(get-graphics-offsets)
  2. add_executable(get-graphics-offsets)
  3. target_sources(
  4. get-graphics-offsets
  5. PRIVATE get-graphics-offsets.c
  6. get-graphics-offsets.h
  7. dxgi-offsets.cpp
  8. d3d8-offsets.cpp
  9. d3d9-offsets.cpp
  10. ../graphics-hook-info.h
  11. ../hook-helpers.h)
  12. target_include_directories(get-graphics-offsets PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/..
  13. ${CMAKE_CURRENT_SOURCE_DIR}/../d3d8-api)
  14. target_link_libraries(get-graphics-offsets d3d9.lib dxgi.lib d3d11.lib)
  15. target_compile_definitions(get-graphics-offsets PRIVATE OBS_LEGACY)
  16. if(MSVC)
  17. target_compile_options(get-graphics-offsets PRIVATE "$<IF:$<CONFIG:Debug>,/MTd,/MT>")
  18. endif()
  19. set_target_properties(get-graphics-offsets PROPERTIES FOLDER "plugins/win-capture")
  20. set_target_properties(get-graphics-offsets
  21. PROPERTIES OUTPUT_NAME "get-graphics-offsets$<IF:$<EQUAL:${CMAKE_SIZEOF_VOID_P},8>,64,32>")
  22. set(OBS_PLUGIN_DESTINATION "${OBS_DATA_DESTINATION}/obs-plugins/win-capture/")
  23. setup_plugin_target(get-graphics-offsets)
  24. add_dependencies(win-capture get-graphics-offsets)