Initial install-time test for PCRE compiled without Unicode properties, which causes corruption in feeds and other linking problems.

Error message links to help info at http://status.net/wiki/Red_Hat_Enterprise_Linux#PCRE_library
This commit is contained in:
Brion Vibber 2010-03-05 11:27:48 -08:00
parent 248aed7cf4
commit 54de8ad9f2
1 changed files with 13 additions and 0 deletions

View File

@ -301,6 +301,19 @@ function checkPrereqs()
$pass = false;
}
// Look for known library bugs
$str = "abcdefghijklmnopqrstuvwxyz";
$replaced = preg_replace('/[\p{Cc}\p{Cs}]/u', '*', $str);
if ($str != $replaced) {
printf('<p class="error">PHP is linked to a version of the PCRE library ' .
'that does not support Unicode properties. ' .
'If you are running Red Hat Enterprise Linux / ' .
'CentOS 5.3 or earlier, see <a href="' .
'http://status.net/wiki/Red_Hat_Enterprise_Linux#PCRE_library' .
'">our documentation page</a> on fixing this.</p>');
$pass = false;
}
$reqs = array('gd', 'curl',
'xmlwriter', 'mbstring', 'xml', 'dom', 'simplexml');