From 59c6babc06f9bbb6b051366fcd2bb8aa92227f57 Mon Sep 17 00:00:00 2001 From: Sadik Armagan Date: Mon, 20 Jun 2022 17:25:17 +0100 Subject: IVGCVSW-6989 'Fixed build issue' Signed-off-by: Sadik Armagan Change-Id: I20e22821b6d4532953ddec2a8eac2a0f09e8013b --- CMakeLists.txt | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 0b535b234f..959675db85 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,5 @@ # -# Copyright © 2020 Arm Ltd and Contributors. All rights reserved. +# Copyright © 2022 Arm Ltd and Contributors. All rights reserved. # Copyright 2020 NXP # SPDX-License-Identifier: MIT # @@ -116,7 +116,9 @@ list(APPEND armnnUtils_sources src/armnnUtils/Transpose.cpp ) -add_library_ex(armnnUtils OBJECT ${armnnUtils_sources}) +add_library(armnnUtilsObj OBJECT ${armnnUtils_sources}) +add_library_ex(armnnUtils STATIC ${armnnUtils_sources}) + target_include_directories(armnnUtils PRIVATE src/backends) if(BUILD_ONNX_PARSER) @@ -816,7 +818,7 @@ if(BUILD_UNIT_TESTS) target_link_libraries(UnitTests ${CMAKE_THREAD_LIBS_INIT}) target_link_libraries(UnitTests armnn) - target_link_libraries(UnitTests armnnUtils) + target_link_libraries(UnitTests $) target_link_libraries(UnitTests armnnTestUtils) if(BUILD_GATORD_MOCK) @@ -963,6 +965,14 @@ install( ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} ) +install( + TARGETS armnnUtilsObj + EXPORT armnn-targets + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + OBJECTS DESTINATION ${CMAKE_INSTALL_LIBDIR} +) + #################################################### ## Set export alias set_target_properties(armnn -- cgit v1.2.1