PHP5.2 for lucid ppa

Drupal and a lot of community modules do not work yet 100% with PHP 5.3. Therefore, in order to make it easier for any drupal administrators who wish to run the ubuntu lucid server, I have created a ppa that allows easy use of php5.2 packages that have been compiled under lucid: https://edge.launchpad.net/~txwikinger/+archive/php5.2

Rules for pinning this version are provided in the description of the ppa.

0
Your rating: None

Comments

php5-gd and image manipulation in drupal

Hi,
Thanks very much for this back-port. It's v useful to have php 5.2 under Ubuntu 10. I have one issue which is slowing down my site. The GD libraries are problamatic in Ubuntu. To quote from this page [ http://groups.drupal.org/node/35764 ] :
The problem is that Debian/Ubuntu does not use anywhere near the latest GD libraries. Im not 100% certain but I think these builds are all running ubuntu. Installing php5-gd with apt-get is really not going to do anything for you as they debian/ubuntu built it with an outdated gd library instead of the one bundled with the modern php, which has superior performance and many added features.

The above page recommends re-compiling php with a newer GD lib (not the standard Ubuntu lib) or to use Imagick module. However there is no imagick with these backports. Any chance of an updated php5-gd deb with the newer libs?

Many Thanks

Ben

GD libraries

The problem is not that Ubuntu is using old GD libraries, but that php has forked the libraries in a way that makes it impossible for Debian and Ubuntu to include it.

I do not want to rehash all the arguments in both directions that have been made.

As far as I understand this issue will be obsolete with Drupal 7, I am not sure if there will be a viable solution before that.

Can you elaborate a little bit more?

Like many I'm stuck in a bit of a hard place as I really want to run Ubuntu 10.04LTS and Drupal. While the current version of Drupal 6 and the upcoming Drupal 7 support PHP 5.3 and all this GD business is taken care of, I'm stuck in php 5.2 because there are many drupal modules that have not been updated yet. (BTW, your PHP 5.2 repository is a fantastic resource. Thanks!) I'm probably picking the wrong search terms (ubuntu php GD fork), but Google gives me 34,600 different ways to recompile PHP with GD but I've not found a discussion of why it is impossible for Debian or Ubuntu to use the PHP GD libs.

Could you provide a short explanation of what the issue is with the fork, and/or point me in the direction of where I might find this info? I'm curious as to the reasons for the incompatibility. Is it a licence issue or or a technical issue?

Thank you again for your time and your php repository.

GD incompatibility in debian/ubuntu

It is not a matter of licence or even an impossibility to compile php5.2 on Debian or Ubuntu systems with the necessary fork.

It was always rather a matter of maintenance an incompatibility to other projects. IIRC it was decided, that it was the wrong approach and an introduction of an insecurity, to use the php fork, rather than have the appropriate fixes been done upstream by the GD library maintainers.

Theoretically, you could download the php5.2 sources from the Ubuntu archive and apply the fork on it, and then build the package.

However, php is a very complex package and not easy to handle. I rather live with the limitations at the moment and wait for drupal7 working with php5.3.

Hello. I just wanted to thank

Hello.

I just wanted to thank you for this repository, i've been searching for a better way to install php52 into lucid and keep the system clean since it was released.

problems with php5-mcrypt and php5-imap

Thank you for providing this.
I'm having 2 problems though:


apt-get install php5-imap
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package php5-imap is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package php5-imap has no installation candidate


apt-get install phpmyadmin
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
phpmyadmin: Depends: php5-mcrypt but it is not going to be installed
E: Broken packages


apt-get install php5-mcrypt
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
php5-mcrypt: Depends: phpapi-20090626
E: Broken packages

both php5-imap and php5-mrypt are pinned according to desctiption on the ppa

It works now

The installations of php5-mcrypt and php5-imap work now. However, extra care must be taken for the correct pinning. The pinning version is '5.2.6*' !

mcrypt / imap will not load

From command line, I can apt-get install php5-imap and php5-mcrypt. They are pinned correctly, and they download the correct 5.2.6* and build the .so's in /usr/lib/php5/20090626+lfs (all the other libs are in /usr/lib/php5/20060613+lfs). I have .ini files for mcrypt and imap in /etc/php5/conf.d (which just have, ex.g. "extension=mcrypt.so" in them).

My extension_dir, according to phpinfo(), is /usr/lib/php5.

I have restarted Apache (numerous times).

Alas, mcrypt and imap refuse to load! What gives?

wrong mcrypt and imap package installed

The wrong mcrypt and imap packages are installed. 20090626 is the api for 5.3.2, the correct api for 5.2 in the ppa is 20090613.

Either the pinning is correct, or a false package was already installed. The pinning as given on the ppa description does not downgrade, so maybe removing the packages and re-installing them with the right pinning helps.

Use apt-get policy to check what is really installed.

Same problem here

Hi, I'm having the same problem exactly (tho I'm not using IMAP). I'm far from a Linux guru, so may have missed something. As with Chris W. I have the appropriate pinnings, and on installatoin it says

Unpacking php5-mcrypt (from .../php5-mcrypt_5.2.6-0ubuntu6_i386.deb) ...

The .so appears in the same directory as for Chris W. however. I've done apt-get purge php5-mcrypt and then tried to install again - no luck. I do have an ini file with extension = mcrypt.so

I'm stuck: any ideas?

Thanks for your time,

Andy

Update on phpapi dependency problem

I have done a little more research about the phpapi dependency problem. In fact the phpapi package is a virtual package that does not exist, but basically points to a group of packages that each by themselves resolve the dependency.

Since these packages are available in my ppa, I am looking for a way to figure out how to solve this problem. Please stay tuned.