From ee129725243454ff6e3283bec7c7c79c51feb8a8 Mon Sep 17 00:00:00 2001 From: jianghongbo4 Date: Sat, 7 Jan 2023 17:38:30 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=AF=E6=8C=81openEuler=202203=20LTS?= =?UTF-8?q?=E7=B3=BB=E7=BB=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- configure | 5 +++++ src/Makefile.global.in | 6 ++++++ src/gausskernel/cbb/bbox/bbox_elf_dump.h | 6 +++--- src/gausskernel/cbb/bbox/bbox_syscall_support.h | 6 +++--- src/gausskernel/cbb/bbox/bbox_threads.h | 4 ++++ .../storage/mot/core/system/statistics/process_statistics.h | 2 ++ src/include/communication/commproxy_interface.h | 2 +- 7 files changed, 24 insertions(+), 7 deletions(-) diff --git a/configure b/configure index 22009e0342..fb65b23cb0 100755 --- a/configure +++ b/configure @@ -709,6 +709,7 @@ with_selinux krb_srvtab with_python with_openeuler_os +with_openeuler_major enable_thread_safety INCLUDES TAS @@ -828,6 +829,7 @@ enable_nls with_pgport with_gs_version with_openeuler_os +with_openeuler_major enable_shared enable_rpath enable_jemalloc @@ -3272,6 +3274,9 @@ _ACEOF fi +if [ "$(cat /etc/system-release)" == "openEuler release 22.03 LTS" ]; then + with_openeuler_major=yes +fi # # --enable-coverage enables generation of code coverage metrics with gcov diff --git a/src/Makefile.global.in b/src/Makefile.global.in index 2db3b14b3f..3437943d6f 100644 --- a/src/Makefile.global.in +++ b/src/Makefile.global.in @@ -211,6 +211,7 @@ TCL_SHLIB_LD_LIBS = @TCL_SHLIB_LD_LIBS@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ PTHREAD_LIBS = @PTHREAD_LIBS@ with_openeuler_os = @with_openeuler_os@ +with_openeuler_major = @with_openeuler_major@ ############################################################################# @@ -728,6 +729,11 @@ endif ifeq ($(with_openeuler_os), yes) override CPPFLAGS := $(CPPFLAGS) -DWITH_OPENEULER_OS endif + +ifeq ($(with_openeuler_major), yes) + override CPPFLAGS := $(CPPFLAGS) -DOPENEULER_MAJOR +endif + CC = @CC@ GCC = @GCC@ C = gcc diff --git a/src/gausskernel/cbb/bbox/bbox_elf_dump.h b/src/gausskernel/cbb/bbox/bbox_elf_dump.h index 21c675e932..acdf5ede45 100644 --- a/src/gausskernel/cbb/bbox/bbox_elf_dump.h +++ b/src/gausskernel/cbb/bbox/bbox_elf_dump.h @@ -31,10 +31,10 @@ #include #include #include -#ifndef WITH_OPENEULER_OS -#include -#else +#if (defined WITH_OPENEULER_OS) || (defined OPENEULER_MAJOR) #include +#else +#include #endif #include #include diff --git a/src/gausskernel/cbb/bbox/bbox_syscall_support.h b/src/gausskernel/cbb/bbox/bbox_syscall_support.h index c131a573df..12adc5728e 100644 --- a/src/gausskernel/cbb/bbox/bbox_syscall_support.h +++ b/src/gausskernel/cbb/bbox/bbox_syscall_support.h @@ -54,10 +54,10 @@ #include #include #include -#ifndef WITH_OPENEULER_OS -#include -#else +#if (defined WITH_OPENEULER_OS) || (defined OPENEULER_MAJOR) #include +#else +#include #endif #include #include diff --git a/src/gausskernel/cbb/bbox/bbox_threads.h b/src/gausskernel/cbb/bbox/bbox_threads.h index bb890047f0..bf91fd3028 100644 --- a/src/gausskernel/cbb/bbox/bbox_threads.h +++ b/src/gausskernel/cbb/bbox/bbox_threads.h @@ -28,6 +28,10 @@ #define PAGE_SIZE 4096 #define BBOX_PROC_PATH_LEN 128 +#ifdef MINSIGSTKSZ +#undef MINSIGSTKSZ +#endif +#define MINSIGSTKSZ 5120 #define BBOX_ALT_STACKSIZE (MINSIGSTKSZ + 4096 * 32) diff --git a/src/gausskernel/storage/mot/core/system/statistics/process_statistics.h b/src/gausskernel/storage/mot/core/system/statistics/process_statistics.h index 55c9fa9a85..21b34de27f 100644 --- a/src/gausskernel/storage/mot/core/system/statistics/process_statistics.h +++ b/src/gausskernel/storage/mot/core/system/statistics/process_statistics.h @@ -30,7 +30,9 @@ #include "typed_statistics_generator.h" #include "sys/times.h" +#ifndef OPENEULER_MAJOR #include "sys/vtimes.h" +#endif namespace MOT { /** diff --git a/src/include/communication/commproxy_interface.h b/src/include/communication/commproxy_interface.h index 5a3aa0484f..67dab2f4a8 100644 --- a/src/include/communication/commproxy_interface.h +++ b/src/include/communication/commproxy_interface.h @@ -164,7 +164,7 @@ extern ErrorLevel min_debug_level; #define MAX_CONTINUOUS_COUNT 10 #define INIT_TX_ALLOC_BUFF_NUM 5 -#ifndef WITH_OPENEULER_OS +#if (!defined WITH_OPENEULER_OS) && (!defined OPENEULER_MAJOR) extern int gettimeofday(struct timeval* tp, struct timezone* tzp); #endif //extern THR_LOCAL knl_thrd_context t_thrd; -- Gitee