diff options
| author | liuwentan <[email protected]> | 2022-12-23 14:17:42 +0800 |
|---|---|---|
| committer | liuwentan <[email protected]> | 2022-12-24 22:36:36 +0800 |
| commit | af3058e9eb9c015c8cb829f26a91c6afa3fe1a61 (patch) | |
| tree | bbc1aed942026ddc9c94c257dd73706bd9d098db | |
| parent | 3cfe499fd2eca67c8c8902fc6cc538f3f74e6503 (diff) | |
fix maat_frame_version and zlog dynamic->staticv3.6.18
| -rw-r--r-- | CMakeLists.txt | 4 | ||||
| -rw-r--r-- | src/CMakeLists.txt | 4 | ||||
| -rw-r--r-- | test/CMakeLists.txt | 2 | ||||
| -rw-r--r-- | vendor/CMakeLists.txt | 21 | ||||
| -rw-r--r-- | vendor/MESA_handle_logger-dev-2.0.zip | bin | 152325 -> 152349 bytes | |||
| -rw-r--r-- | vendor/zlog-1.2.15.tar.gz | bin | 0 -> 125080 bytes |
6 files changed, 25 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index f22922b..f726b4d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required (VERSION 3.5) +cmake_minimum_required (VERSION 2.8) set(lib_name maatframe) project (maatframe) @@ -10,7 +10,7 @@ SET(CMAKE_INSTALL_PREFIX /opt/MESA/) LINK_DIRECTORIES(/opt/MESA/lib /usr/lib64) set(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} -Wall) -set(MAAT_DEPEND_DYN_LIB pcre rulescan pthread m pcre crypto z zlog) +set(MAAT_DEPEND_DYN_LIB pcre rulescan pthread m pcre crypto z) include_directories(${PROJECT_SOURCE_DIR}/inc/) include_directories(/opt/MESA/include/) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 90838cd..8c24dc2 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.5) set(MAAT_FRAME_MAJOR_VERSION 3) -set(MAAT_FRAME_MINOR_VERSION 5) +set(MAAT_FRAME_MINOR_VERSION 6) set(MAAT_FRAME_PATCH_VERSION 0) set(MAAT_FRAME_VERSION ${MAAT_FRAME_MAJOR_VERSION}.${MAAT_FRAME_MINOR_VERSION}.${MAAT_FRAME_PATCH_VERSION}) @@ -31,6 +31,7 @@ target_link_libraries(maat_frame_static igraph-static) target_link_libraries(maat_frame_static ipmatcher-static) target_link_libraries(maat_frame_static fieldstat2-static) target_link_libraries(maat_frame_static mesalogger-static) +target_link_libraries(maat_frame_static zlog-static) target_link_libraries(maat_frame_static mesahtable-static) # Shared Library Output @@ -48,6 +49,7 @@ target_link_libraries(maat_frame_shared igraph-static ${MAAT_DEPEND_DYN_LIB}) target_link_libraries(maat_frame_shared ipmatcher-static) target_link_libraries(maat_frame_shared fieldstat2-static) target_link_libraries(maat_frame_shared mesalogger-static) +target_link_libraries(maat_frame_shared zlog-static) target_link_libraries(maat_frame_shared mesahtable-static) set(CMAKE_INSTALL_PREFIX /opt/MESA/) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 09e9087..40575d2 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -6,7 +6,7 @@ add_executable(test_igraph test_igraph.cpp) target_link_libraries(test_igraph igraph-static) add_executable(test_maatframe test_maatframe.cpp) -target_link_libraries(test_maatframe maat_frame_shared mesalogger-static gtest) +target_link_libraries(test_maatframe maat_frame_shared gtest) add_executable(perf_test_maatframe perf_test_maatframe.cpp) target_link_libraries(perf_test_maatframe maat_frame_shared gtest) diff --git a/vendor/CMakeLists.txt b/vendor/CMakeLists.txt index 76a7b0d..5bbdff0 100644 --- a/vendor/CMakeLists.txt +++ b/vendor/CMakeLists.txt @@ -78,17 +78,34 @@ add_dependencies(fieldstat2-static FieldStat2) set_property(TARGET fieldstat2-static PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/lib/libMESA_field_stat2.a) set_property(TARGET fieldstat2-static PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${INSTALL_DIR}/include) +# zlog +ExternalProject_Add(zlog PREFIX zlog + URL ${CMAKE_CURRENT_SOURCE_DIR}/zlog-1.2.15.tar.gz + URL_MD5 5e79f8d08744c7fef8528dd55a3bcd2d + CONFIGURE_COMMAND "" + BUILD_COMMAND make + INSTALL_COMMAND "" + BUILD_IN_SOURCE 1) + +ExternalProject_Get_Property(zlog SOURCE_DIR) +file(MAKE_DIRECTORY ${SOURCE_DIR}/src/) + +set(ARCHIVE_OUTPUT_DIRECTORY ${SOURCE_DIR}) +add_library(zlog-static STATIC IMPORTED GLOBAL) +add_dependencies(zlog-static zlog) +set_property(TARGET zlog-static PROPERTY IMPORTED_LOCATION ${SOURCE_DIR}/src/libzlog.a) +set_property(TARGET zlog-static PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${SOURCE_DIR}/src) + # mesa_handle_logger ExternalProject_Add(MESA_handle_logger PREFIX MESA_handle_logger URL ${CMAKE_CURRENT_SOURCE_DIR}/MESA_handle_logger-dev-2.0.zip CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR> -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} -DCMAKE_C_FLAGS="-fPIC") ExternalProject_Get_Property(MESA_handle_logger INSTALL_DIR) -message(" MESA_handle_logger CMAKE_BINARY_DIR: ${CMAKE_BINARY_DIR}") file(MAKE_DIRECTORY ${INSTALL_DIR}/include) add_library(mesalogger-static STATIC IMPORTED GLOBAL) -add_dependencies(mesalogger-static MESA_handle_logger) +add_dependencies(mesalogger-static MESA_handle_logger zlog-static) set_property(TARGET mesalogger-static PROPERTY IMPORTED_LOCATION ${INSTALL_DIR}/src/MESA_handle_logger-build/libMESA_handle_logger.a) set_property(TARGET mesalogger-static PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${INSTALL_DIR}/include) diff --git a/vendor/MESA_handle_logger-dev-2.0.zip b/vendor/MESA_handle_logger-dev-2.0.zip Binary files differindex 6ebe1b1..38c374e 100644 --- a/vendor/MESA_handle_logger-dev-2.0.zip +++ b/vendor/MESA_handle_logger-dev-2.0.zip diff --git a/vendor/zlog-1.2.15.tar.gz b/vendor/zlog-1.2.15.tar.gz Binary files differnew file mode 100644 index 0000000..eb4c906 --- /dev/null +++ b/vendor/zlog-1.2.15.tar.gz |
