]> TLD Linux GIT Repositories - packages/php-pear-PEAR.git/blob - ext-check.patch
- release 2
[packages/php-pear-PEAR.git] / ext-check.patch
1 --- PEAR-1.9.4/usr/share/pear/pearcmd.php~      2014-05-14 19:21:49.000000000 +0300
2 +++ PEAR-1.9.4/usr/share/pear/pearcmd.php       2014-05-14 19:21:53.064418441 +0300
3 @@ -45,6 +45,16 @@
4  
5  $pear_package_version = "1.9.4";
6  
7 +// before trying anything deep, ensure base extensions are present
8 +// this avoids debugging problems with bogus error messages, which really are
9 +// caused by missing extension
10 +foreach (array('pcre', 'zlib', 'xml') as $ext) {
11 +       if (!extension_loaded($ext)) {
12 +               error_log("pear requires PHP extension '$ext' for ".PHP_VERSION);
13 +               exit(1);
14 +       }
15 +}
16 +
17  require_once 'PEAR.php';
18  require_once 'PEAR/Frontend.php';
19  require_once 'PEAR/Config.php';