added snuffleupagus ext support

pull/125/head
Konstantin A. Lepikhov 2020-02-26 11:18:28 +01:00
parent 37e0b4fff3
commit 310d89ade2
2 changed files with 13 additions and 1 deletions

View File

@ -54,6 +54,7 @@ rdkafka 5.5 5.6 7.0 7.1 7.2 7.3 7.4
recode 5.5 5.6 7.0 7.1 7.2 7.3
redis 5.5 5.6 7.0 7.1 7.2 7.3 7.4
shmop 5.5 5.6 7.0 7.1 7.2 7.3 7.4
snuffleupagus 7.0 7.1 7.2 7.3 7.4
snmp 5.5 5.6 7.0 7.1 7.2 7.3 7.4
soap 5.5 5.6 7.0 7.1 7.2 7.3 7.4
sockets 5.5 5.6 7.0 7.1 7.2 7.3 7.4

View File

@ -55,7 +55,7 @@ getDistroVersion() {
# Output:
# The PHP numeric Major-Minor version
getPHPMajorMinor() {
php -r '$v = explode(".", PHP_VERSION); echo $v[0] * 100 + $v[1];'
php-config --version | awk -F. '{print $1*100+$2}'
}
# Get the normalized list of already installed PHP modules
@ -553,6 +553,10 @@ buildRequiredPackageLists() {
esac
fi
;;
snuffleupagus@alpine)
buildRequiredPackageLists_persistent="$buildRequiredPackageLists_persistent pcre"
buildRequiredPackageLists_volatile="$buildRequiredPackageLists_volatile pcre-dev"
;;
snmp@alpine)
buildRequiredPackageLists_persistent="$buildRequiredPackageLists_persistent net-snmp-libs"
buildRequiredPackageLists_volatile="$buildRequiredPackageLists_volatile net-snmp-dev"
@ -1002,6 +1006,7 @@ installModuleFromSource() {
printf '### INSTALLING MODULE %s FROM SOURCE CODE ###\n' "$1"
installModuleFromSource_dir="$(getPackageSource "$2")"
cd "$installModuleFromSource_dir"
[ -d "$installModuleFromSource_dir"/src ] && cd src
phpize
./configure $3 CFLAGS="${4:-}"
make -j$(nproc) install
@ -1413,6 +1418,12 @@ for PHP_MODULE_TO_INSTALL in $PHP_MODULES_TO_INSTALL; do
MODULE_SOURCE_CONFIGOPTIONS=--enable-igbinary
MODULE_SOURCE_CFLAGS='-O2 -g'
;;
snuffleupagus)
MODULE_SOURCE="https://github.com/jvoisin/snuffleupagus/archive/v0.5.0.tar.gz"
MODULE_SOURCE_CONFIGOPTIONS=--enable-snuffleupagus
cd "$(getPackageSource https://github.com/jvoisin/snuffleupagus/archive/v0.5.0.tar.gz)"
cp -a config/default.rules /usr/local/etc/php/conf.d/snuffleupagus.rules
;;
esac
if test -n "$MODULE_SOURCE"; then
installModuleFromSource "$PHP_MODULE_TO_INSTALL" "$MODULE_SOURCE" "$MODULE_SOURCE_CONFIGOPTIONS" "$MODULE_SOURCE_CFLAGS"