From 61bb97a6bea767c77c358520fecd8098b0b46866 Mon Sep 17 00:00:00 2001 From: zhang_xubo <2578876417@qq.com> Date: Mon, 14 Aug 2023 09:48:14 +0800 Subject: [PATCH] fix compile error in openeuler2309 branch (cherry picked from commit 0969e55b2cc500b461400361d3b3b671e8a3c2d3) --- compile_2309.patch | 40 ++++++++++++++++++++++++++++++++++++++++ opengauss-server.spec | 7 ++++++- 2 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 compile_2309.patch diff --git a/compile_2309.patch b/compile_2309.patch new file mode 100644 index 0000000..0ef7b50 --- /dev/null +++ b/compile_2309.patch @@ -0,0 +1,40 @@ +diff -crN '--exclude=.git' '--exclude=.gitee' openGauss-server-2.1.0/src/bin/pg_basebackup/pg_basebackup.cpp openGauss-server-2.1.0-edit/src/bin/pg_basebackup/pg_basebackup.cpp +*** openGauss-server-2.1.0/src/bin/pg_basebackup/pg_basebackup.cpp 2021-12-13 16:23:09.000000000 +0800 +--- openGauss-server-2.1.0-edit/src/bin/pg_basebackup/pg_basebackup.cpp 2023-08-14 10:19:02.650301090 +0800 +*************** +*** 1584,1590 **** + struct dirent* ent; + while (1) { + ent = readdir(dir); +! if (ent <= 0) { + break; + } + if ((strcmp(".", ent->d_name) == 0) || (strcmp("..", ent->d_name) == 0)) { +--- 1584,1590 ---- + struct dirent* ent; + while (1) { + ent = readdir(dir); +! if (ent == NULL) { + break; + } + if ((strcmp(".", ent->d_name) == 0) || (strcmp("..", ent->d_name) == 0)) { +diff -crN '--exclude=.git' '--exclude=.gitee' openGauss-server-2.1.0/src/gausskernel/runtime/opfusion/opfusion_util.cpp openGauss-server-2.1.0-edit/src/gausskernel/runtime/opfusion/opfusion_util.cpp +*** openGauss-server-2.1.0/src/gausskernel/runtime/opfusion/opfusion_util.cpp 2021-12-13 16:23:09.000000000 +0800 +--- openGauss-server-2.1.0-edit/src/gausskernel/runtime/opfusion/opfusion_util.cpp 2023-08-14 10:18:07.476105895 +0800 +*************** +*** 405,411 **** + + /* check whether to have order by */ + if (node->aggstrategy != AGG_PLAIN || +! node->groupingSets > 0) { + return NOBYPASS_NOT_PLAIN_AGG; + } + +--- 405,411 ---- + + /* check whether to have order by */ + if (node->aggstrategy != AGG_PLAIN || +! node->groupingSets != NIL) { + return NOBYPASS_NOT_PLAIN_AGG; + } + diff --git a/opengauss-server.spec b/opengauss-server.spec index 0963ef7..a9834e8 100755 --- a/opengauss-server.spec +++ b/opengauss-server.spec @@ -12,7 +12,7 @@ Name: opengauss Version: 2.1.0 -Release: 4 +Release: 5 Summary: openGauss is an open source relational database management system License: MulanPSL-2.0 and MIT and BSD and zlib and TCL and Apache-2.0 and BSL-1.0 URL: https://gitee.com/opengauss/openGauss-server @@ -33,6 +33,7 @@ Patch22: 0003-zlib.patch Patch23: makefile-miniunz.patch Patch40: 0001-orc.patch Patch50: openssl3-adptor.patch +Patch51: compile_2309.patch BuildRequires: cmake gcc gcc-c++ openssl-devel python BuildRequires: cjson lz4-devel protobuf-devel snappy-devel zstd-devel boost-devel @@ -70,6 +71,7 @@ openGauss kernel : openGauss is an open source relational database management sy pushd openGauss-server-%{version} %patch0 -p1 %patch50 -p1 +%patch51 -p1 popd pushd %{cjson_name}-%{cjson_version} @@ -290,6 +292,9 @@ fi %changelog +* Mon Aug 14 2023 zhangxubo - 2.1.0-5 +- Fix bugs: #I7QJRO + * Sat Feb 11 2023 zhangxubo - 2.1.0-4 - Fix bugs: #I6ED94 -- Gitee