CMakeLists.txt 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. #
  2. # Copyright (c) Contributors to the Open 3D Engine Project.
  3. # For complete copyright and license terms please see the LICENSE at the root of this distribution.
  4. #
  5. # SPDX-License-Identifier: Apache-2.0 OR MIT
  6. #
  7. #
  8. o3de_pal_dir(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Source/Platform/${PAL_PLATFORM_NAME} "${gem_restricted_path}" "${gem_path}" "${gem_parent_relative_path}")
  9. ly_add_target(
  10. NAME ${gem_name}.Headers HEADERONLY
  11. NAMESPACE Gem
  12. FILES_CMAKE
  13. bootstrap_headers_files.cmake
  14. INCLUDE_DIRECTORIES
  15. INTERFACE
  16. Include
  17. )
  18. ly_add_target(
  19. NAME ${gem_name} ${PAL_TRAIT_MONOLITHIC_DRIVEN_MODULE_TYPE}
  20. NAMESPACE Gem
  21. FILES_CMAKE
  22. bootstrap_files.cmake
  23. ${pal_dir}/bootstrap_${PAL_PLATFORM_NAME_LOWERCASE}_files.cmake
  24. PLATFORM_INCLUDE_FILES
  25. INCLUDE_DIRECTORIES
  26. PRIVATE
  27. Source
  28. ${pal_dir}
  29. PUBLIC
  30. Include
  31. BUILD_DEPENDENCIES
  32. PRIVATE
  33. AZ::AtomCore
  34. AZ::AzCore
  35. AZ::AzFramework
  36. Legacy::CryCommon
  37. Gem::Atom_RPI.Public
  38. )
  39. # Inject the gem name into the Module source file
  40. ly_add_source_properties(
  41. SOURCES
  42. Source/BootstrapModule.cpp
  43. PROPERTY COMPILE_DEFINITIONS
  44. VALUES
  45. O3DE_GEM_NAME=${gem_name}
  46. O3DE_GEM_VERSION=${gem_version})
  47. # Atom_Bootstrap is only used in Launchers
  48. ly_create_alias(NAME ${gem_name}.Clients NAMESPACE Gem TARGETS Gem::${gem_name})
  49. ly_create_alias(NAME ${gem_name}.Servers NAMESPACE Gem TARGETS Gem::${gem_name})
  50. ly_create_alias(NAME ${gem_name}.Unified NAMESPACE Gem TARGETS Gem::${gem_name})
  51. # The Atom_Bootstrap gem is responsible for making the NativeWindow handle in the launcher applications