2019-09-05, 01:02 PM
If you don't have access to a RHEL license, then you can get RHEL 8 through Fedora 28 or newer. There's no stable build of CentOS 8 right now, but that might change in the near future.
Okay let's get started with the necessary packages needed to build a MyBB-friendly copy of PHP 8:
Now that we have our required libraries and the git program, we can clone ourselves a copy of the PHP sources:
From there we want to enter the php source folder and create a new shell script named "phpconf.sh" with the following contents:
Now we need to run the following commands:
If everything went well, you should be greeted with a "thank you" screen from the Zend team. Now you can start the build process.
And voila, you should be running a thread-safe x86_64 variant of PHP 8.0.0-dev:
To verify that the modules you enabled in the build configuration are functioning:
This should be the expected output:
Okay let's get started with the necessary packages needed to build a MyBB-friendly copy of PHP 8:
sudo yum -y install \
bison \
re2c \
systemd-devel \
libacl-devel \
libxml2-devel \
openssl-devel \
sqlite-devel \
bzip2-devel \
libcurl-devel \
libpng-devel \
libicu-devel \
oniguruma-devel \
libpq-devel \
libsodium-devel \
libargon2-devel \
libtidy-devel \
git
Now that we have our required libraries and the git program, we can clone ourselves a copy of the PHP sources:
git clone https://github.com/php/php-src.git
From there we want to enter the php source folder and create a new shell script named "phpconf.sh" with the following contents:
#!/bin/bash
./configure \
--enable-fpm \
--with-fpm-systemd \
--with-fpm-acl \
--enable-fd-setsize=2048 \
--with-openssl \
--with-zlib \
--enable-bcmath \
--with-bz2 \
--with-curl \
--enable-exif \
--enable-gd \
--enable-intl \
--enable-mbstring \
--with-mysqli \
--with-pdo-mysql \
--with-pdo-pgsql \
--enable-soap \
--with-sodium \
--with-password-argon2 \
--with-tidy \
--with-xmlrpc \
--enable-zts \
--enable-shared
Now we need to run the following commands:
sudo chmod +x phpconf.sh
./buildconf
./phpconf.sh
If everything went well, you should be greeted with a "thank you" screen from the Zend team. Now you can start the build process.
sudo make
sudo make install
And voila, you should be running a thread-safe x86_64 variant of PHP 8.0.0-dev:
To verify that the modules you enabled in the build configuration are functioning:
php -r "echo '<pre>'; print_r(get_loaded_extensions()); echo '</pre>';"
This should be the expected output: