Enable cmake-install in project-centric / engine-prebuilt (#4767)

Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
This commit is contained in:
Esteban Papp
2021-10-18 15:56:59 -07:00
committed by GitHub
parent c8dc309b32
commit 3deaed5733
3 changed files with 11 additions and 12 deletions
+1 -4
View File
@@ -6,10 +6,7 @@
#
#
ly_set(LY_INSTALL_ENABLED TRUE)
if(INSTALLED_ENGINE)
ly_set(LY_INSTALL_ENABLED FALSE)
endif()
set(LY_INSTALL_ENABLED TRUE CACHE BOOL "Indicates if the install process is enabled")
if(LY_INSTALL_ENABLED)
ly_get_absolute_pal_filename(pal_dir ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Platform/${PAL_PLATFORM_NAME})
+10 -7
View File
@@ -315,13 +315,16 @@ function(ly_add_target)
# Store the target so we can walk through all of them in LocationDependencies.cmake
set_property(GLOBAL APPEND PROPERTY LY_ALL_TARGETS ${interface_name})
# Store the aliased target into a DIRECTORY property
set_property(DIRECTORY APPEND PROPERTY LY_DIRECTORY_TARGETS ${interface_name})
# Store the directory path in a GLOBAL property so that it can be accessed
# in the layout install logic. Skip if the directory has already been added
get_property(ly_all_target_directories GLOBAL PROPERTY LY_ALL_TARGET_DIRECTORIES)
if(NOT CMAKE_CURRENT_SOURCE_DIR IN_LIST ly_all_target_directories)
set_property(GLOBAL APPEND PROPERTY LY_ALL_TARGET_DIRECTORIES ${CMAKE_CURRENT_SOURCE_DIR})
if(NOT ly_add_target_IMPORTED)
# Store the aliased target into a DIRECTORY property
set_property(DIRECTORY APPEND PROPERTY LY_DIRECTORY_TARGETS ${interface_name})
# Store the directory path in a GLOBAL property so that it can be accessed
# in the layout install logic. Skip if the directory has already been added
get_property(ly_all_target_directories GLOBAL PROPERTY LY_ALL_TARGET_DIRECTORIES)
if(NOT CMAKE_CURRENT_SOURCE_DIR IN_LIST ly_all_target_directories)
set_property(GLOBAL APPEND PROPERTY LY_ALL_TARGET_DIRECTORIES ${CMAKE_CURRENT_SOURCE_DIR})
endif()
endif()
# Custom commands need to be declared in the same folder as the target that they use.
@@ -385,7 +385,6 @@ function(ly_setup_cmake_install)
COMPONENT ${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}
PATTERN "__pycache__" EXCLUDE
PATTERN "Findo3de.cmake" EXCLUDE
PATTERN "ConfigurationTypes.cmake" EXCLUDE
REGEX "3rdParty/Platform\/.*\/BuiltInPackages_.*\.cmake" EXCLUDE
)
# Connect configuration types