summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
author박종현/동작제어Lab(SR)/Senior Engineer/삼성전자 <jh1302.park@samsung.com>2018-05-28 13:32:49 +0900
committer서상민/동작제어Lab(SR)/Senior Engineer/삼성전자 <sangmin7.seo@samsung.com>2018-05-28 13:32:49 +0900
commitec683653855374ebd4af912710676eecfce08f44 (patch)
tree584b6d38cc412b08172510a470fc97e78c8ed24f /CMakeLists.txt
parent77fc8e51800db628c6b3ed5eeb3c03cc9309d95b (diff)
downloadnnfw-ec683653855374ebd4af912710676eecfce08f44.tar.gz
nnfw-ec683653855374ebd4af912710676eecfce08f44.tar.bz2
nnfw-ec683653855374ebd4af912710676eecfce08f44.zip
Introduce 'nnfw_find_package' (#1372)
This commit introduces 'nnfw_find_package' macro which allows users to write and use nnfw-internal CMake modules (similarly as modules provided via find_package). Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ae2109084..97e84606b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,6 +2,10 @@ cmake_minimum_required(VERSION 3.1)
project(nnfw)
+macro(nnfw_find_package PREFIX)
+ find_package(${PREFIX} CONFIG NO_DEFAULT_PATH PATHS ${CMAKE_SOURCE_DIR}/cmake/packages ${ARGN})
+endmacro(nnfw_find_package)
+
if(CMAKE_VERSION VERSION_LESS 3.1.0)
set(CMAKE_CXX_FLAGS "-std=c++11")
else(CMAKE_VERSION VERSION_LESS 3.1.0)