Installing PEAR in 5.1.0RC2-dev

php.internals

Antony Dovgal

20 years ago
Hello all. This is what I got trying to install latest snapshot of 5.1.0-dev with Apache2 on Linux: ------------------ Notice: Error: zlib extension is not enabled - gzinflate() function needed for compressed .phars in /root/php5-200510131630/pear/install-pear.phar on line 393 Warning: main(phar://install-pear.phar/index.php): failed to open stream: "PHP_Archive::stream_open" call failed in /root/php5-200510131630/pear/install-pear.phar on line 633 Fatal error: main(): Failed opening required 'phar://install-pear.phar/index.php' (include_path='.:/usr/local/lib/php') in /root/php5-200510131630/pear/install-pear.phar on line 633 make[1]: *** [install-pear-installer] Error 255 make: *** [install-pear] Error 2 ------------------ The configure line used was: ./configure --with-apxs2=/opt/apache/bin/apxs --enable-debug Am I the only one who see these errors or PEAR indeed doesn't use any error handling?
-- Wbr, Antony Dovgal

Jani Taskinen

20 years ago
On Thu, 13 Oct 2005, Antony Dovgal wrote:
> ------------------ > Notice: Error: zlib extension is not enabled - gzinflate() function needed for > compressed .phars in /root/php5-200510131630/pear/install-pear.phar on line > 393 > > Warning: main(phar://install-pear.phar/index.php): failed to open stream: > "PHP_Archive::stream_open" call failed in > /root/php5-200510131630/pear/install-pear.phar on line 633 > > Fatal error: main(): Failed opening required > 'phar://install-pear.phar/index.php' (include_path='.:/usr/local/lib/php') in > /root/php5-200510131630/pear/install-pear.phar on line 633 > make[1]: *** [install-pear-installer] Error 255 > make: *** [install-pear] Error 2 > ------------------ > > The configure line used was: > ./configure --with-apxs2=/opt/apache/bin/apxs --enable-debug > > Am I the only one who see these errors or PEAR indeed doesn't use any error > handling?
Add --disable-pear to the configure line and the errors go away. --Jani
-- Give me your money at @ <http://pecl.php.net/wishlist.php/sniper> Donating money may make me happier and friendlier for a limited period! Death to all 4 letter abbreviations starting with P!

Antony Dovgal

20 years ago
On 13.10.2005 23:38, Jani Taskinen wrote:
> Add --disable-pear to the configure line and the errors go away.
Cool. We need to document it then =)
-- Wbr, Antony Dovgal

Greg Beaver

20 years ago
Jani Taskinen wrote:
> On Thu, 13 Oct 2005, Antony Dovgal wrote: > >> ------------------ >> Notice: Error: zlib extension is not enabled - gzinflate() function >> needed for compressed .phars in >> /root/php5-200510131630/pear/install-pear.phar on line 393 >> >> Warning: main(phar://install-pear.phar/index.php): failed to open >> stream: "PHP_Archive::stream_open" call failed in >> /root/php5-200510131630/pear/install-pear.phar on line 633 >> >> Fatal error: main(): Failed opening required >> 'phar://install-pear.phar/index.php' >> (include_path='.:/usr/local/lib/php') in >> /root/php5-200510131630/pear/install-pear.phar on line 633 >> make[1]: *** [install-pear-installer] Error 255 >> make: *** [install-pear] Error 2 >> ------------------ >> >> The configure line used was: >> ./configure --with-apxs2=/opt/apache/bin/apxs --enable-debug >> >> Am I the only one who see these errors or PEAR indeed doesn't use any >> error handling? > > > > Add --disable-pear to the configure line and the errors go away.
can we add --disable-smartass to this thread? ;) The design of .phar is an uncompressed archive containined individually compressed files. I just uploaded an uncompressed .phar that can be used. The easiest (and obvious) solution is to simply use it if zlib is not enabled. Otherwise, using the zlib one is the obvious choice because it is 1/6 the size. Greg

Antony Dovgal

20 years ago
After the recent discussion in #php.pecl: Is there any chance to use system's gunzip to unpack the phar as a fallback solution ? Or even better - to download and install not compressed version of the phar ? Or at least use --without-pear when there is no --with-zlib or it's --with-zlib=shared ? Greg? Pierre? Any other ideas? On 13.10.2005 21:54, Antony Dovgal wrote:
> Hello all. > > This is what I got trying to install latest snapshot of 5.1.0-dev with Apache2 on Linux: > > ------------------ > Notice: Error: zlib extension is not enabled - gzinflate() function needed for compressed .phars in /root/php5-200510131630/pear/install-pear.phar on line 393 > > Warning: main(phar://install-pear.phar/index.php): failed to open stream: "PHP_Archive::stream_open" call failed in /root/php5-200510131630/pear/install-pear.phar on line 633 > > Fatal error: main(): Failed opening required 'phar://install-pear.phar/index.php' (include_path='.:/usr/local/lib/php') in /root/php5-200510131630/pear/install-pear.phar on line 633 > make[1]: *** [install-pear-installer] Error 255 > make: *** [install-pear] Error 2 > ------------------ > > The configure line used was: > ./configure --with-apxs2=/opt/apache/bin/apxs --enable-debug > > Am I the only one who see these errors or PEAR indeed doesn't use any error handling? >
-- Wbr, Antony Dovgal

Derick Rethans

20 years ago
On Fri, 14 Oct 2005, Antony Dovgal wrote:
> After the recent discussion in #php.pecl: > > Is there any chance to use system's gunzip to unpack the phar as a fallback > solution ? > Or even better - to download and install not compressed version of the phar ? > Or at least use --without-pear when there is no --with-zlib or it's > --with-zlib=shared ? > > Greg? Pierre? Any other ideas?
I think we can just make it an uncompressed phar, or make two, one compressed and one uncompressed. The uncompressed one we can put into the snapshots and releases, as they will be compressed anyway. Derick
-- Derick Rethans http://derickrethans.nl | http://ez.no | http://xdebug.org

Pierre Joye

20 years ago
On Thu, 13 Oct 2005 23:22:36 +0200 (CEST) derick@php.net (Derick Rethans) wrote:
> On Fri, 14 Oct 2005, Antony Dovgal wrote: > > > After the recent discussion in #php.pecl: > > > > Is there any chance to use system's gunzip to unpack the phar as a > > fallback solution ? > > Or even better - to download and install not compressed version of > > the phar ? Or at least use --without-pear when there is no > > --with-zlib or it's --with-zlib=shared ? > > > > Greg? Pierre? Any other ideas? > > I think we can just make it an uncompressed phar, or make two, one > compressed and one uncompressed. The uncompressed one we can put into > the snapshots and releases, as they will be compressed anyway.
Exact, it was the idea the last time this problem was brought. Another is to add --with-zlib when --with-pear is used. You "need" it somehow. This solution is my favourite. --Pierre

Antony Dovgal

20 years ago
On 14.10.2005 01:30, Pierre wrote:
> On Thu, 13 Oct 2005 23:22:36 +0200 (CEST) > derick@php.net (Derick Rethans) wrote: > >> On Fri, 14 Oct 2005, Antony Dovgal wrote: >> >> > After the recent discussion in #php.pecl: >> > >> > Is there any chance to use system's gunzip to unpack the phar as a >> > fallback solution ? >> > Or even better - to download and install not compressed version of >> > the phar ? Or at least use --without-pear when there is no >> > --with-zlib or it's --with-zlib=shared ? >> > >> > Greg? Pierre? Any other ideas? >> >> I think we can just make it an uncompressed phar, or make two, one >> compressed and one uncompressed. The uncompressed one we can put into >> the snapshots and releases, as they will be compressed anyway. > > Exact, it was the idea the last time this problem was brought. > > Another is to add --with-zlib when --with-pear is used. You "need" it > somehow. This solution is my favourite.
No, silently enabling something doesn't look like a good idea to me. We might disable something because of dependencies, but we enable only something that was requested by user explicitly (except for those modules that are enabled by default). Also, what if someone uses --without-zlib? The installer would fail again?
-- Wbr, Antony Dovgal

Pierre Joye

20 years ago
On Fri, 14 Oct 2005 01:39:08 +0400 antony@zend.com (Antony Dovgal) wrote:
> Also, what if someone uses --without-zlib? The installer would fail > again?
Yes, so the solution is to go with uncompressed phar in php releases. It gets compressed anyway. --Pierre