AtomicWindows.cmake 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. set (JAVASCRIPT_BINDINGS_PLATFORM "WINDOWS")
  2. include(AtomicDesktop)
  3. #set (CMAKE_DEBUG_POSTFIX _d)
  4. set (ATOMIC_NODE_JAKE Build/Windows/node/node.exe Build/node_modules/jake/bin/cli.js -f Build\\Scripts\\Bootstrap.js)
  5. if( CMAKE_SIZEOF_VOID_P EQUAL 8 )
  6. set (D3DCOMPILER_47_DLL ${CMAKE_SOURCE_DIR}/Build/Windows/Binaries/x64/D3DCompiler_47.dll)
  7. else()
  8. set (D3DCOMPILER_47_DLL ${CMAKE_SOURCE_DIR}/Build/Windows/Binaries/x86/D3DCompiler_47.dll)
  9. endif()
  10. add_definitions(-DATOMIC_PLATFORM_WINDOWS -D_CRT_SECURE_NO_WARNINGS -DATOMIC_TBUI )
  11. list (APPEND ATOMIC_LINK_LIBRARIES MojoShader user32 gdi32 winmm imm32 ole32 oleaut32 version uuid Ws2_32)
  12. if (ATOMIC_D3D11)
  13. add_definitions(-DATOMIC_D3D11)
  14. list (APPEND ATOMIC_LINK_LIBRARIES d3d11 d3dcompiler dxguid)
  15. else()
  16. list (APPEND ATOMIC_LINK_LIBRARIES d3d9 d3dcompiler)
  17. endif()
  18. # compile with static runtime
  19. set(CompilerFlags CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_RELEASE CMAKE_C_FLAGS CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_RELEASE)
  20. foreach(CompilerFlag ${CompilerFlags})
  21. string(REPLACE "/MD" "/MT" ${CompilerFlag} "${${CompilerFlag}}")
  22. endforeach()