Author Topic: PHP8.2.* Install?  (Read 1987 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
PHP8.2.* Install?
« on: December 09, 2022, 05:38:45 PM »
Hello,

Since we are still quite new and have only been working with CWP for a few weeks, I wanted to ask what you have to do to make PHP versions also show PHP8.2.*?

Do you have to wait for an update from CWP or can you add it yourself? Since we have a large statistics tool, which should work best with php8.2.*!

Thanks for the brief information!

Offline
****
Re: PHP8.2.* Install?
« Reply #1 on: December 12, 2022, 04:04:15 PM »
I thought PHP 8.2 was still in the RC stage.

Just looked and it is released.

Let me do some testing, and I'll get back with you.

(BTW I do not work for CWP)

Offline
****
Re: PHP8.2.* Install?
« Reply #2 on: December 12, 2022, 06:33:14 PM »
Based On and Credit To:
Sandeep B. - November 26, 2021
https://www.uxlinux.com/install-php-8-1-latest-version-in-cwp-control-panel/

--

NOTE: ionCube 12.0.x does NOT support PHP 8.2.x as of 12 December 2022.

Below was tested on AlmaLinux 8.7 & CWP 0.9.8.1148

Start with PHP 8.1.13
Compiled in CWP WITHOUT: imagick, ioncube, sodium

--

dnf install oniguruma oniguruma-devel gcc make gcc-c++ cpp kernel-headers.x86_64 libxml2-devel openssl-devel bzip2-devel libjpeg-devel libpng-devel freetype-devel openldap-devel postgresql-devel aspell-devel net-snmp-devel libxslt-devel libc-client-devel libicu-devel gmp-devel curl-devel libmcrypt-devel pcre-devel sqlite-devel libdb-devel enchant-devel libXpm-devel mysql-devel readline-devel libedit-devel recode-devel libtidy-devel libtool-ltdl-devel libwebp libwebp-devel expat expat-devel libmemcached libmemcached-devel

--

dnf install libzip libzip-devel
dnf install cmake zlib-devel

--

cd /usr/local/src
rm -rf libzip*
wget https://libzip.org/download/libzip-1.9.2.tar.gz
tar zxvf libzip*
cd libzip*/
mkdir build
cd build
/usr/bin/cmake3 ..
make && make install

--

cd /usr/local/src
rm -rf pcre2*
wget https://github.com/PhilipHazel/pcre2/releases/download/pcre2-10.41/pcre2-10.41.zip -O pcre2.zip
unzip pcre2.zip
cd pcre2-*/
./configure
make && make install

--

cd /usr/local/src
rm -rf master* libavif-master*
wget https://github.com/AOMediaCodec/libavif/archive/refs/heads/master.zip
unzip master.zip
cd libavif-main
mkdir build-dir
cd build-dir
cmake ..
make
make install

--

export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:/usr/local/lib64/pkgconfig

--

mkdir -p /usr/local/php-82
cd /usr/local/php-82
wget http://php.net/distributions/php-8.2.0.tar.gz
tar zxvf php-8.2.0.tar.gz
cd php-8.2.0
./configure --with-config-file-path=/usr/local/php --enable-cgi --with-config-file-scan-dir=/usr/local/php/php.d --with-zlib=/usr --enable-mbstring --with-zip --enable-bcmath --enable-pcntl --enable-ftp --enable-exif --enable-calendar --enable-sysvmsg --enable-sysvsem --enable-sysvshm --with-tidy --with-curl --with-iconv --with-gmp --with-pspell --enable-gd --with-avif --with-jpeg --with-freetype --enable-gd-jis-conv --with-webp --with-zlib-dir=/usr --with-xpm --with-openssl --with-pdo-mysql=mysqlnd --with-gettext=/usr --with-bz2=/usr --with-mysqli --enable-soap --enable-phar --with-xsl --with-kerberos --enable-posix --enable-sockets --with-external-pcre --with-libdir=lib64 --with-mysql-sock=/var/lib/mysql/mysql.sock --enable-intl --with-password-argon2 --enable-litespeed --with-ldap=/usr --with-ldap-sasl=/usr 
make
make install

--

php -v

You should see (if all went well):

PHP 8.2.0 (cli) (built: Dec 12 2022 17:57:50) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.2.0, Copyright (c) Zend Technologies

Offline
****
Re: PHP8.2.* Install?
« Reply #3 on: December 12, 2022, 06:34:23 PM »
In CWP you should see:


Offline
*
Re: PHP8.2.* Install?
« Reply #4 on: December 12, 2022, 09:35:52 PM »
Thank you! Will it be submitted by an update from CWP directly to the PHP 8.2 ? Because I didn't want to work on the console now, or is that unfortunately absolutely necessary? I mean, I don't really need it yet, but with the next updates of our scripts it will be imperative, but I wanted to inform myself first!

Offline
****
Re: PHP8.2.* Install?
« Reply #5 on: December 12, 2022, 10:15:37 PM »
Don't know when/if CWP will add 8.2 in the next update, as I mentioned I don't work for them.

I know I was able to go back to 8.1 without problems, and the 8.1 version of this worked with CWP when they finally did add support.

The only way to get 8.2.0 now, would be thru cli via ssh or local.