Re: External Packages x PEAR
| From: | Tomas V.V.Cox | Date: | Wed, 30 Jun 2004 10:53:54 +0000 |
| Subject: | Re: External Packages x PEAR | ||
| References: | 1 2 3 4 | Groups: | php.pear.qa |
| Request: | Send a blank email to pear-qa+get-1549@lists.php.net to get a copy of this message | ||
Adam Gołębiowski wrote:
On Tue, Jun 29, 2004 at 08:50:03PM +0200, Tomas V.V.Cox wrote: We also have a set of two rather simple scripts for generating dependencies based on package.xml file. Uhm, actually these scripts are finished, and they work when run from command line, but when called while building package they are terminated with some strange error... still to be figured out.I remember long time ago a guy (maybe from PLD) doing that by "grepping" the XML in a bash script. In case you're interested on how to do that natively, a quick example: $ php -r 'include "PEAR/Common.php"; $c=new PEAR_Common; $i=$c->infoFromAny("./package.xml"); print_r($i["deps"]);' (The deps generation for "makerpm" is still missing, yes)
"pear makerpm" does generate a .spec file, you can mutate for your distrib. If you want even low level access, in cvs: pear-core/template.spec, you have the source file we use for generating the rpm.Thanks, was always curious about that.If anyone wants to have a look, our specs are available and http://cvs.pld-linux.org/SPECS/template-php-pear.spec and http://cvs.pld-linux.org/SPECS/template-php-pecl.spec. I am also curious of what you think of such way of distributing PEAR packages. And for the question - why not pear makerpm. Hmm... well, how could we control it? It wouldn't fit to our infrastructure - that's for sure.
Second, what would be the benefit?It's relative dangerous to install PEAR packages without the pear installer. Mostly for: 1) PEAR packages do replacements in files 2) The user may want to install the packages shipped with PLD, but upgrade or install newer ones with the "pear installer". If you don't register it's deps, would hardly work. 3) In general using the pear installer will make your life more easy in the future. I'd be glad to hear suggestions and improvements for the RPM generation, was coded mostly for helping Linux distributions, and anyone (AFAIK) is using it, spending a lot of efforts on home-made package converters with IMHO not very high quality results. Tomas V.V.Cox