CMakeLists.txt 804 B

12345678910111213141516171819202122232425
  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_find_ancestor_gem_root(gem_path gem_name "${CMAKE_CURRENT_SOURCE_DIR}")
  9. if (NOT gem_name)
  10. set(gem_name "CommonFeaturesAtom")
  11. endif()
  12. # Fallback to using the current source CMakeLists.txt directory as the gem root path
  13. if (NOT gem_path)
  14. set(gem_path ${CMAKE_CURRENT_SOURCE_DIR})
  15. endif()
  16. set(gem_json ${gem_path}/gem.json)
  17. o3de_restricted_path(${gem_json} gem_restricted_path gem_parent_relative_path)
  18. o3de_pal_dir(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/Platform/${PAL_PLATFORM_NAME} "${gem_restricted_path}" "${gem_path}" "${gem_parent_relative_path}")
  19. add_subdirectory(Code)