Re: XML_RPC
| From: | Greg Beaver | Date: | Mon, 06 Dec 2004 16:25:14 +0000 |
| Subject: | Re: XML_RPC | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-34838@lists.php.net to get a copy of this message | ||
techtonik wrote:
This would mean the code would have to first write out a temporary file using PHP like so "%PHP_PEAR_PHP_BIN%" -v > ~~~testver.inf echo "<?php preg_match('/PHP (\d.\d)/',implode('',file('~~~testver.inf')),$m);if(count($m)){if(version_compare($m[1], '4.2', >)return 1;else return 0;}" > ~tv.php IF "%PHP_PEAR_PHP_BIN%" ~tv.php ( SET %PHP_PEAR_ARGC%="register_argc_argv=On" ) ELSE ( SET %PHP_PEAR_ARGC%= ) As you can see, this will be a major headache to debug, and since the better solution is to upgrade PHP (not always possible, I know), and my time is finite, I would ask that you take the above code, test it, and tweak it until it works, then send me the results for inclusion in the next release of PEAR. Thanks, Greg||*()*|| [\..konnichi wa, ogenki desu ka, Greg../]GB> Until PEAR no longer supports PHP 4.2, it will not be possible to fix GB> this, as php 4.2 does not like "register_argc_argv=On" Is it possible to calculate PHP version in install procedure? And include something like @PHP_ABOVE_4_2_ARGC_ARGUMENT@ in pear.bat? Yes it is possible, but the installer does not support conditional replacements for package.xml version 1.0 (or 2.0, actually, although this can be more easily changed). It would have to be in native batch file language.With every new Pear::Pear package upgrade I add -d register_argc_argv=On into .bat file manually and even this is something I sometimes forget. I prefer to install new system (or PHP) without bothering about additional required files. It is natural desire to make life easier if it is possible.