CMakeLists.txt 480 字节
Newer Older
H
Hongze Cheng 已提交
1
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/src/version.c.in" "${CMAKE_CURRENT_SOURCE_DIR}/src/version.c")
H
refact  
Hongze Cheng 已提交
2
aux_source_directory(src UTIL_SRC)
H
Hongze Cheng 已提交
3
add_library(util STATIC ${UTIL_SRC})
H
refact  
Hongze Cheng 已提交
4 5 6
target_include_directories(
    util
    PUBLIC "${CMAKE_SOURCE_DIR}/include/util"
S
Shengliang Guan 已提交
7
    PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
H
refact  
Hongze Cheng 已提交
8 9 10 11
)
target_link_libraries(
    util
    PRIVATE os
S
Shengliang Guan 已提交
12 13
    PUBLIC zlib
    PUBLIC lz4_static
S
Shengliang Guan 已提交
14
    PUBLIC api
D
dapan1121 已提交
15 16
)

H
refact  
Hongze Cheng 已提交
17 18 19 20
if(${BUILD_TEST})
    ADD_SUBDIRECTORY(test)
endif(${BUILD_TEST})