CMakeLists.txt 869 B

12345678910111213141516171819202122232425262728293031
  1. # Source files and their filters
  2. include(CMakeSources.cmake)
  3. file(GLOB BS_GENERATED_SCRIPT_H_FILES ${CMAKE_CURRENT_SOURCE_DIR}/Generated/*.h)
  4. file(GLOB BS_GENERATED_SCRIPT_CPP_FILES ${CMAKE_CURRENT_SOURCE_DIR}/Generated/*.cpp)
  5. source_group("Generated" FILES ${BS_GENERATED_SCRIPT_H_FILES} ${BS_GENERATED_SCRIPT_CPP_FILES})
  6. # Target
  7. add_library(EditorScript OBJECT
  8. ${BS_EDITORSCRIPT_SRC}
  9. ${BS_GENERATED_SCRIPT_H_FILES}
  10. ${BS_GENERATED_SCRIPT_CPP_FILES})
  11. # Common flags
  12. add_common_flags(EditorScript)
  13. # Includes
  14. set(EditorScript_INC "./")
  15. target_include_directories(EditorScript PUBLIC ${EditorScript_INC})
  16. # Defines
  17. target_compile_definitions(EditorScript PUBLIC -DBS_SCR_BED_STATIC_LIB)
  18. # Libraries
  19. ## Local libs
  20. target_link_libraries(EditorScript bsfScript bsfMono EditorCore bsf)
  21. # IDE specific
  22. set_property(TARGET EditorScript PROPERTY FOLDER Script)