CMakeLists.txt 1.2 KB

123456789101112131415161718192021222324252627282930313233
  1. include_directories(${CMAKE_CURRENT_SOURCE_DIR}
  2. ${CMAKE_SOURCE_DIR}/Source/ThirdParty
  3. ${CMAKE_SOURCE_DIR}/Source/ThirdParty/rapidjson/include
  4. ${CMAKE_SOURCE_DIR}/Source/ThirdParty/kNet/include
  5. ${CMAKE_SOURCE_DIR}/Source/ThirdParty/FreeType/include
  6. ${CMAKE_SOURCE_DIR}/Source/ThirdParty/Box2D )
  7. # ${CMAKE_SOURCE_DIR}/Build/Source/Generated/${JAVASCRIPT_BINDINGS_PLATFORM}/CSharp/Packages/Atomic/Native)
  8. file (GLOB CSHARP_SOURCES *.cpp *.h)
  9. if (NOT MSVC)
  10. # for kNet
  11. add_definitions (-DUNIX)
  12. endif()
  13. set (SOURCE_FILES ${CSHARP_SOURCES} ${CSHARP_BINDINGS_SOURCE} ${CSHARPATOMICPLAYER_BINDINGS_SOURCE})
  14. add_library(AtomicNETNative SHARED ${SOURCE_FILES})
  15. target_link_libraries(AtomicNETNative AtomicJS AtomicPlayerLib AtomicPlayerJS NETCore ${ATOMIC_LINK_LIBRARIES})
  16. if (APPLE)
  17. target_link_libraries(AtomicNETNative "-framework AudioUnit -framework Carbon -framework Cocoa -framework CoreAudio -framework ForceFeedback -framework IOKit -framework OpenGL -framework CoreServices -framework Security")
  18. endif()
  19. if (NOT IOS AND NOT ANDROID AND NOT EMSCRIPTEN)
  20. add_dependencies(AtomicNETNative AtomicTool)
  21. endif()