Using PECL without installing PEAR

  107787
November 13, 2019 16:43 matthieu@mnapoli.fr (Matthieu Napoli)
Hi all,

Following a discussion with Nikita, I understood that [installing PEAR with PHP is deprecated](https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101 <https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101>).
However, installing PEAR is necessary for PECL to work (it uses PEAR).

I started having a look at what could be done to use PECL without PEAR. This lead me to the following question: as a first step, would it make sense to provide PECL as a self-contained PHAR?
That way users can download the PHAR and avoid install PEAR. Following that we can have a look at trimming the PECL package, but the PHAR would be a first step.

Thanks

Matthieu
  107788
November 13, 2019 17:21 ben@benramsey.com (Ben Ramsey)
> On Nov 13, 2019, at 10:43, Matthieu Napoli <matthieu@mnapoli.fr> wrote: > > Hi all, > > Following a discussion with Nikita, I understood that [installing PEAR with PHP is deprecated](https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101 <https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101>). > However, installing PEAR is necessary for PECL to work (it uses PEAR). > > I started having a look at what could be done to use PECL without PEAR. This lead me to the following question: as a first step, would it make sense to provide PECL as a self-contained PHAR? > That way users can download the PHAR and avoid install PEAR. Following that we can have a look at trimming the PECL package, but the PHAR would be a first step. > > Thanks > > Matthieu
What’s the status of the pickle installer? It doesn’t look like it’s been touched since 2017. https://github.com/FriendsOfPHP/pickle I thought that was a promising project. Did it work well? Were there problems? Cheers, Ben
  107789
November 13, 2019 17:33 cmbecker69@gmx.de ("Christoph M. Becker")
On 13.11.2019 at 17:43, Matthieu Napoli wrote:

> Following a discussion with Nikita, I understood that [installing PEAR with PHP is deprecated](https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101 <https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101>). > However, installing PEAR is necessary for PECL to work (it uses PEAR). > > I started having a look at what could be done to use PECL without PEAR. This lead me to the following question: as a first step, would it make sense to provide PECL as a self-contained PHAR? > That way users can download the PHAR and avoid install PEAR. Following that we can have a look at trimming the PECL package, but the PHAR would be a first step.
Are you looking for <https://github.com/pear/pearweb_phars>? -- Christoph M. Becker
  107798
November 15, 2019 14:40 nikita.ppv@gmail.com (Nikita Popov)
On Wed, Nov 13, 2019 at 5:44 PM Matthieu Napoli <matthieu@mnapoli.fr> wrote:

> Hi all, > > Following a discussion with Nikita, I understood that [installing PEAR > with PHP is deprecated]( > https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101 < > https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101>). > However, installing PEAR is necessary for PECL to work (it uses PEAR). > > I started having a look at what could be done to use PECL without PEAR. > This lead me to the following question: as a first step, would it make > sense to provide PECL as a self-contained PHAR? > That way users can download the PHAR and avoid install PEAR. Following > that we can have a look at trimming the PECL package, but the PHAR would be > a first step. > > Thanks > > Matthieu
I think that makes sense. The only thing we really want/need from PEAR is the "pecl" command, and having a single self-contained phar for that would be much better than requiring a global PEAR installation, and allow us to change the underlying implementation more easily in the future. Nikita
  107799
November 15, 2019 15:03 pierre.php@gmail.com (Pierre Joye)
On Fri, Nov 15, 2019, 3:41 PM Nikita Popov ppv@gmail.com> wrote:

