# Newest php8.4 on Debian / Ubuntu - build missing modules with \[php-module-builder\]

**URL:** <https://help.nextcloud.com/t/newest-php8-4-on-debian-ubuntu-build-missing-modules-with-php-module-builder/174766>\
**Category:** 📑 How to\
**Tags:** php84, admin-scripts\
**Created:** [January 1, 2024, 11:00pm UTC](https://help.nextcloud.com/t/newest-php8-4-on-debian-ubuntu-build-missing-modules-with-php-module-builder/174766 "2024-01-01T23:00:00Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ernolf](https://help.nextcloud.com/user_avatar/help.nextcloud.com/ernolf/32/77874_2.png) [@ernolf](https://help.nextcloud.com/u/ernolf)\
**Post date:** [January 1, 2024, 11:00pm UTC](https://help.nextcloud.com/t/newest-php8-4-on-debian-ubuntu-build-missing-modules-with-php-module-builder/174766/1 "2024-01-01T23:00:00Z")

</div>

Hello Nextclouders,

This may be of interest to those of you who want to test Nextcloud with the newest PHP 8.4 on Ubuntu or Debian.  
You can easily set this up with these two scripts:

1. 
## php-updater

* * *

You’ll probably do your php updates already with the _`php-updater`_ script with builtin _`php.net`_-defaults and -changelog of the most php-ini directives and a verbose explanation. Install it with:

```sh
sudo wget -qO /usr/local/bin/php-updater https://global-social.net/script/php-updater
sudo chmod +x /usr/local/bin/php-updater

```

**Explanation:**  
- the first line downloads the script into the directory _`/usr/local/bin`_  
- the second line makes it executable

You only need to install it once.  
As [all of my → ebtb ← scripts](https://github.com/ernolf/ebtb), it comes signed and does an integrity check on the first run and checks for updates on every startup.

Once installed, simply run it:

```sh
php-updater

```

.. and choose to install the version php8.4. Abort the script at the point where the settings from your old php version (probably 8.2 or 8.3) are to be integrated into the new php8.4, because not all modules are installed yet at that point.

1. 
## php-module-builder

* * *

At the moment I’m writing this, PHP 8.4 is still in RC status, so in its early stages, and a lot of PHP modules are still not delivered, including some that are absolutely necessary to operate Nextcloud.

As after the release of php8.3, most modules will be delivered by the maintainer as package versions over time. Nevertheless, some modules will not be packaged and can be built with this script though, even if builds do not succeed with pecl.

The **`php-module-builder`** script makes it easy to build and install all essential modules that are not (yet) available as Debian packages. The modules installed with this tool can also be removed just as easily. So the entire administration for the self-built modules is handled by one script. There is no need to make any changes to the _`php.ini`_ ; the modules are all integrated into PHP by the script with Debian-style symlinks and locations, along with their own little ini files.

It has an automatic patching function that scans the source code before building the modules and updates old deprecated functions and include-pathes to comply with the new version for php8.4. This means that you can already use modules not yet officially released for php8.4 yet.

Installation of the script:

```sh
sudo wget -qO /usr/local/bin/php-module-builder https://global-social.net/script/php-module-builder
sudo chmod +x /usr/local/bin/php-module-builder

```

**Explanation:**  
- the first line downloads the script into the directory _`/usr/local/bin`_  
- the second line makes it executable

once installed, simply run:

```sh
php-module-builder

```

After you have installed the missing modules for php8.4 like apcu, igbinary, imagick, lua and redis, you can run the migrationstep with

```sh
php-updater 8.3 8.4

```

(asuming php8.3 as your “old” php version)

As long as there is no official Nextcloud support for php8.4, this is probably more of a developer thing.  
You can easily switch back and forth between the different installed php versions with

```sh
php-updater --switch-version

```

* * *

## This table lists which modules are involved:

###### _(last updated@15.10.2024)_

| | | | | | | |
| --- | --- | --- | --- | --- | --- | --- |
| Module | 8.0 | 8.1 | 8.2 | 8.3 | 8.4 | _php-module-builder_ |
| | | | | | | |
| amqp | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| apcu | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| ast | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| bcmath | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| brotli | 🔴 | 🔴 | 🔴 | 🔴 | 🔴 | ✅ |
| bz2 | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| cgi | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| cli | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| common | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| curl | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| dba | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| decimal | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |
| dev | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| dio | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | |
| ds | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| enchant | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| excimer | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| facedetect | 🟢 | 🟢 | 🔴 | 🔴 | 🔴 | ✅ |
| fpm | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| gd | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| gearman | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| gmagick | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| gmp | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| gnupg | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| grpc | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | |
| http | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| igbinary | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| imagick | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| imap | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| inotify | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |
| interbase | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| intl | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| ldap | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| libvirt-php | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| lua | 🔴 | 🔴 | 🔴 | 🔴 | 🔴 | ✅ |
| lz4 | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |
| mailparse | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| maxminddb | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| mbstring | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| mcrypt | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| memcache | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| memcached | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| mongodb | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| msgpack | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| mysql | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| oauth | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| odbc | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| opcache | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| pcov | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| pgsql | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| phalcon5 | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | |
| phpdbg | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| pinba | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | |
| pq | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| propro | 🟢 | 🟢 | 🟢 | 🔴 | 🔴 | |
| protobuf | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | |
| ps | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| pspell | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| psr | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| raphf | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| rdkafka | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | |
| readline | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| redis | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| rrd | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| smbclient | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |
| snmp | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| soap | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| solr | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |
| sqlite3 | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| ssh2 | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| stomp | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| swoole | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |
| sybase | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| tideways | 🟢 | 🟢 | 🟢 | 🔴 | 🔴 | ✅ |
| tidy | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| uopz | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| uploadprogress | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| uuid | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| vips | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |
| xdebug | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| xhprof | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |
| xml | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| xmlrpc | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| xsl | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| yac | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| yaml | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | ✅ |
| zip | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| zmq | 🟢 | 🟢 | 🟢 | 🟢 | 🟢 | |
| zstd | 🟢 | 🟢 | 🟢 | 🟢 | 🔴 | ✅ |

* * *

## lua module for File Actions app:

This tool is helpful if you want to make use of the [File Actions-_`files_scripts`_](https://github.com/Raudius/files_scripts#recommended) app, which relies on the Lua module that always has to be built.

Example call, to create **php8.3-lua** module:

```sh
php-module-builder 8.3 lua

```

* * *

It can only build one module per call. So if you need three modules, you will have to run it three times, one for every single module.

* * *

Happy hacking!  
Much and good luck,  
ernolf

---

<div class="post-metadata">

**Author:** ![devnoname120](https://help.nextcloud.com/user_avatar/help.nextcloud.com/devnoname120/32/54904_2.png) [@devnoname120](https://help.nextcloud.com/u/devnoname120)\
**Post date:** [May 13, 2024, 12:12pm UTC](https://help.nextcloud.com/t/newest-php8-4-on-debian-ubuntu-build-missing-modules-with-php-module-builder/174766/2 "2024-05-13T12:12:10Z")

</div>

This is really great! Thank you a lot.

I would suggest you to integrate it into [nextcloud/all-in-one](https://github.com/nextcloud/all-in-one) as it would be helpful for a lot of people. 🙂

---

<div class="post-metadata">

**Author:** ![ernolf](https://help.nextcloud.com/user_avatar/help.nextcloud.com/ernolf/32/77874_2.png) [@ernolf](https://help.nextcloud.com/u/ernolf)\
**Post date:** [May 13, 2024, 3:11pm UTC](https://help.nextcloud.com/t/newest-php8-4-on-debian-ubuntu-build-missing-modules-with-php-module-builder/174766/3 "2024-05-13T15:11:48Z")

</div>

Hi @devnoname120

thank you for your kind feedback. ❤

> [@devnoname120](#):
>
> I would suggest you to integrate it into nextcloud/all-in-one

That’s not gonna happen because this script is intended for php on barremetal and AIO is a containerized solution where the PHP modules have to be built by the creator of the container. There is no such freedom there.

* * *

Much and good luck,  
ernolf

---

<div class="post-metadata">

**Author:** ![ernolf](https://help.nextcloud.com/user_avatar/help.nextcloud.com/ernolf/32/77874_2.png) [@ernolf](https://help.nextcloud.com/u/ernolf)\
**Post date:** [October 2, 2024, 12:08am UTC](https://help.nextcloud.com/t/newest-php8-4-on-debian-ubuntu-build-missing-modules-with-php-module-builder/174766/5 "2024-10-02T00:08:30Z")

</div>

FYI:  
Just updated all php admin scripts to handle php8.4

* * *

ernolf

---

<div class="post-metadata">

**Author:** ![ernolf](https://help.nextcloud.com/user_avatar/help.nextcloud.com/ernolf/32/77874_2.png) [@ernolf](https://help.nextcloud.com/u/ernolf)\
**Post date:** [October 15, 2024, 12:41pm UTC](https://help.nextcloud.com/t/newest-php8-4-on-debian-ubuntu-build-missing-modules-with-php-module-builder/174766/6 "2024-10-15T12:41:35Z")

</div>


