Install Phalcon PHP framework in openSUSE

Phalcon is a web framework implemented as a C extension offering high performance and lower resource consumption”. From the benchmark page, “The compiled nature of Phalcon offers extraordinary performance that outperforms all other frameworks measured in these benchmarks”. Personally i find it very easy to work with, less dirs and files for the project. And it’s documentation is quite organized and useful. Installation in Linux distros is quite easy for most of the parts. Let’s install in openSUSE 12.3 and 13.1. 1st of all let’s thank Mariusz Łączak for his useful work to provide repositories. Fire up a terminal and become root by su – .

If you are on openSUSE 12.3, add this repo:

[cc lang=”bash” escaped=”true” nowrap=”false” noborder=”true” line_numbers=”false” lines=”2″ tab_size=”4″]

zypper ar -f http://download.opensuse.org/repositories/home:/mruz/openSUSE_12.3/ Phalcon

[/cc]

For openSUSE 13.1:

[cc lang=”bash” escaped=”true” nowrap=”false” noborder=”true” line_numbers=”false” lines=”2″ tab_size=”4″]

zypper ar -f http://download.opensuse.org/repositories/home:/mruz/openSUSE_13.1/ Phalcon

[/cc]

zypper-add-repo-phalcon

Refresh the repos:

[cc lang=”bash” escaped=”true” nowrap=”false” noborder=”true” line_numbers=”false” lines=”2″ tab_size=”4″]

zypper ref

[/cc]

It will ask for the key to trust for the new repo, just type a to trust always. We are almost there.

Before installation of phalcon, we need to make sure that these dependencies are installed: mbstring, mcrypt, opensll, pdo/MySQL

If not, no worries install it by using this command:

[cc lang=”bash” escaped=”true” nowrap=”false” noborder=”true” line_numbers=”false” lines=”2″ tab_size=”4″]

zypper in php5-mbstring mcrypt openssl php5-pdo

[/cc]

Time to install phalcon:

[cc lang=”bash” escaped=”true” nowrap=”false” noborder=”true” line_numbers=”false” lines=”2″ tab_size=”4″]

zypper in php5-phalcon

[/cc]

And that’s it, but before jumping to your web dir to start a demo project, restart apache:

[cc lang=”bash” escaped=”true” nowrap=”false” noborder=”true” line_numbers=”false” lines=”2″ tab_size=”4″]

systemctl restart apache2.service

[/cc]

Phalcon documentation are self explanatory and easy to follow. Start here for a test project.