Cphalcon: [BUG]: Failed to execute zephir build when compiling Phalcon from source

Created on 17 Jun 2020  路  7Comments  路  Source: phalcon/cphalcon

Describe the bug
When using Ubuntu 20.04 (along with Nginx & PHP FPM 7.4), we can't use both pecl installation (gives error) and the apt packages (is not ready #14958).

So the solution is to build from source. But when running zephir build, it gives me error. I use phalcon 4.0.6 (though 4.0.0 gives the same result)

[ERROR] Class 'Memcached' does not implement method: 'setSaslAuthData' in
         /app/cphalcon/phalcon/Storage/Adapter/Libmemcached.zep on line 156

Here's the screenshot:
error-when-building-with-zephir

To Reproduce

  • Use Ubuntu 20.04 along with Nginx + PHP FPM 7.4
  • Build from source (both 4.0.6 & 4.0.0 gives the same result here)
  • The error will occur when running zephir build

Provide minimal script to reproduce the issue

git clone https://github.com/phalcon/cphalcon
cd cphalcon/
git checkout tags/v4.0.6 ./
zephir fullclean
zephir build

Expected behavior
@ruudboon had a success installation using this env. Then i re-install the server and start from beginning and got error above.

Details

  • Phalcon version: 4.0.6
  • PHP Version: 7.4
  • Operating System: Ubuntu 20.04
  • Installation type: Compiling from source
  • Zephir version (if any): latest
  • Server: Nginx

Additional context
I can provide the _ssh root_ for testing this bug.

bug unverified

Most helpful comment

Hi @Jeckerson , you're correct, it was because of insufficient memory.
Thanks for helping

All 7 comments

What version of Zephir are you using? Please use 0.12.17

Hi @Jeckerson ,
Ow yea, i was like in 0.11.12 . After switching to 0.12.17 and 0.12.19, the _Compiling..._ stucked and never finished (until the ssh disconnected)

Might be because of insufficient RAM. Try to create swap with 1Gb.

@contactjavas Does problem still exist?

Hi @Jeckerson , you're correct, it was because of insufficient memory.
Thanks for helping

Also, here is example how to create swap:
https://gist.github.com/Jeckerson/2322849d9f5dbbc9543c99e49341177e

Well im not sure if it's really insufficient. I had the same issue because i was compiling memcache from source without sasl support and had the same error, after remove from memcache configure --disable-memcached-sasl it worked correctly

Was this page helpful?
0 / 5 - 0 ratings

Related issues

abcpremium picture abcpremium  路  3Comments

masood09 picture masood09  路  4Comments

mynameisbogdan picture mynameisbogdan  路  3Comments

ruudboon picture ruudboon  路  3Comments

Yakovlev-Melarn picture Yakovlev-Melarn  路  3Comments