PHP 5.4.0 – Try this at home

You might have noticed that we still do not have the latest version of PHP in our repositories. Unfortunately there are still several issues which prevents me from updating to 5.4.0 right away.

Concerning the php package itself the updated version of the Suhosin patch is not available yet.

In addition to this, several modules do not work with the new PHP yet. Among them is of course the suhosin extension but also APC and xdebug. The state of other extensions still needs to be researched; if you are lucky simply recompiling will do it.

While I obviously cannot recommend the use of PHP 5.4.0 on any server or production system yet, I would consider it a good idea to start testing your setup and scripts for compatibility. Also at Arch we like to play with the newest features and get hit by bugs nobody has seen before.

Therefore I set up a repository for all administrators and developers who like their packages broken. These come without suhosin (patch nor extension) and are available for both i686 and x86_64. I also packaged some modules like memcache(d), apc and geoip. Note that I will base these builds upon the [testing] repository. This might not be a problem right now, but once you see a our stock version of PHP in [testing] these package wont work without the usage of [testing] as well.

To use this repo put the following lines on top of all other repositories (including [testing]) in pacman.conf:

[php]
Server = https://repo.pierre-schmitz.com/$repo/os/$arch

For those who are all over the brand new signing stuff: Yes, all these packages are signed using my Arch packager key.

Before you get started have a brief look at the changelog and migration guide which are provided upstream. Then make sure you get all changes in php.ini merged. The easiest was to do so is probably starting with the packaged one and adjust the changes you need. For testing properly it is important to enable error reporting:

error_reporting = E_ALL
display_errors = On
display_startup_errors = On

Note that E_ALL now also includes E_STRICT by default. If you are testing third party code make sure it does not override these settings by either .htaccess or calling error_reporting(). If you find any error this way: You know the drill, report it to the upstream projects.

If you have any suggestions about the packages or configuration, let me know. Especially drop a line if you found any issues regarding extensions or web apps. It’ll help me a lot to know how many breakage such an update will cause.

10 Replies to “PHP 5.4.0 – Try this at home”

  1. Thanks! Nice to be able to play with this on a test machine before it gets added to the official repos.

  2. Just a little error in repo-address — not “$arc”, but “$arch”.
    And thanks.

  3. APC works just fine on php 5.4. The latest release require small changes (very small) to make it compile first and to fix a segfault when the php process is closed (not that it really affects anything, it’s just polluting logs) and the trunk works straight away.

    As far as suhosin is concerned, they seem to have slowed the development in the last two or three years, I wouldn’t count on prompt updates for major releases anymore. PHP 5.4 also implements a couple of suhosin’s enhancements.

    1. A further notice: xdebug trunk also works fine with PHP 5.4, I’ve been using it for several months. On release candidates and on final release.

    2. Correct, APC got fixed some days ago and that version is already in my repo; just didn’t bother to update the post. :-)

      And no, I am not that happy with suhosin development; mostly as there is no information about the state of development or any schedule.

  4. Thanks for the package! But why did you disable libiconv support? Grts

    1. Regarding iconv there is no change from PHP 5.3. Are you sure you have enabled iconv.so in your php.ini?

Comments are closed.