From 0f1767b3f006b351243e72d10613866af6089148 Mon Sep 17 00:00:00 2001 From: levlam Date: Thu, 18 Jul 2024 17:12:56 +0300 Subject: [PATCH] Use dnf as package manager on CentOS 8+. --- build.html | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/build.html b/build.html index 619e6ff73..2e1417acf 100644 --- a/build.html +++ b/build.html @@ -848,23 +848,25 @@ function onOptionsChanged() { commands.push(sudo + 'apk add ' + packages); break; case 'CentOS 7': - case 'CentOS 8': commands.push(sudo + 'yum update -y'); - var packages = 'gcc-c++ make git zlib-devel openssl-devel php'; - if (linux_distro === 'CentOS 7') { - commands.push(sudo + 'yum install -y centos-release-scl-rh epel-release'); - commands.push(sudo + 'yum install -y devtoolset-9-gcc devtoolset-9-gcc-c++'); - cmake = 'cmake3'; - packages += ' gperf'; - } else { - commands.push(sudo + 'dnf --enablerepo=powertools install gperf'); - } - packages += ' ' + cmake; + commands.push(sudo + 'yum install -y centos-release-scl-rh epel-release'); + commands.push(sudo + 'yum install -y devtoolset-9-gcc devtoolset-9-gcc-c++'); + var packages = 'gcc-c++ make git zlib-devel openssl-devel php gperf cmake3'; if (target === 'JNI') { packages += ' java-11-openjdk-devel'; } + cmake = 'cmake3'; commands.push(sudo + 'yum install -y ' + packages); break; + case 'CentOS 8': + commands.push(sudo + 'dnf update -y'); + commands.push(sudo + 'dnf --enablerepo=powertools install gperf'); + var packages = 'gcc-c++ make git zlib-devel openssl-devel php cmake'; + if (target === 'JNI') { + packages += ' java-11-openjdk-devel'; + } + commands.push(sudo + 'dnf install -y ' + packages); + break; case 'Debian 8': case 'Debian 9': case 'Debian 10+':