1

I have a fairly fresh Debian Testing install, and I am trying to install PEAR / PECL but when I run the command nothing happens. I don't want to install the PEAR package in the Debian repositories because in my experience it is too old. I have installed php5-dev.

Here is what I tried:

$ wget http://pear.php.net/go-pear.phar $ php go-pear.phar 

I also tried sudo php go-pear.phar.

$ php -version PHP 5.3.6-13 with Suhosin-Patch (cli) (built: Jul 4 2011 12:42:46) Copyright (c) 1997-2011 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2011 Zend Technologies with Suhosin v0.9.32.1, Copyright (c) 2007-2010, by SektionEins GmbH 

Any thoughts how I can see what is going wrong here?

-- Edit

if I do: php -i | grep phar I get:

Registered PHP Streams => https, ftps, compress.zlib, compress.bzip2, php, file, glob, data, http, ftp, phar, zip Phar-based phar archives => enabled Tar-based phar archives => enabled ZIP-based phar archives => enabled phar.cache_list => no value => no value phar.readonly => On => On phar.require_hash => On => On 

There is no phar.ini in /etc/php5/conf.d/.

-- Edit 2

I have installed PEAR from the Debian repositories now and run pear upgrade. Still interested to figure out why the go-pear.phar installation is not working.

$ whereis php

php: /usr/bin/php /usr/share/php /usr/share/man/man1/php.1.gz 

$ whereis pear

pear: /usr/bin/pear /etc/pear 
4
  • Do you mean it didn't show the prompt after typing php go-pear.phar? Commented Aug 31, 2011 at 8:10
  • No, I mean it shows the prompt immediately afterward, without showing anything else. Just in case it was a silent install I tried running both pear and pecl. The system did not recognise the commands, so I assume they weren't installed. Commented Aug 31, 2011 at 17:32
  • What does prompt say? Commented Sep 1, 2011 at 2:04
  • Sorry I misunderstood, I thought you meant the commandline prompt. I enter after the command and am immediately returned to the commandline prompt. There is no output or prompts from the sudo php go-pear.phar. This is what I meant when I said nothing happens. Commented Sep 1, 2011 at 16:37

3 Answers 3

2

This is what worked for me. Tested on a Debian Squeeze amd64 installation:

$ php -d suhosin.executor.include.whitelist="phar" go-pear.phar 
0

Try this:

$ php -d phar.require_hash=0 go-pear.phar 

pear: /usr/bin/pear /etc/pear 

It means that the PEAR is already installed. Type pear -version to check its version. Uninstall it first and try again.

3
  • No, that didn't make any difference. Commented Sep 1, 2011 at 18:28
  • What is the output of: whereis php, whereis pear? Commented Sep 2, 2011 at 1:08
  • See my edit to the main question. Commented Sep 2, 2011 at 6:42
0

Another interesting situation is if you are listening for remote XDebug connections and pecl is driven by PHP, so it may catch and break the process.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.