Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I have a wiki set up on my local development environment. The wiki runs on Mediawiki 1.5.8, but I'm trying to upgrade it to run on Mediawiki 1.19.

When I run the update.php script I get the following error message:

Your system has a combination of PHP and libxml2 versions which is buggy
and can cause hidden data corruption in MediaWiki and other web apps.
Upgrade to PHP 5.2.9 or later and libxml2 2.7.3 or later! 
ABORTING (see http://bugs.php.net/bug.php?id=45996).

Running php -v gives a PHP version number of 5.2.9, and since this is the PHP install that is running the update.php script I'm guessing this isn't the problem.

I've got libxml2 insalled via MacPorts, and according to MacPorts version 2.7.8 is installed, which should be sufficiently up-to-date to get Mediawiki updating properly.

Any ideas as to how I can go about resolving this?

share|improve this question
add comment

1 Answer

Looking at the source code it's checking the PHP version, but for libxml2 it actually runs some code to see if the bug is there. https://gerrit.wikimedia.org/r/gitweb?p=mediawiki/core.git;a=blob;f=includes/installer/PhpBugTests.php

It looks like even the version you have has the bug, and you have the latest libxml2 so I'd edit the code in that function so that it doesn't check for that bug.

If you look at the end of that bug report someone found it in a supposedly valid combination of PHP and libxml2.

(Open source: cons - component version clashes, pros - open source.)

share|improve this answer
    
I would not disable the check. It's there for a reason, and as you note, it's actually testing to see if the bug occurs. That is to say, the fact that the check fails means that your PHP/libxml combination is buggy and will corrupt data under some circumstances. –  Ilmari Karonen May 15 '12 at 23:25
    
According to phpinfo(), the version of libxml2 that my PHP installation can see is version 2.7.2, so the error message is correct. –  Jim May 17 '12 at 18:19
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.