From 2aaa4e94e3ebe24d7dac6c526208b8f180ef73b7 Mon Sep 17 00:00:00 2001 From: Kazuhito Suda Date: Mon, 11 Sep 2023 21:22:39 +0900 Subject: [PATCH] ADD Alpine 3.16.x as distribution with old SSL version --- CMakeLists.txt | 2 +- scripts/build/osDistro.sh | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index b260ad8faa..42a046ec8d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -173,7 +173,7 @@ endif (${CMAKE_BUILD_TYPE} STREQUAL DEBUG) # Enables some some #ifdef in the code for compiling in old system # FIXME: cleanup OLD_SSL_VERSION_FORMAT stuff after consolidating the change to Debian 12+ -IF(${DISTRO} MATCHES "Debian_11.*") +IF((${DISTRO} MATCHES "Debian_11.*") OR (${DISTRO} MATCHES "Alpine_3.16.*")) ADD_DEFINITIONS(-DOLD_SSL_VERSION_FORMAT) ENDIF() diff --git a/scripts/build/osDistro.sh b/scripts/build/osDistro.sh index 7a02c2c33d..ce7fcc9140 100755 --- a/scripts/build/osDistro.sh +++ b/scripts/build/osDistro.sh @@ -26,6 +26,8 @@ suse_distro=$(cat /etc/SuSE-release 2> /dev/null | grep SUSE | cut -d ' ' -f 1-2 centos_distro=$(cat /etc/redhat-release 2> /dev/null | awk '{print $3}') +alpine_distro=$(cat /etc/alpine-release 2> /dev/null) + # In some cases (e.g. CentOS 7.x) we have found that the /etc/redhat-release content uses the following pattern: # # CentOS Linux release 7.2.1511 (Core) @@ -69,6 +71,9 @@ then elif [ "$centos_distro" != "" ] then distro=CentOS_$centos_distro +elif [ "$alpine_distro" != "" ] +then + distro=Alpine_$alpine_distro fi echo -n $distro