How to compile phalcon for php7 on raspian "stretch" 9?

Hi there

How to compile phalcon for php7 on raspian "stretch" 9 with gccc?

Does somebody know this?

THank you for your feedbacks.

Best regards, Jan



79.4k
cd /tmp/;
git clone https://github.com/phalcon/cphalcon.git cphalcon
cd cphalcon;
./ext/install

./configure: File or directory not found

?

You must make sure that your OS meets all required deps for compilation process.

Start by downloading latest release https://github.com/phalcon/cphalcon/archive/v3.4.1.tar.gz

Prerequisite packages are:

  • PHP 5.5.x/5.6.x/7.0.x/7.1.x/7.2.x development resources (PHP 5.3 and 5.4 are no longer supported)
  • g++ >= 4.4 | clang++ >= 3.x | vc++ >= 11
  • GNU make >= 3.81
  • re2c >= 0.13

go to build directory and start ./install script.

edited Aug '18

[email protected]:/tmp/cphalcon/build# ./install
Configuring for:
PHP Api Version:         20151012
Zend Module Api No:      20151012
Zend Extension Api No:   320151012
libtool: compile:  gcc -I. -I/tmp/cphalcon/build/php7/32bits -DPHP_ATOM_INC -I/tmp/cphalcon/build/php7/32bits/include -I/tmp/cphalcon/build/php7/32bits/main -I/tmp/cphalcon/build/php7/32bits -I/usr/include/php/20151012 -I/usr/include/php/20151012/main -I/usr/include/php/20151012/TSRM -I/usr/include/php/20151012/Zend -I/usr/include/php/20151012/ext -I/usr/include/php/20151012/ext/date/lib -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DPHALCON_RELEASE -DHAVE_CONFIG_H -march=native -mtune=native -O2 -fomit-frame-pointer -c /tmp/cphalcon/build/php7/32bits/phalcon.zep.c  -fPIC -DPIC -o .libs/phalcon.o
gcc: internal compiler error: Getötet (program cc1)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-6/README.Bugs> for instructions.
Makefile:194: die Regel für Ziel „phalcon.lo“ scheiterte
make: *** [phalcon.lo] Fehler 1
libtool: compile:  gcc -I. -I/tmp/cphalcon/build/php7/32bits -DPHP_ATOM_INC -I/tmp/cphalcon/build/php7/32bits/include -I/tmp/cphalcon/build/php7/32bits/main -I/tmp/cphalcon/build/php7/32bits -I/usr/include/php/20151012 -I/usr/include/php/20151012/main -I/usr/include/php/20151012/TSRM -I/usr/include/php/20151012/Zend -I/usr/include/php/20151012/ext -I/usr/include/php/20151012/ext/date/lib -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DPHALCON_RELEASE -DHAVE_CONFIG_H -march=native -mtune=native -O2 -fomit-frame-pointer -c /tmp/cphalcon/build/php7/32bits/phalcon.zep.c  -fPIC -DPIC -o .libs/phalcon.o
gcc: internal compiler error: Getötet (program cc1)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-6/README.Bugs> for instructions.
Makefile:194: die Regel für Ziel „phalcon.lo“ scheiterte
make: *** [phalcon.lo] Fehler 1

Thanks for compiling Phalcon!
Build succeed: Please restart your web server to complete the installation

> "Build succeed: Please restart your web server to complete the installation"

``

That's not true...:-(
edited Oct '18

Now it works, and i also increased the swap size. (I don't know what the problem was - too less of swap memory size or using the wrong (master) branch?)

Thank you very very much!! :-)

With best regards, Jan



79.4k

compiling requires memory, ~ 1 gb for the operation system i think is fine.