diff options
author | Ryan OShea <ryan.oshea3@arm.com> | 2023-03-20 11:10:40 +0000 |
---|---|---|
committer | Francis Murtagh <francis.murtagh@arm.com> | 2023-05-08 16:59:40 +0000 |
commit | a3dc95ec2b0ac9e7f87dd32d03679a4b2a9b5d2a (patch) | |
tree | f65bf6ebae620be85cd1122e32889b9e8b69e1b8 /src/armnnTestUtils | |
parent | f6ed6d410dca0bbf22f338ca6e2fafd36d5c963f (diff) | |
download | armnn-a3dc95ec2b0ac9e7f87dd32d03679a4b2a9b5d2a.tar.gz |
Improve reusability of code that is defined out by cmake build paths
* Added new ARMNN_STUB_PROFILING and ARMNN_DISABLE_DYNAMIC_BACKEND
defines to replace BUILD_BARE_METAL and BUILD_EXECUTE_NETWORK_STATIC
* Add new CMake variables to disable sample apps and dynamic backends
* Improve BUILD_SHARED_LIBS CMake variable
* Add new archive output location to various libraries so that the
static libraries appear in the same location as the shared libraries
* Fixes for bare metal build
* Add ARMNN_DISABLE_FILE_SYSTEM defines to missing locations
Signed-off-by: Ryan OShea <ryan.oshea3@arm.com>
Change-Id: I1db9a8f483e7134bd261294b35240cf21b150d45
Diffstat (limited to 'src/armnnTestUtils')
-rwxr-xr-x | src/armnnTestUtils/CMakeLists.txt | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/src/armnnTestUtils/CMakeLists.txt b/src/armnnTestUtils/CMakeLists.txt index a4333cf306..b2f31245b7 100755 --- a/src/armnnTestUtils/CMakeLists.txt +++ b/src/armnnTestUtils/CMakeLists.txt @@ -31,23 +31,20 @@ list(APPEND armnnTestUtils_sources TestUtils.hpp ) -if(NOT BUILD_BARE_METAL AND NOT EXECUTE_NETWORK_STATIC) list(APPEND armnnTestUtils_sources UnitTests.cpp UnitTests.hpp ) -endif() - -if(BUILD_BARE_METAL) - add_library_ex(armnnTestUtils STATIC ${armnnTestUtils_sources}) -elseif(EXECUTE_NETWORK_STATIC) - add_library_ex(armnnTestUtils OBJECT ${armnnTestUtils_sources}) -else() +if(BUILD_SHARED_LIBS) add_library_ex(armnnTestUtils SHARED ${armnnTestUtils_sources}) +else() + add_library_ex(armnnTestUtils STATIC ${armnnTestUtils_sources}) endif() set_target_properties(armnnTestUtils PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}) +set_target_properties(armnnTestUtils PROPERTIES ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}) + target_include_directories(armnnTestUtils PUBLIC |