• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1file(GLOB utility_headfiles include/*.h)
2file(GLOB utility_extra_headfiles include/extra/*.h)
3
4set(utility_sources
5     ${CMAKE_CURRENT_SOURCE_DIR}/dynamic_module.cpp
6     ${CMAKE_CURRENT_SOURCE_DIR}/time_util.cpp
7     ${CMAKE_CURRENT_SOURCE_DIR}/file_util.cpp
8)
9
10if(WIN32)
11    file(GLOB utility_platform_sources platform/windows/*.cpp)
12elseif(UNIX)
13    set(utility_platform_sources
14        ${CMAKE_CURRENT_SOURCE_DIR}/platform/linux/time_util.cpp
15        ${CMAKE_CURRENT_SOURCE_DIR}/platform/linux/thread_util.cpp
16        ${CMAKE_CURRENT_SOURCE_DIR}/platform/linux/file_util.cpp
17        ${CMAKE_CURRENT_SOURCE_DIR}/platform/ohos/common_utils.cpp)
18endif()
19
20target_sources(${PROJECT_NAME}
21    PRIVATE
22    ${utility_sources}
23    ${utility_platform_sources}
24    ${utility_headfiles}
25    ${utility_extra_headfiles})
26target_include_directories(${PROJECT_NAME} PUBLIC
27        include
28        include/extra)