> On Wed, Nov 13, 2019 at 5:44 PM Matthieu Napoli <matthieu@mnapoli.fr> > wrote: > > > Hi all, > > > > Following a discussion with Nikita, I understood that [installing PEAR > > with PHP is deprecated]( > > https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101 < > > https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101>). > > However, installing PEAR is necessary for PECL to work (it uses PEAR). > > > > I started having a look at what could be done to use PECL without PEAR. > > This lead me to the following question: as a first step, would it make > > sense to provide PECL as a self-contained PHAR? > > That way users can download the PHAR and avoid install PEAR. Following > > that we can have a look at trimming the PECL package, but the PHAR would > be > > a first step. > > > > Thanks > > > > Matthieu > > > I think that makes sense. The only thing we really want/need from PEAR is > the "pecl" command, and having a single self-contained phar for that would > be much better than requiring a global PEAR installation, and allow us to > change the underlying implementation more easily in the future. >
Also if there is an interest I can give back some love to Pickle ( https://github.com/FriendsOfPHP/pickle) and ensure it works smoothly up to php master or 7.4/7.4+1. The phar releases support pecl.php.net, github or any git/directory install of extensions. Best, Pierre
>
  107801
November 15, 2019 16:58 matthieu@mnapoli.fr (Matthieu Napoli)
> Le 15 nov. 2019 à 16:03, Pierre Joye php@gmail.com> a écrit : > > On Fri, Nov 15, 2019, 3:41 PM Nikita Popov ppv@gmail.com> wrote: > On Wed, Nov 13, 2019 at 5:44 PM Matthieu Napoli <matthieu@mnapoli.fr> wrote: > > > Hi all, > > > > Following a discussion with Nikita, I understood that [installing PEAR > > with PHP is deprecated]( > > https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101 < > > https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101>). > > However, installing PEAR is necessary for PECL to work (it uses PEAR). > > > > I started having a look at what could be done to use PECL without PEAR. > > This lead me to the following question: as a first step, would it make > > sense to provide PECL as a self-contained PHAR? > > That way users can download the PHAR and avoid install PEAR. Following > > that we can have a look at trimming the PECL package, but the PHAR would be > > a first step. > > > > Thanks > > > > Matthieu > > > I think that makes sense. The only thing we really want/need from PEAR is > the "pecl" command, and having a single self-contained phar for that would > be much better than requiring a global PEAR installation, and allow us to > change the underlying implementation more easily in the future. > > > Also if there is an interest I can give back some love to Pickle (https://github.com/FriendsOfPHP/pickle) and ensure it works smoothly up to php master or 7.4/7.4+1. The phar releases support pecl.php.net, github or any git/directory install of extensions. > > Best, > Pierre
Hi Pierre, I spent some time on Pickle as well. The thing isn't maintained, the tests do not pass, I had a hard time doing anything. I still tried to fix most of the tests here: https://github.com/FriendsOfPHP/pickle/pull/164 but I didn't manage to make the CI green. Removing HHVM support did make the code much cleaner, and I think I can help as well but I am afraid that nobody will merge anything. If you get the project going again that could be great. One main thing that could help is listing what's missing. In other words, I don't know what to do. If Pickle works already and just need a green test suite and a new version, then maybe we can start with that and then advertise it as a viable replacement to PEAR? Matthieu
  107802
November 15, 2019 17:05 pierre.php@gmail.com (Pierre Joye)
On Fri, Nov 15, 2019, 5:58 PM Matthieu Napoli <matthieu@mnapoli.fr> wrote:

> > > Le 15 nov. 2019 à 16:03, Pierre Joye php@gmail.com> a écrit : > > > > On Fri, Nov 15, 2019, 3:41 PM Nikita Popov ppv@gmail.com> wrote: > > On Wed, Nov 13, 2019 at 5:44 PM Matthieu Napoli <matthieu@mnapoli.fr> > wrote: > > > > > Hi all, > > > > > > Following a discussion with Nikita, I understood that [installing PEAR > > > with PHP is deprecated]( > > > https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101 < > > > https://github.com/php/php-src/blob/PHP-7.4/UPGRADING#L98-L101>). > > > However, installing PEAR is necessary for PECL to work (it uses PEAR).. > > > > > > I started having a look at what could be done to use PECL without PEAR. > > > This lead me to the following question: as a first step, would it make > > > sense to provide PECL as a self-contained PHAR? > > > That way users can download the PHAR and avoid install PEAR. Following > > > that we can have a look at trimming the PECL package, but the PHAR > would be > > > a first step. > > > > > > Thanks > > > > > > Matthieu > > > > > > I think that makes sense. The only thing we really want/need from PEAR is > > the "pecl" command, and having a single self-contained phar for that > would > > be much better than requiring a global PEAR installation, and allow us to > > change the underlying implementation more easily in the future. > > > > > > Also if there is an interest I can give back some love to Pickle ( > https://github.com/FriendsOfPHP/pickle) and ensure it works smoothly up > to php master or 7.4/7.4+1. The phar releases support pecl.php.net, > github or any git/directory install of extensions. > > > > Best, > > Pierre > > Hi Pierre, > I spent some time on Pickle as well. The thing isn't maintained, the tests > do not pass, I had a hard time doing anything. I still tried to fix most of > the tests here: https://github.com/FriendsOfPHP/pickle/pull/164 but I > didn't manage to make the CI green. Removing HHVM support did make the code > much cleaner, and I think I can help as well but I am afraid that nobody > will merge anything.
Let me check the PR and merge them this weekend :) If you get the project going again that could be great.
>
I would be more than happy to see it running. I am lacking time but I can have some hours here and there to help. One main thing that could help is listing what's missing. In other words, I
> don't know what to do. >
See below, the big selling point is to get it to work together with composer. I did a PR back then but we decided it should be done another way, which we need to figure out :) If Pickle works already and just need a green test suite and a new version,
> then maybe we can start with that and then advertise it as a viable > replacement to PEAR? >
I created it and then a few took over most of the devs, and yes, it is thought to fully replace pear/pecl as well as a better together works with composer (need work on their side but Jordi and I need to sit down to get it done :)
> Matthieu