cphalcon: [BUG]: Install of Phalcon 5 Fails Using pecl on Ubuntu 22.04
When attempting to install Phalcon 5 in Ubuntu 22.04 using pecl, the build throws a lot of error and fails.
I start with “pecl channel-update pecl.php.net” which produces:
Updating channel "pecl.php.net"
Channel "pecl.php.net" is up to date
I then enter “pecl install phalcon” (I’ve also tried “pecl install phalcon-5.0.0”, “pecl install phalcon-5.1.0” and “pecl install phalcon-5.1.1”) and pecl starts and produces a lot of warning and then fails to build as outlined in the attached file.
Details
- Phalcon version: (
php --ri phalcon) INCOMPLETE, SO VERSION UNAVAILABLE - PHP Version: (
php -v): 8.1.12 - Operating System: Ubuntu 22.04
- Installation type: PECL
- Zephir version: N/A
- Server: Apache
- Other related info (Database, table schema): N/A kbg.txt
About this issue
- Original URL
- State: open
- Created 2 years ago
- Reactions: 2
- Comments: 26 (10 by maintainers)
@kgrammer,
I’ve found a reasonable workaround in the interim. It seems the issue with phalcon 5 isn’t phalcon 5, but the compiling of it using make. So I thought… why not just get it precompiled?
If you have wget and an unzipping tool installed (I used p7zip-full) you can do the following
wget https://github.com/phalcon/cphalcon/releases/download/v5.1.1/phalcon-php8.1-nts-ubuntu-gcc-x64.zip7z x phalcon-php8.1-nts-ubuntu-gcc-x64.zipAfter extracting the zip, you just have to manually move the phalcon.so file and register it in apache Be sure to double check the version of phalcon, version of php, and if you are using thread safe version of php or not.
happy coding!!
https://docs.phalcon.io/latest/installation/#linux-deb-ondrej-sury
Still here buddy
Sadly no. Adding phalcon back to packagecloud introduces one more thing that we have to deal with in every release, and trust me we spent a lot of time setting those processes up. That was one of the main reasons that we wanted to go with PECL so that we don’t have to do all this work. Remi and Onrej also have repositories that offer Phalcon, and although not everyone can use them, they are there.
Thanks Jeckerson.
Today’s PECL build attempt was on a server with 2GB of memory. The initial report failed on a server with 8GB of memory. I can try the PECL build on the 8gb server, but it’s my production server and I will have to find an off-hours time for that to happen since the PECL build takes quite some time to complete. That is difficult to do on a server that has international users.
My point about the documentation is one I’ve made several times now. The documentation doesn’t say “pecl install phalcon” so a new user, reading the Phalcon 5 install guide, would be unable to make it past that step. As written, the documentation ensures failure for new Phalcon users trying to use the preferred installation method.
Niden and I have chatted about this a few times, and I while understand the difficulty of keeping the web site current with the latest release, failing to do adds roadblocks for new users.
“Why is this labeled not a bug?”
My question exactly. 😃
Here are my build commands that I’ve used to install Phalcon 5 now on about a dozen servers but I’m not running docker:
cd /usr/local/lib git clone https://github.com/phalcon/cphalcon cd cphalcon git checkout tags/v5.1.3 ./ zephir fullclean zephir build phpenmod Phalcon