Wednesday, July 29, 2015

PHP gettext extension missing (Zabbix)

PHP gettext extension missing (PHP configuration parameter --with-gettext)

The getText PHP usage (getText is a set of tools and libraries to help programmers and translators to develop multi-language software), in order to achieve the PHP i18n.

No way, looked under the original extension was not installed gettest when installed php, no way to re-fill

Mainly two aspects cause PHP gettext extension missing (PHP configuration parameter --with-gettext) this error: First, do not add --with-gettext option when compiling PHP
Solutions are as follows:
The installation is a dynamic installation of php gettext extension module in php source file into the /ext /gettext
cd /ext/gettext
/Usr/local/php/bin/phpize
./configure -with-php-config = /usr/local/php/bin/php-config
make && make install
Second, the system lacks gettext-devel tool library, or already compile and install the gettext but could not find a way to compile php
vi /usr/local/php/etc/php.ini
Find extensions option, add the following entry:
extension = "gettext.so"
Here remember to add the path to extensions

restart apache service
That's it.......