diff --git a/install_binaries.sh b/install_binaries.sh
index 7372335..91e7976 100755
--- a/install_binaries.sh
+++ b/install_binaries.sh
@@ -1331,31 +1331,7 @@ cd php-src
 cd ext
 cd apcu && git fetch --all && git checkout v5.1.23 && cd ..
 cd php-ext-brotli && git fetch --all && git checkout 0.13.1 && cd ..
-cd imagick && git fetch --all && git checkout 3.7.0
-cat <<EOF | git apply -
-From 7088edc353f53c4bc644573a79cdcd67a726ae16 Mon Sep 17 00:00:00 2001
-From: FedericoHeichou <federicoheichou@gmail.com>
-Date: Fri, 24 Nov 2023 11:24:00 +0100
-Subject: [PATCH] Fix compilation error "Unterminated preprocessor conditions"
- in php 8.3
-
----
- Imagick.stub.php | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/Imagick.stub.php b/Imagick.stub.php
-index 804c0152..49da9386 100644
---- a/Imagick.stub.php
-+++ b/Imagick.stub.php
-@@ -1669,4 +1669,5 @@ public function setInterpolateMethod(int $method): bool{}
- 	public function setOrientation(int $orientation): bool {}
- #endif
- 
-+#endif
- }
-EOF
-
-cd ..
+cd imagick && git fetch --all && git checkout 3.7.0 && cd ..
 cd php-gnupg && git fetch --all --recurse-submodules && git checkout gnupg-1.5.1 --recurse-submodules && cd ..
 cd php-rar && git fetch --all && git reset --hard && git checkout ab26d285759e4c917879967b09976a44829ed570
 cat <<EOF | git apply -