Skip to content

Commit 5afed16

Browse files
committed
Fix support for imagick for PHP 5.3 to 5.5 on macOS
1 parent 14fa980 commit 5afed16

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/scripts/darwin.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,12 @@ add_extension() {
8686
if check_extension "$extension"; then
8787
add_log "${tick:?}" "$extension" "Enabled"
8888
else
89-
[[ "$version" =~ 5.[4-5] ]] && [ "$extension" = "imagick" ] && brew install -f pkg-config imagemagick >/dev/null 2>&1
90-
pecl_install "$extension" >/dev/null 2>&1 &&
89+
if [[ "$version" =~ ${old_versions:?} ]] && [ "$extension" = "imagick" ]; then
90+
run_script "php5-darwin" "${version/./}" "$extension" >/dev/null 2>&1
91+
else
92+
pecl_install "$extension" >/dev/null 2>&1 &&
9193
if [[ "$version" =~ ${old_versions:?} ]]; then echo "$prefix=$ext_dir/$extension.so" >>"$ini_file"; fi
94+
fi
9295
add_extension_log "$extension" "Installed and enabled"
9396
fi
9497
}

0 commit comments

Comments
 (0)