summaryrefslogtreecommitdiff
path: root/inference-engine/thirdparty/mkl-dnn/examples/CMakeLists.txt
blob: c9179557731d0f06b51034df55bd5ecaab8c0135 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#===============================================================================
# Copyright 2016-2018 Intel Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#===============================================================================

if (NOT WITH_EXAMPLE)
    return()
endif()

# propagate EXAMPLE specific flags
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_EXAMPLE_CCXX_FLAGS}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_EXAMPLE_CCXX_FLAGS}")

include_directories(${CMAKE_SOURCE_DIR}/include)

register_exe(simple-net-c simple_net.c "test")
register_exe(simple-net-cpp simple_net.cpp "test")
if(UNIX)
    set(LIBM m)
endif()
register_exe(simple-training-net-c simple_training_net.c "test" ${LIBM})
register_exe(simple-training-net-cpp simple_training_net.cpp "test" ${LIBM})
register_exe(simple-net-int8-cpp simple_net_int8.cpp "test")

if(HAVE_MKL)
    register_exe(simple-rnn-cpp simple_rnn.cpp "test")
    register_exe(simple-rnn-training-cpp simple_rnn_training.cpp "test")
endif()