Add lib-ICU platform package
parent
5b1f3145c2
commit
f69418427f
|
@ -70,6 +70,7 @@ class PlatformRepository extends ArrayRepository
|
||||||
// Doing it this way to know that functions or constants exist before
|
// Doing it this way to know that functions or constants exist before
|
||||||
// relying on them.
|
// relying on them.
|
||||||
foreach ($loadedExtensions as $name) {
|
foreach ($loadedExtensions as $name) {
|
||||||
|
$prettyVersion = null;
|
||||||
switch ($name) {
|
switch ($name) {
|
||||||
case 'curl':
|
case 'curl':
|
||||||
$curlVersion = curl_version();
|
$curlVersion = curl_version();
|
||||||
|
@ -80,6 +81,23 @@ class PlatformRepository extends ArrayRepository
|
||||||
$prettyVersion = ICONV_VERSION;
|
$prettyVersion = ICONV_VERSION;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case 'intl':
|
||||||
|
$name = 'ICU';
|
||||||
|
if (defined('INTL_ICU_VERSION')) {
|
||||||
|
$prettyVersion = INTL_ICU_VERSION;
|
||||||
|
} else {
|
||||||
|
$reflector = new \ReflectionExtension('intl');
|
||||||
|
|
||||||
|
ob_start();
|
||||||
|
$reflector->info();
|
||||||
|
$output = ob_get_clean();
|
||||||
|
|
||||||
|
preg_match('/^ICU version => (.*)$/m', $output, $matches);
|
||||||
|
$prettyVersion = $matches[1];
|
||||||
|
}
|
||||||
|
|
||||||
|
break;
|
||||||
|
|
||||||
case 'libxml':
|
case 'libxml':
|
||||||
$prettyVersion = LIBXML_DOTTED_VERSION;
|
$prettyVersion = LIBXML_DOTTED_VERSION;
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue