blob: 70dfd67728cf10926b81aa77942df72026f8649c [file] [log] [blame]
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001# Copyright (c) 2017 ARM Limited.
2#
3# SPDX-License-Identifier: MIT
4#
5# Permission is hereby granted, free of charge, to any person obtaining a copy
6# of this software and associated documentation files (the "Software"), to
7# deal in the Software without restriction, including without limitation the
8# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
9# sell copies of the Software, and to permit persons to whom the Software is
10# furnished to do so, subject to the following conditions:
11#
12# The above copyright notice and this permission notice shall be included in all
13# copies or substantial portions of the Software.
14#
15# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21# SOFTWARE.
22cmake_minimum_required (VERSION 3.1)
23project (arm_compute_test)
24
25set(CMAKE_CXX_STANDARD 11)
26set(CMAKE_CXX_STANDARD_REQUIRED ON)
27
28add_library(boost_unit_test_framework STATIC IMPORTED)
29set_target_properties(boost_unit_test_framework PROPERTIES
30 IMPORTED_LOCATION "${CMAKE_SOURCE_DIR}/../3rdparty/linux/armv7a/libboost_unit_test_framework.a"
31)
32
33add_library(boost_program_options STATIC IMPORTED)
34set_target_properties(boost_program_options PROPERTIES
35 IMPORTED_LOCATION "${CMAKE_SOURCE_DIR}/../3rdparty/linux/armv7a/libboost_program_options.a"
36)
37
38add_library(arm_compute SHARED IMPORTED)
39set_target_properties(arm_compute PROPERTIES
40 IMPORTED_LOCATION "${CMAKE_SOURCE_DIR}/../build/libarm_compute.so"
41)
42
43include_directories("${CMAKE_SOURCE_DIR}")
44include_directories("${CMAKE_SOURCE_DIR}/..")
45include_directories("${CMAKE_SOURCE_DIR}/../3rdparty/include/")
46
Moritz Pflanzerfb5aabb2017-07-18 14:39:55 +010047# AssetsLibrary
Anthony Barbier6ff3b192017-09-04 18:44:23 +010048set(tensor_library_SOURCE_FILES
49 ${CMAKE_SOURCE_DIR}/RawTensor.h
50 ${CMAKE_SOURCE_DIR}/RawTensor.cpp
51 ${CMAKE_SOURCE_DIR}/TensorCache.h
Moritz Pflanzerfb5aabb2017-07-18 14:39:55 +010052 ${CMAKE_SOURCE_DIR}/AssetsLibrary.h
53 ${CMAKE_SOURCE_DIR}/AssetsLibrary.cpp
Anthony Barbier6ff3b192017-09-04 18:44:23 +010054)
55
56add_library(tensor_library OBJECT
57 ${tensor_library_SOURCE_FILES}
58)
59
60set(arm_compute_test_SOURCE_FILES
61 ${CMAKE_SOURCE_DIR}/BorderModeDataset.h
62 ${CMAKE_SOURCE_DIR}/ConvertPolicyDataset.h
63 ${CMAKE_SOURCE_DIR}/Globals.h
64 ${CMAKE_SOURCE_DIR}/IAccessor.h
65 ${CMAKE_SOURCE_DIR}/ImageDatasets.h
66 ${CMAKE_SOURCE_DIR}/InterpolationPolicyDataset.h
67 ${CMAKE_SOURCE_DIR}/NormalizationTypeDataset.h
68 ${CMAKE_SOURCE_DIR}/ProgramOptions.h
69 ${CMAKE_SOURCE_DIR}/ProgramOptions.cpp
70 ${CMAKE_SOURCE_DIR}/RoundingPolicyDataset.h
71 ${CMAKE_SOURCE_DIR}/ShapeDatasets.h
72 ${CMAKE_SOURCE_DIR}/TypePrinter.h
73 ${CMAKE_SOURCE_DIR}/TypeReader.h
74 ${CMAKE_SOURCE_DIR}/UserConfiguration.h
75 ${CMAKE_SOURCE_DIR}/UserConfiguration.cpp
76 ${CMAKE_SOURCE_DIR}/Utils.h
77 ${CMAKE_SOURCE_DIR}/boost_wrapper.h
78)
79
80add_library(arm_compute_test OBJECT
81 ${arm_compute_test_SOURCE_FILES}
82)
83
84add_subdirectory(validation)
85add_subdirectory(benchmark)