Files
o3de/Templates/PythonGem/Template/Code/CMakeLists.txt
T
Jonny Galloway d7045f4c31 Scaffold PythonGem template (#4888)
* Renamed ctest_pytest.ini to pytest.ini so it is used by default, added TestSuite_ as collection file (#4822)

* Fixed warnings of unused marks, renamed ctest_pytest.ini to pytest.ini to better consistency on runs

* Fixed some test suites to run propertly

* Fix missing arguments

* Fixed missing cmakelists and renamed missing file

* Temp disable editor_testing_tests as timeout in jenkins

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* scaffold PythonGem template

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* CustomTool was not added to CMakeLists

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* Update Templates/PythonGem/Template/Code/CMakeLists.txt

makes sense thank you for the help

Co-authored-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* Update Templates/PythonGem/Template/Code/CMakeLists.txt

Co-authored-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* Delete  ${NameLower}_tests_files.cmake

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* suggested changes made

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* cleanup not needed files

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* fix up template.json

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* made a correction

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* made a correction

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* fixes

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* fixes

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* more fixes, fixed a file name

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* Added helper method to az_qt_helpers for retrieving the main window instance.

Signed-off-by: Chris Galvan <chgalvan@amazon.com>

* additional fixes

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* Fix for AP trowing errors at boot (can not get mainwindow)

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* Added missing EBus connect/disconnect calls in the EditorSystemComponent


Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* additional fix up

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

* adding dialog internals

Signed-off-by: Jonny Gallowy <gallowj@amazon.com>

Co-authored-by: AMZN-AlexOteiza <82234181+AMZN-AlexOteiza@users.noreply.github.com>
Co-authored-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
Co-authored-by: Chris Galvan <chgalvan@amazon.com>
2021-10-25 18:18:27 -05:00

77 lines
3.0 KiB
CMake

# {BEGIN_LICENSE}
# Copyright (c) Contributors to the Open 3D Engine Project.
# For complete copyright and license terms please see the LICENSE at the root of this distribution.
#
# SPDX-License-Identifier: Apache-2.0 OR MIT
#
# {END_LICENSE}
# Currently we are in the Code folder: ${CMAKE_CURRENT_LIST_DIR}
# Get the platform specific folder ${pal_dir} for the current folder: ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME}
# Note: ly_get_list_relative_pal_filename will take care of the details for us, as this may be a restricted platform
# in which case it will see if that platform is present here or in the restricted folder.
# i.e. It could here in our gem : Gems/${Name}/Code/Platform/<platorm_name> or
# <restricted_folder>/<platform_name>/Gems/${Name}/Code
ly_get_list_relative_pal_filename(pal_dir ${CMAKE_CURRENT_LIST_DIR}/Platform/${PAL_PLATFORM_NAME} ${o3de_gem_restricted_path} ${o3de_gem_path} ${o3de_gem_name})
# Now that we have the platform abstraction layer (PAL) folder for this folder, thats where we will find the
# traits for this platform. Traits for a platform are defines for things like whether or not something in this gem
# is supported by this platform.
include(${pal_dir}/PAL_${PAL_PLATFORM_NAME_LOWERCASE}.cmake)
# If we are on a host platform, we want to add the host tools targets like the ${Name}.Editor target which
# will also depend on ${Name}.Static
if(PAL_TRAIT_BUILD_HOST_TOOLS)
ly_add_target(
NAME ${Name}.Editor.Static STATIC
NAMESPACE Gem
FILES_CMAKE
${NameLower}_editor_files.cmake
INCLUDE_DIRECTORIES
PRIVATE
Source
PUBLIC
Include
BUILD_DEPENDENCIES
PUBLIC
AZ::AzToolsFramework
)
ly_add_target(
NAME ${Name}.Editor GEM_MODULE
NAMESPACE Gem
AUTOMOC
FILES_CMAKE
${NameLower}_editor_shared_files.cmake
INCLUDE_DIRECTORIES
PRIVATE
Source
PUBLIC
Include
BUILD_DEPENDENCIES
PUBLIC
Gem::${Name}.Editor.Static
)
# By default, we will specify that the above target ${Name} would be used by
# Tool and Builder type targets when this gem is enabled. If you don't want it
# active in Tools or Builders by default, delete one of both of the following lines:
ly_create_alias(NAME ${Name}.Tools NAMESPACE Gem TARGETS Gem::${Name}.Editor)
ly_create_alias(NAME ${Name}.Builders NAMESPACE Gem TARGETS Gem::${Name}.Editor)
endif()
################################################################################
# Tests
################################################################################
# See if globally, tests are supported
if(PAL_TRAIT_BUILD_TESTS_SUPPORTED)
# We globally support tests, see if we support tests on this platform for ${Name}.Static
# If we are a host platform we want to add tools test like editor tests here
if(PAL_TRAIT_BUILD_HOST_TOOLS)
endif()
endif()