2020-12-01 18:35:15 +08:00
|
|
|
include_directories(${PYTHON_INCLUDE_DIRS})
|
|
|
|
include_directories(${MS_CCSRC_PATH})
|
|
|
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
|
|
|
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/stub/runtime/)
|
2020-12-05 12:16:18 +08:00
|
|
|
include_directories(${CMAKE_SOURCE_DIR}/mindspore/ccsrc)
|
2021-04-17 15:44:57 +08:00
|
|
|
include_directories(${CMAKE_SOURCE_DIR}/mindspore/ccsrc/minddata/dataset)
|
2020-12-05 12:16:18 +08:00
|
|
|
include_directories(${CMAKE_SOURCE_DIR}/mindspore/core)
|
2020-12-01 18:35:15 +08:00
|
|
|
include_directories(${CMAKE_BINARY_DIR})
|
|
|
|
include_directories(${CUDA_INCLUDE_DIRS})
|
|
|
|
|
2021-02-05 16:46:24 +08:00
|
|
|
if(ENABLE_ACL)
|
|
|
|
add_definitions(-D ENABLE_ACL)
|
|
|
|
endif()
|
2020-12-01 18:35:15 +08:00
|
|
|
file(GLOB_RECURSE CXX_ST_SRC RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.cc)
|
|
|
|
add_executable(st_tests ${CXX_ST_SRC})
|
2020-12-05 12:16:18 +08:00
|
|
|
target_link_libraries(st_tests PRIVATE mindspore_shared_lib _c_dataengine mindspore::gtest)
|
2022-01-24 16:23:48 +08:00
|
|
|
target_link_options(st_tests PRIVATE -Wl,--unresolved-symbols=ignore-all)
|
2020-12-30 09:40:31 +08:00
|
|
|
set_target_properties(st_tests PROPERTIES SKIP_BUILD_RPATH TRUE RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR})
|
|
|
|
file(COPY ${gtest_LIBPATH}/libgtest${CMAKE_SHARED_LIBRARY_SUFFIX} DESTINATION ${CMAKE_CURRENT_SOURCE_DIR})
|