diff --git a/mod_php_install.sh b/mod_php_install.sh index 8f57c0a..b5e2a5c 100755 --- a/mod_php_install.sh +++ b/mod_php_install.sh @@ -2077,6 +2077,34 @@ fi ## - END: Install redis ## ----- +## ----- +## - Install uri_template - !! only versions <= 5.6 +## ----- +echononl "\tInstall uri_template via pecl.." +if [[ $MAIN_VERSION -lt 7 ]] ; then + printf "\n" | ${PREFIX_PHP}/bin/pecl install uri_template > /dev/null 2>&1 + if [ "$?" = "0" ]; then + echo_ok + + echononl "\tphp.ini: extension=uri_template.so .." + _extension="uri_template.so" + perl -i -n -p -e "s#^(\s*\[PHP\]\s*)#\1\nextension=${_extension}\napc.enable_cli = 1\n#" $PHP_INI_FILE + if [ "$?" = "0" ]; then + echo_ok + else + echo_failed + fi + + else + echo_failed + fi +else + echo_skipped + warn "Pecl extension 'uri_template' is only available for PHP versions < 7 - version 7 also excluded." +fi + + + ## ----- ## - Install APCu