加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
using-system-package-instead-binarylibs.patch 34.18 KB
一键复制 编辑 原始数据 按行查看 历史
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539
From 0a8df49b1df5dd25f5aa4a80db44c593a51a7396 Mon Sep 17 00:00:00 2001
From: huangji <huangji@iscas.ac.cn>
Date: Tue, 5 Nov 2024 08:12:26 +0000
Subject: [PATCH 1/4] using system package instead binarylibs
Signed-off-by: huangji <huangji@iscas.ac.cn>
---
CMakeLists.txt | 2 +
cmake/src/use-systemlib.cmake | 10 ++
contrib/pagehack/CMakeLists.txt | 2 +-
contrib/pg_xlogdump/CMakeLists.txt | 2 +-
src/CMakeLists.txt | 114 ------------------
src/bin/gs_cgroup/CMakeLists.txt | 2 +-
src/bin/gs_guc/CMakeLists.txt | 4 +-
src/bin/gs_log/CMakeLists.txt | 2 +-
src/bin/gs_persist/CMakeLists.txt | 2 +-
src/bin/initdb/CMakeLists.txt | 2 +-
src/bin/pg_basebackup/CMakeLists.txt | 6 +-
src/bin/pg_config/CMakeLists.txt | 2 +-
src/bin/pg_controldata/CMakeLists.txt | 2 +-
src/bin/pg_ctl/CMakeLists.txt | 2 +-
src/bin/pg_dump/CMakeLists.txt | 4 +-
src/bin/pg_probackup/CMakeLists.txt | 2 +-
src/bin/pg_resetxlog/CMakeLists.txt | 2 +-
src/bin/pg_upgrade/CMakeLists.txt | 2 +-
src/bin/pgxc_clean/CMakeLists.txt | 2 +-
src/bin/psql/CMakeLists.txt | 4 +-
src/bin/scripts/CMakeLists.txt | 2 +-
src/common/timezone/CMakeLists.txt | 2 +-
src/gausskernel/CMakeLists.txt | 4 +-
src/gausskernel/cbb/utils/zfiles/zip_file.cpp | 2 +-
.../security/keymgr/CMakeLists.txt | 2 +-
src/lib/gstrace/CMakeLists.txt | 2 +-
src/test/regress/CMakeLists.txt | 2 +-
27 files changed, 42 insertions(+), 144 deletions(-)
create mode 100644 cmake/src/use-systemlib.cmake
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5aab533..10d8058 100755
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -8,6 +8,8 @@ cmake_minimum_required(VERSION 3.16.5)
#project name
project(openGauss)
+include(cmake/src/use-systemlib.cmake)
+
if(POLICY CMP0068)
cmake_policy(SET CMP0068 NEW)
endif()
diff --git a/cmake/src/use-systemlib.cmake b/cmake/src/use-systemlib.cmake
new file mode 100644
index 0000000..7a4b40d
--- /dev/null
+++ b/cmake/src/use-systemlib.cmake
@@ -0,0 +1,10 @@
+find_package(PkgConfig REQUIRED)
+
+pkg_check_modules(MINIZIP REQUIRED minizip)
+include_directories(${MINIZIP_INCLUDE_DIRS})
+
+pkg_check_modules(CJSON REQUIRED libcjson)
+include_directories(${CJSON_INCLUDE_DIRS})
+
+add_library(securec INTERFACE)
+target_link_libraries(securec INTERFACE -lboundscheck)
diff --git a/contrib/pagehack/CMakeLists.txt b/contrib/pagehack/CMakeLists.txt
index b15bee1..4702797 100644
--- a/contrib/pagehack/CMakeLists.txt
+++ b/contrib/pagehack/CMakeLists.txt
@@ -14,7 +14,7 @@ if(${ENABLE_DEBUG} STREQUAL "ON")
endif()
set(pagehack_COMPILE_OPTIONS ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${CHECK_OPTIONS} ${BIN_SECURE_OPTIONS} ${OPTIMIZE_OPTIONS})
set(pagehack_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(pagehack_LINK_LIBS -lpgport -lcrypt -ldl -lm -ledit -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz -lzstd -lpagecompression -llz4)
+set(pagehack_LINK_LIBS -lpgport -lcrypt -ldl -lm -ledit -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES} -lzstd -lpagecompression -llz4)
add_bintarget(pagehack TGT_pagehack_SRC TGT_pagehack_INC "${pagehack_DEF_OPTIONS}" "${pagehack_COMPILE_OPTIONS}" "${pagehack_LINK_OPTIONS}" "${pagehack_LINK_LIBS}")
add_dependencies(pagehack pgport_static pagecompression)
target_link_directories(pagehack PUBLIC
diff --git a/contrib/pg_xlogdump/CMakeLists.txt b/contrib/pg_xlogdump/CMakeLists.txt
index d53590b..f67f8d6 100644
--- a/contrib/pg_xlogdump/CMakeLists.txt
+++ b/contrib/pg_xlogdump/CMakeLists.txt
@@ -40,7 +40,7 @@ SET(TGT_xlogdump_INC
SET(xlogdump_DEF_OPTIONS ${MACRO_OPTIONS} -DFRONTEND)
SET(xlogdump_COMPILE_OPTIONS ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${CHECK_OPTIONS} ${BIN_SECURE_OPTIONS} ${OPTIMIZE_OPTIONS})
SET(xlogdump_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-SET(xlogdump_LINK_LIBS libpgcommon.a -lpgport -lcrypt -ldl -lm -ledit -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+SET(xlogdump_LINK_LIBS libpgcommon.a -lpgport -lcrypt -ldl -lm -ledit -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
list(APPEND xlogdump_LINK_DIRS ${LIBUWAL_LINK_DIRS})
list(APPEND xlogdump_LINK_OPTIONS ${LIBUWAL_LINK_OPTIONS})
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index d9a73ae..c6f9a9d 100755
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -185,117 +185,3 @@ install(CODE "execute_process(
COMMAND cp ${CMAKE_CURRENT_SOURCE_DIR}/include/port/linux.h ${prefix_home}/include/postgresql/server/pg_config_os.h
COMMAND cp ${CMAKE_CURRENT_SOURCE_DIR}/include/cm/libpq-fe.h ${prefix_home}/include/cm-libpq-fe.h)"
)
-
-# open source install part
-if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
- install(DIRECTORY ${JAVA_HOME}/jre/ DESTINATION jre FILE_PERMISSIONS OWNER_EXECUTE GROUP_EXECUTE OWNER_READ GROUP_READ)
-endif()
-
-if("${ENABLE_MULTIPLE_NODES}" STREQUAL "OFF")
- install(DIRECTORY ${DCF_LIB_PATH} DESTINATION .)
-endif()
-if(${ENABLE_MULTIPLE_NODES}_${ENABLE_PRIVATEGAUSS} STREQUAL OFF_OFF AND NOT ${ENABLE_LITE_MODE} STREQUAL ON)
- if(EXISTS ${DMS_LIB_PATH})
- install(DIRECTORY ${DMS_LIB_PATH} DESTINATION .)
- endif()
- if(EXISTS ${DSS_LIB_PATH})
- install(DIRECTORY ${DSS_LIB_PATH} DESTINATION .)
- endif()
- if(EXISTS ${DSS_BIN_PATH})
- install(DIRECTORY ${DSS_BIN_PATH} DESTINATION . FILE_PERMISSIONS OWNER_EXECUTE GROUP_EXECUTE WORLD_EXECUTE OWNER_READ GROUP_READ WORLD_READ OWNER_WRITE)
- endif()
-endif()
-
-install(DIRECTORY ${ZSTD_LIB_PATH} DESTINATION . PATTERN "*.a" EXCLUDE)
-if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
- install(DIRECTORY ${LIBOBS_LIB_PATH} DESTINATION .)
- install(DIRECTORY ${LIBOBS_INCLUDE_PATH} DESTINATION include/postgresql/server/access/obs)
-endif()
-install(DIRECTORY ${CJSON_LIB_PATH} DESTINATION .)
-install(DIRECTORY ${CJSON_INCLUDE_PATH}/cjson DESTINATION include/postgresql/server)
-if(NOT ${ENABLE_LITE_MODE} STREQUAL ON)
- install(DIRECTORY ${ETCD_BIN_PATH} DESTINATION .)
- install(DIRECTORY ${IPERF_LIB_PATH} DESTINATION .)
-endif()
-if(NOT ${ENABLE_LITE_MODE} STREQUAL ON)
-if(NOT ${ENABLE_MULTIPLE_NODES}_${ENABLE_PRIVATEGAUSS} STREQUAL OFF_OFF)
- install(DIRECTORY ${KMC_LIB_PATH} DESTINATION .)
-endif()
-endif()
-install(DIRECTORY ${LIBCURL_LIB_PATH} DESTINATION .)
-install(DIRECTORY ${AWSSDK_LIB_PATH} DESTINATION .)
-if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
- install(DIRECTORY ${KERBEROS_SBIN_PATH}/ DESTINATION bin)
- install(DIRECTORY ${KERBEROS_BIN_PATH} DESTINATION .)
- install(DIRECTORY ${KERBEROS_LIB_PATH} DESTINATION .)
-endif()
-install(DIRECTORY ${LZ4_LIB_PATH} DESTINATION .)
-install(DIRECTORY ${LZ4_BIN_PATH} DESTINATION .)
-install(DIRECTORY ${LIBOPENSSL_BIN_PATH} DESTINATION .)
-install(DIRECTORY ${LIBOPENSSL_LIB_PATH} DESTINATION . PATTERN "*.a" EXCLUDE )
-install(DIRECTORY ${ZLIB_LIB_PATH} DESTINATION . FILES_MATCHING PATTERN "libz.*")
-
-list(FIND MACRO_OPTIONS "-D__USE_NUMA" RET_NUMA)
-if(NOT ${RET_NUMA} EQUAL -1)
- install(DIRECTORY ${NUMA_LIB_PATH} DESTINATION .)
-endif()
-
-if("${ENABLE_MOT}" STREQUAL "ON")
-install(DIRECTORY ${MASSTREE_LIB_PATH} DESTINATION .)
-install(CODE "execute_process(
- COMMAND cp ${GCC_LIB_PATH}/lib64/libatomic.so.1.2.0 ${prefix_home}/lib/libatomic.so.1.2.0
- COMMAND ln -fs libatomic.so.1.2.0 libatomic.so
- COMMAND ln -fs libatomic.so.1.2.0 libatomic.so.1
- WORKING_DIRECTORY ${prefix_home}/lib)"
-)
-install(CODE "message(\"-- Created symlink: libatomic.so -> libatomic.so.1.2.0\")")
-install(CODE "message(\"-- Created symlink: libatomic.so.1 -> libatomic.so.1.2.0\")")
-endif()
-
-install(FILES ${SECUREDYNAMICLIB_HOME}/libsecurec.so DESTINATION lib)
-install(FILES ${GCC_LIB_PATH}/lib64/libgcc_s.so.1 DESTINATION lib)
-install(FILES ${GCC_LIB_PATH}/lib64/libgomp.so DESTINATION lib)
-install(FILES ${GCC_LIB_PATH}/lib64/libgomp.so.1 DESTINATION lib)
-install(FILES ${GCC_LIB_PATH}/lib64/libgomp.so.1.0.0 DESTINATION lib)
-install(FILES ${XGBOOST_LIB_PATH}/libxgboost.so DESTINATION lib)
-if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
- install(FILES ${PLJAVA_HOME}/lib/libpljava.so DESTINATION lib)
- install(FILES ${PLJAVA_HOME}/java/pljava.jar DESTINATION lib/postgresql/java)
- install(FILES ${PLJAVA_HOME}/udstools.py DESTINATION share/postgresql/tmp)
-endif()
-if(NOT ${ENABLE_MULTIPLE_NODES}_${ENABLE_PRIVATEGAUSS} STREQUAL OFF_OFF)
- if("${SUPPORT_HOTPATCH}" STREQUAL "yes")
- install(FILES ${LIBHOTPATCH_LIB_PATH}/libdoprapatch.a DESTINATION lib)
- endif()
-endif()
-
-if("${ENABLE_MOT}" STREQUAL "ON")
- install(DIRECTORY ${MASSTREE_LIB_PATH} DESTINATION .)
- install(DIRECTORY ${GCC_LIB_PATH}/lib64/ DESTINATION lib
- FILES_MATCHING PATTERN "libatomic.so*")
-endif()
-
-install(FILES ${GCC_LIB_PATH}/lib64/libgcc_s.so.1 DESTINATION lib)
-install(DIRECTORY ${GCC_LIB_PATH}/lib64/ DESTINATION lib
- FILES_MATCHING PATTERN "libgomp.so*")
-
-install(CODE "execute_process(
- COMMAND cp ${GCC_LIB_PATH}/lib64/libstdc++.so.6.0.${LIBSTD_SUB_VERSION} ${prefix_home}/lib/libstdc++.so.6
- WORKING_DIRECTORY ${prefix_home}/lib)"
-)
-
-# install(DIRECTORY ${LIBCGROUP_LIB_PATH} DESTINATION . FILES_MATCHING PATTERN "libcgroup.so*")
-install(CODE "execute_process(
-COMMAND cp ${LIBCGROUP_LIB_PATH}/libcgroup.so.1.0.42 ${prefix_home}/lib/libcgroup.so
-COMMAND ln -fs libcgroup.so libcgroup.so.1
-WORKING_DIRECTORY ${prefix_home}/lib)"
-)
-install(CODE "message(\"-- Created symlink: libcgroup.so.1 -> libcgroup.so\")")
-
-# fastcheck part
-install(FILES ${PROJECT_SRC_DIR}/test/regress/stub/roach_api_stub/roach_api_stub.control
- DESTINATION share/postgresql/extension/
-)
-install(FILES ${PROJECT_SRC_DIR}/test/regress/stub/roach_api_stub/roach_api_stub--1.0.sql
- DESTINATION share/postgresql/extension/
-)
diff --git a/src/bin/gs_cgroup/CMakeLists.txt b/src/bin/gs_cgroup/CMakeLists.txt
index 3203cb5..e55cce5 100755
--- a/src/bin/gs_cgroup/CMakeLists.txt
+++ b/src/bin/gs_cgroup/CMakeLists.txt
@@ -18,7 +18,7 @@ set(TGT_cgroup_INC
set(cgroup_DEF_OPTIONS ${MACRO_OPTIONS})
set(cgroup_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(cgroup_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(cgroup_LINK_LIBS libelog.a -lpgport -lcrypt -ldl -lm -l${SECURE_C_CHECK} -pthread -lrt -lminiunz -lcgroup)
+set(cgroup_LINK_LIBS libelog.a -lpgport -lcrypt -ldl -lm -l${SECURE_C_CHECK} -pthread -lrt ${MINIZIP_LIBRARIES} -lcgroup)
add_bintarget(gs_cgroup TGT_cgroup_SRC TGT_cgroup_INC "${cgroup_DEF_OPTIONS}" "${cgroup_COMPILE_OPTIONS}" "${cgroup_LINK_OPTIONS}" "${cgroup_LINK_LIBS}")
add_dependencies(gs_cgroup elog_static pgport_static)
target_link_directories(gs_cgroup PUBLIC
diff --git a/src/bin/gs_guc/CMakeLists.txt b/src/bin/gs_guc/CMakeLists.txt
index 285a6e1..e742f61 100755
--- a/src/bin/gs_guc/CMakeLists.txt
+++ b/src/bin/gs_guc/CMakeLists.txt
@@ -16,7 +16,7 @@ set(TGT_guc_INC
set(guc_DEF_OPTIONS ${MACRO_OPTIONS})
set(guc_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(guc_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(guc_LINK_LIBS libelog.a libconfig.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+set(guc_LINK_LIBS libelog.a libconfig.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
set(guc_LINK_DEPEND elog_static config_static pgport_static)
set(guc_LINK_DIRS ${LIBOPENSSL_LIB_PATH} ${KERBEROS_LIB_PATH} ${CMAKE_BINARY_DIR}/lib
${LIBCURL_LIB_PATH} ${ZLIB_LIB_PATH} ${LIBCGROUP_LIB_PATH} ${LIBEDIT_LIB_PATH} ${SECURE_LIB_PATH})
@@ -54,7 +54,7 @@ set(TGT_encrypt_INC
set(encrypt_DEF_OPTIONS ${MACRO_OPTIONS})
set(encrypt_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(encrypt_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(encrypt_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+set(encrypt_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
add_bintarget(encrypt TGT_encrypt_SRC TGT_encrypt_INC "${encrypt_DEF_OPTIONS}" "${encrypt_COMPILE_OPTIONS}" "${encrypt_LINK_OPTIONS}" "${encrypt_LINK_LIBS}")
add_dependencies(encrypt elog_static pgport_static)
target_link_directories(encrypt PUBLIC
diff --git a/src/bin/gs_log/CMakeLists.txt b/src/bin/gs_log/CMakeLists.txt
index 675c303..7e7b10e 100755
--- a/src/bin/gs_log/CMakeLists.txt
+++ b/src/bin/gs_log/CMakeLists.txt
@@ -21,7 +21,7 @@ set(TGT_log_INC
set(log_DEF_OPTIONS ${MACRO_OPTIONS})
set(log_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(log_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(log_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+set(log_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
add_bintarget(gs_log TGT_log_SRC TGT_log_INC "${log_DEF_OPTIONS}" "${log_COMPILE_OPTIONS}" "${log_LINK_OPTIONS}" "${log_LINK_LIBS}")
add_dependencies(gs_log elog_static pgport_static)
target_link_directories(gs_log PUBLIC
diff --git a/src/bin/gs_persist/CMakeLists.txt b/src/bin/gs_persist/CMakeLists.txt
index bcf4468..85457fa 100644
--- a/src/bin/gs_persist/CMakeLists.txt
+++ b/src/bin/gs_persist/CMakeLists.txt
@@ -13,7 +13,7 @@ set(tgt_gssgpersist_INC
set(gssgpersist_DEF_OPTIONS ${MACRO_OPTIONS})
set(gssgpersist_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(gssgpersist_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(gssgpersist_LINK_LIBS -lsecurec -ldl -lrt)
+set(gssgpersist_LINK_LIBS -lboundscheck -ldl -lrt)
if("${ENABLE_UT}" STREQUAL "ON")
add_shared_libtarget(ut_gs_persist_lib tgt_gssgpersist_SRC tgt_gssgpersist_INC "${gssgpersist_DEF_OPTIONS}" "${gssgpersist_COMPILE_OPTIONS}" "${gssgpersist_LINK_OPTIONS}")
diff --git a/src/bin/initdb/CMakeLists.txt b/src/bin/initdb/CMakeLists.txt
index 5a5aa66..47edfe0 100755
--- a/src/bin/initdb/CMakeLists.txt
+++ b/src/bin/initdb/CMakeLists.txt
@@ -31,7 +31,7 @@ set(TGT_initdb_INC
set(initdb_DEF_OPTIONS ${MACRO_OPTIONS} -DFRONTEND)
set(initdb_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(initdb_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(initdb_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+set(initdb_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
add_bintarget(gs_initdb TGT_initdb_SRC TGT_initdb_INC "${initdb_DEF_OPTIONS}" "${initdb_COMPILE_OPTIONS}" "${initdb_LINK_OPTIONS}" "${initdb_LINK_LIBS}")
add_dependencies(gs_initdb elog_static pgport_static)
target_link_directories(gs_initdb PUBLIC
diff --git a/src/bin/pg_basebackup/CMakeLists.txt b/src/bin/pg_basebackup/CMakeLists.txt
index dc5efef..fc3dde2 100755
--- a/src/bin/pg_basebackup/CMakeLists.txt
+++ b/src/bin/pg_basebackup/CMakeLists.txt
@@ -33,7 +33,7 @@ set(TGT_basebackup_INC
set(basebackup_DEF_OPTIONS ${MACRO_OPTIONS} -DHAVE_LIBZ -DFRONTEND)
set(basebackup_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(basebackup_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(basebackup_LINK_LIBS lib_string_obj libelog.a libbuildquery.a libpgcommon.a libhotpatchclient.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz -llz4 -lzstd -lpagecompression)
+set(basebackup_LINK_LIBS lib_string_obj libelog.a libbuildquery.a libpgcommon.a libhotpatchclient.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES} -llz4 -lzstd -lpagecompression)
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND basebackup_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
endif()
@@ -79,7 +79,7 @@ set(TGT_receivexlog_INC
set(receivexlog_DEF_OPTIONS ${MACRO_OPTIONS} -DHAVE_LIBZ -DFRONTEND)
set(receivexlog_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(receivexlog_LINK_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS} -pie)
-set(receivexlog_LINK_LIBS lib_string_obj libelog.a libbuildquery.a libpgcommon.a libhotpatchclient.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz -llz4)
+set(receivexlog_LINK_LIBS lib_string_obj libelog.a libbuildquery.a libpgcommon.a libhotpatchclient.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES} -llz4)
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND receivexlog_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
endif()
@@ -126,7 +126,7 @@ set(TGT_recvlogical_INC
set(recvlogical_DEF_OPTIONS ${MACRO_OPTIONS} -DHAVE_LIBZ -DFRONTEND)
set(recvlogical_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(recvlogical_LINK_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS} -pie)
-set(recvlogical_LINK_LIBS lib_string_obj libelog.a libbuildquery.a libpgcommon.a libhotpatchclient.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz -llz4)
+set(recvlogical_LINK_LIBS lib_string_obj libelog.a libbuildquery.a libpgcommon.a libhotpatchclient.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES} -llz4)
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND recvlogical_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
endif()
diff --git a/src/bin/pg_config/CMakeLists.txt b/src/bin/pg_config/CMakeLists.txt
index 1bf4f96..fa0b330 100755
--- a/src/bin/pg_config/CMakeLists.txt
+++ b/src/bin/pg_config/CMakeLists.txt
@@ -17,7 +17,7 @@ SET(TGT_pgconfig_INC
SET(pgconfig_DEF_OPTIONS ${MACRO_OPTIONS})
SET(pgconfig_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS} -fstack-protector-all)
SET(pgconfig_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-SET(pgconfig_LINK_LIBS libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+SET(pgconfig_LINK_LIBS libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
add_bintarget(pg_config TGT_pgconfig_SRC TGT_pgconfig_INC "${pgconfig_DEF_OPTIONS}" "${pgconfig_COMPILE_OPTIONS}" "${pgconfig_LINK_OPTIONS}" "${pgconfig_LINK_LIBS}")
add_dependencies(pg_config pgport_static)
target_link_directories(pg_config PUBLIC
diff --git a/src/bin/pg_controldata/CMakeLists.txt b/src/bin/pg_controldata/CMakeLists.txt
index 0da485c..5a4a174 100755
--- a/src/bin/pg_controldata/CMakeLists.txt
+++ b/src/bin/pg_controldata/CMakeLists.txt
@@ -19,7 +19,7 @@ set(TGT_controldata_INC
set(controldata_DEF_OPTIONS ${MACRO_OPTIONS})
set(controldata_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(controldata_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(controldata_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+set(controldata_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
add_bintarget(pg_controldata TGT_controldata_SRC TGT_controldata_INC "${controldata_DEF_OPTIONS}" "${controldata_COMPILE_OPTIONS}" "${controldata_LINK_OPTIONS}" "${controldata_LINK_LIBS}")
add_dependencies(pg_controldata elog_static pgport_static)
target_link_directories(pg_controldata PUBLIC
diff --git a/src/bin/pg_ctl/CMakeLists.txt b/src/bin/pg_ctl/CMakeLists.txt
index 7268a15..4dbd464 100755
--- a/src/bin/pg_ctl/CMakeLists.txt
+++ b/src/bin/pg_ctl/CMakeLists.txt
@@ -30,7 +30,7 @@ set(TGT_gsctl_INC
set(gsctl_DEF_OPTIONS ${MACRO_OPTIONS} -DHAVE_LIBZ -DFRONTEND)
set(gsctl_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(gsctl_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(gsctl_LINK_LIBS libelog.a libbuildquery.a pg_rewind.a libpgcommon.a libhotpatchclient.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz -lminiunz -lpagecompression -lzstd -llz4)
+set(gsctl_LINK_LIBS libelog.a libbuildquery.a pg_rewind.a libpgcommon.a libhotpatchclient.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz ${MINIZIP_LIBRARIES} -lpagecompression -lzstd -llz4)
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND gsctl_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
endif()
diff --git a/src/bin/pg_dump/CMakeLists.txt b/src/bin/pg_dump/CMakeLists.txt
index b65f7f6..c6dec47 100755
--- a/src/bin/pg_dump/CMakeLists.txt
+++ b/src/bin/pg_dump/CMakeLists.txt
@@ -72,9 +72,9 @@ endif()
set(dump_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(dump_LINK_OPTIONS ${BIN_LINK_OPTIONS})
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
- set(dump_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz -lpq_ce -lcurl -lcjson)
+ set(dump_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES} -lpq_ce -lcurl -lcjson)
else()
- set(dump_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz -lpq -lcurl -lcjson)
+ set(dump_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES} -lpq -lcurl -lcjson)
endif()
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND dump_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
diff --git a/src/bin/pg_probackup/CMakeLists.txt b/src/bin/pg_probackup/CMakeLists.txt
index 062d37c..979c0b6 100755
--- a/src/bin/pg_probackup/CMakeLists.txt
+++ b/src/bin/pg_probackup/CMakeLists.txt
@@ -22,7 +22,7 @@ set(TGT_probackup_INC ${ZLIB_INCLUDE_PATH} ${LZ4_INCLUDE_PATH} ${ZSTD_INCLUDE_PA
set(probackup_DEF_OPTIONS ${MACRO_OPTIONS} -DFRONTEND -DHAVE_LIBZ)
set(probackup_COMPILE_OPTIONS ${PROTECT_OPTIONS} ${BIN_SECURE_OPTIONS} ${OS_OPTIONS} ${WARNING_OPTIONS} ${OPTIMIZE_OPTIONS} ${CHECK_OPTIONS})
set(probackup_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(probackup_LINK_LIBS libpgcommon.a libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz -llz4 -lpq -lpagecompression -lzstd -laws-cpp-sdk-core -laws-cpp-sdk-s3)
+set(probackup_LINK_LIBS libpgcommon.a libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES} -llz4 -lpq -lpagecompression -lzstd -laws-cpp-sdk-core -laws-cpp-sdk-s3)
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND probackup_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
endif()
diff --git a/src/bin/pg_resetxlog/CMakeLists.txt b/src/bin/pg_resetxlog/CMakeLists.txt
index f8b1a88..e7c210a 100755
--- a/src/bin/pg_resetxlog/CMakeLists.txt
+++ b/src/bin/pg_resetxlog/CMakeLists.txt
@@ -17,7 +17,7 @@ set(TGT_resetxlog_INC
set(resetxlog_DEF_OPTIONS ${MACRO_OPTIONS})
set(resetxlog_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(resetxlog_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(resetxlog_LINK_LIBS libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+set(resetxlog_LINK_LIBS libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
add_bintarget(pg_resetxlog TGT_resetxlog_SRC TGT_resetxlog_INC "${resetxlog_DEF_OPTIONS}" "${resetxlog_COMPILE_OPTIONS}" "${resetxlog_LINK_OPTIONS}" "${resetxlog_LINK_LIBS}")
add_dependencies(pg_resetxlog pgport_static)
target_link_directories(pg_resetxlog PUBLIC
diff --git a/src/bin/pg_upgrade/CMakeLists.txt b/src/bin/pg_upgrade/CMakeLists.txt
index 6ac9de7..e2966c8 100755
--- a/src/bin/pg_upgrade/CMakeLists.txt
+++ b/src/bin/pg_upgrade/CMakeLists.txt
@@ -16,7 +16,7 @@ set(TGT_format_INC
set(format_DEF_OPTIONS ${MACRO_OPTIONS})
set(format_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(format_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(format_LINK_LIBS libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz)
+set(format_LINK_LIBS libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES})
add_bintarget(pg_format_cu TGT_format_SRC TGT_format_INC "${format_DEF_OPTIONS}" "${format_COMPILE_OPTIONS}" "${format_LINK_OPTIONS}" "${format_LINK_LIBS}")
add_dependencies(pg_format_cu pgport_static)
target_link_directories(pg_format_cu PUBLIC
diff --git a/src/bin/pgxc_clean/CMakeLists.txt b/src/bin/pgxc_clean/CMakeLists.txt
index 31ee01c..2f98ab5 100755
--- a/src/bin/pgxc_clean/CMakeLists.txt
+++ b/src/bin/pgxc_clean/CMakeLists.txt
@@ -16,7 +16,7 @@ set(TGT_clean_INC
set(clean_DEF_OPTIONS ${MACRO_OPTIONS} -D_FORTIFY_SOURCE=2)
set(clean_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS} -O2)
set(clean_LINK_OPTIONS ${BIN_LINK_OPTIONS} -s)
-set(clean_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz -lminiunz -lpq)
+set(clean_LINK_LIBS libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -lrt -lz ${MINIZIP_LIBRARIES} -lpq)
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND clean_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
endif()
diff --git a/src/bin/psql/CMakeLists.txt b/src/bin/psql/CMakeLists.txt
index 3b69e49..d7d270e 100755
--- a/src/bin/psql/CMakeLists.txt
+++ b/src/bin/psql/CMakeLists.txt
@@ -72,9 +72,9 @@ endif()
set(gsql_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(gsql_LINK_OPTIONS ${BIN_LINK_OPTIONS})
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
- set(gsql_LINK_LIBS utils_aes_aes libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz -lminiunz -ledit -lcjson -lcurl -lpq_ce -lncurses)
+ set(gsql_LINK_LIBS utils_aes_aes libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz ${MINIZIP_LIBRARIES} -ledit -lcjson -lcurl -lpq_ce -lncurses)
else()
- set(gsql_LINK_LIBS utils_aes_aes libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz -lminiunz -ledit -lcjson -lcurl -lpq -lncurses)
+ set(gsql_LINK_LIBS utils_aes_aes libelog.a libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz ${MINIZIP_LIBRARIES} -ledit -lcjson -lcurl -lpq -lncurses)
endif()
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND gsql_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
diff --git a/src/bin/scripts/CMakeLists.txt b/src/bin/scripts/CMakeLists.txt
index da7a061..f82977a 100755
--- a/src/bin/scripts/CMakeLists.txt
+++ b/src/bin/scripts/CMakeLists.txt
@@ -95,7 +95,7 @@ set(TGT_scripts_INC
set(scripts_DEF_OPTIONS ${MACRO_OPTIONS})
set(scripts_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(scripts_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(scripts_LINK_LIBS libelog.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz -lminiunz)
+set(scripts_LINK_LIBS libelog.a libpgport.a -lpq -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz ${MINIZIP_LIBRARIES})
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND scripts_LINK_LIBS -lgssapi_krb5_gauss -lgssrpc_gauss -lkrb5_gauss -lkrb5support_gauss -lk5crypto_gauss -lcom_err_gauss)
endif()
diff --git a/src/common/timezone/CMakeLists.txt b/src/common/timezone/CMakeLists.txt
index 491fae5..63fd8b2 100755
--- a/src/common/timezone/CMakeLists.txt
+++ b/src/common/timezone/CMakeLists.txt
@@ -14,7 +14,7 @@ set(TGT_zic_INC
set(zic_DEF_OPTIONS ${MACRO_OPTIONS})
set(zic_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(zic_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(zic_LINK_LIBS libpgport.a -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz -lminiunz)
+set(zic_LINK_LIBS libpgport.a -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz ${MINIZIP_LIBRARIES})
add_bintarget(zic TGT_zic_SRC TGT_zic_INC "${zic_DEF_OPTIONS}" "${zic_COMPILE_OPTIONS}" "${zic_LINK_OPTIONS}" "${zic_LINK_LIBS}")
add_dependencies(zic pgport_static)
target_link_directories(zic PUBLIC
diff --git a/src/gausskernel/CMakeLists.txt b/src/gausskernel/CMakeLists.txt
index 0d1aefd..3a7acd4 100755
--- a/src/gausskernel/CMakeLists.txt
+++ b/src/gausskernel/CMakeLists.txt
@@ -300,9 +300,9 @@ if(${USE_LIBXML})
endif()
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
- list(APPEND gaussdb_LINK_LIBS -lz -lminiunz -leSDKOBS -leSDKLogAPI -lpcre -liconv -lnghttp2 -llog4cpp -lcurl -llz4 -lcjson -l${JEMALLOC_LIB_NAME} -lcgroup -lzstd -lcom_err_gauss -lgssapi_krb5_gauss -lkrb5_gauss -lgssrpc_gauss -lk5crypto_gauss -lkadm5clnt_mit -lkadm5srv_mit -lkdb5 -lkrb5support_gauss -lstdc++ -lboost_thread -lboost_chrono -lboost_system -lboost_atomic -lxml2 -laio -lncurses -ltinfo -latomic)
+ list(APPEND gaussdb_LINK_LIBS -lz ${MINIZIP_LIBRARIES} -leSDKOBS -leSDKLogAPI -lpcre -liconv -lnghttp2 -llog4cpp -lcurl -llz4 -lcjson -l${JEMALLOC_LIB_NAME} -lcgroup -lzstd -lcom_err_gauss -lgssapi_krb5_gauss -lkrb5_gauss -lgssrpc_gauss -lk5crypto_gauss -lkadm5clnt_mit -lkadm5srv_mit -lkdb5 -lkrb5support_gauss -lstdc++ -lboost_thread -lboost_chrono -lboost_system -lboost_atomic -lxml2 -laio -lncurses -ltinfo -latomic)
else()
- list(APPEND gaussdb_LINK_LIBS -lz -lminiunz -lcurl -llz4 -lcjson -l${JEMALLOC_LIB_NAME} -lcgroup -lzstd -lncurses -ltinfo -lboost_thread -lboost_chrono -lboost_system -lboost_atomic)
+ list(APPEND gaussdb_LINK_LIBS -lz ${MINIZIP_LIBRARIES} -lcurl -llz4 -lcjson -l${JEMALLOC_LIB_NAME} -lcgroup -lzstd -lncurses -ltinfo -lboost_thread -lboost_chrono -lboost_system -lboost_atomic)
endif()
if(NOT "${ENABLE_JEMALLOC}" STREQUAL "ON")
diff --git a/src/gausskernel/cbb/utils/zfiles/zip_file.cpp b/src/gausskernel/cbb/utils/zfiles/zip_file.cpp
index dfe7479..638580f 100644
--- a/src/gausskernel/cbb/utils/zfiles/zip_file.cpp
+++ b/src/gausskernel/cbb/utils/zfiles/zip_file.cpp
@@ -39,7 +39,7 @@ static void memcnxt_pfree(voidp p)
*/
void pm_set_unzip_memfuncs(void)
{
- setUnzipMemoryFunc(memcnxt_palloc, memcnxt_pfree);
+ // setUnzipMemoryFunc(memcnxt_palloc, memcnxt_pfree);
}
/* open a log file using vfd method */
diff --git a/src/gausskernel/security/keymgr/CMakeLists.txt b/src/gausskernel/security/keymgr/CMakeLists.txt
index 2a15745..16560e5 100755
--- a/src/gausskernel/security/keymgr/CMakeLists.txt
+++ b/src/gausskernel/security/keymgr/CMakeLists.txt
@@ -64,7 +64,7 @@ add_static_libtarget(keymgr
if("${ENABLE_KT}" STREQUAL "ON")
add_dependencies(keymgr gs_ktool)
endif()
-set(libkey_LINKS -lcjson -lcurl -lsecurec -lssl -lcrypto -ldl -lrt)
+set(libkey_LINKS -lcjson -lcurl -lboundscheck -lssl -lcrypto -ldl -lrt)
if("${ENABLE_KT}" STREQUAL "ON")
list(APPEND libkey_LINKS -lgs_ktool -lkmc)
endif()
diff --git a/src/lib/gstrace/CMakeLists.txt b/src/lib/gstrace/CMakeLists.txt
index 803f369..487ffb8 100755
--- a/src/lib/gstrace/CMakeLists.txt
+++ b/src/lib/gstrace/CMakeLists.txt
@@ -16,7 +16,7 @@ set(TGT_trace_INC
set(trace_DEF_OPTIONS ${MACRO_OPTIONS})
set(trace_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(trace_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(trace_LINK_LIBS libgstrace.a -lcgroup libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz -lminiunz)
+set(trace_LINK_LIBS libgstrace.a -lcgroup libpgport.a -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz ${MINIZIP_LIBRARIES})
if(NOT "${ENABLE_LITE_MODE}" STREQUAL "ON")
list(APPEND trace_LINK_LIBS -lgssapi_krb5_gauss -lkrb5_gauss -lk5crypto_gauss -lcom_err_gauss -lkrb5support_gauss)
endif()
diff --git a/src/test/regress/CMakeLists.txt b/src/test/regress/CMakeLists.txt
index 1bc95c5..0cd3133 100755
--- a/src/test/regress/CMakeLists.txt
+++ b/src/test/regress/CMakeLists.txt
@@ -15,7 +15,7 @@ set(pg_regress_single_DEF_OPTIONS ${MACRO_OPTIONS} -DHOST_TUPLE="${HOST_TUPLE}"
set(pg_regress_single_main_DEF_OPTIONS ${MACRO_OPTIONS})
set(pg_regress_single_COMPILE_OPTIONS ${OPTIMIZE_OPTIONS} ${OS_OPTIONS} ${PROTECT_OPTIONS} ${WARNING_OPTIONS} ${BIN_SECURE_OPTIONS} ${CHECK_OPTIONS})
set(pg_regress_single_LINK_OPTIONS ${BIN_LINK_OPTIONS})
-set(pg_regress_single_LINK_LIBS pg_regress_single_obj -lpgport -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz -lminiunz)
+set(pg_regress_single_LINK_LIBS pg_regress_single_obj -lpgport -lcrypt -ldl -lm -lssl -lcrypto -l${SECURE_C_CHECK} -pthread -lrt -lz ${MINIZIP_LIBRARIES})
add_static_objtarget(pg_regress_single_obj TGT_pg_regress_single_SRC TGT_pg_regress_single_INC "${pg_regress_single_DEF_OPTIONS}" "${pg_regress_single_COMPILE_OPTIONS}" "${pg_regress_single_LINK_OPTIONS}")
add_bintarget(pg_regress_single TGT_pg_regress_single_main_SRC TGT_pg_regress_single_INC "${pg_regress_single_main_DEF_OPTIONS}" "${pg_regress_single_COMPILE_OPTIONS}" "${pg_regress_single_LINK_OPTIONS}" "${pg_regress_single_LINK_LIBS}")
add_dependencies(pg_regress_single pg_regress_single_obj pgport_static)
--
2.33.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化