Move dependency setup to cache-extensions

This commit is contained in:
Shivam Mathur 2020-02-25 09:38:53 +05:30
parent 9b297384e1
commit a4f7326577
No known key found for this signature in database
GPG Key ID: 3E13E4C8591ACC2A

View File

@ -86,8 +86,6 @@ add_extension() {
install_command="update_ppa && ${install_command/5\.[4-5]-$extension/5-$extension=$release_version}" install_command="update_ppa && ${install_command/5\.[4-5]-$extension/5-$extension=$release_version}"
fi fi
if ! check_extension "$extension" && [ -e "$ext_dir/$extension.so" ]; then if ! check_extension "$extension" && [ -e "$ext_dir/$extension.so" ]; then
# shellcheck disable=SC2046
$apt_install $(apt-cache depends php"$version"-"$extension" 2>/dev/null | awk '/Depends:/{print$2}') >/dev/null 2>&1
echo "$prefix=$extension.so" >>"$ini_file" && add_log "$tick" "$extension" "Enabled" echo "$prefix=$extension.so" >>"$ini_file" && add_log "$tick" "$extension" "Enabled"
elif check_extension "$extension"; then elif check_extension "$extension"; then
add_log "$tick" "$extension" "Enabled" add_log "$tick" "$extension" "Enabled"