Commit ff7333e87 for imagemagick.org
commit ff7333e87cb159bf542eac5ba55f9849055924e0
Author: Dirk Lemstra <dirk@lemstra.org>
Date: Fri Nov 6 00:37:03 2026 +0100
Moved creation of the portable archive to a script.
diff --git a/.github/build/shared/create-portable.sh b/.github/build/shared/create-portable.sh
new file mode 100755
index 000000000..4115fdf08
--- /dev/null
+++ b/.github/build/shared/create-portable.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+set -e
+
+mkdir -p "$PACKAGE_NAME/bin" "$PACKAGE_NAME/etc" "$PACKAGE_NAME/share"
+cp portable/usr/bin/magick "$PACKAGE_NAME/bin/"
+cp -a portable/usr/etc/ImageMagick-7 "$PACKAGE_NAME/etc/"
+cp -a portable/usr/share/ImageMagick-7 "$PACKAGE_NAME/share/"
+cp portable/usr/lib/ImageMagick-*/config-*/configure.xml "$PACKAGE_NAME/etc/ImageMagick-7/"
+cp ChangeLog.md LICENSE "$PACKAGE_NAME/"
+cp config/sRGB.icm "$PACKAGE_NAME/sRGB.icc"
+mkdir -p artifacts
+COPYFILE_DISABLE=1 XZ_OPT="-9e" tar -cJf "artifacts/$PACKAGE_NAME.tar.xz" "$PACKAGE_NAME"
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 4ac8dd35c..da053f823 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -9,6 +9,7 @@ on:
- configure
- m4/version.m4
- .github/build/windows/download-configure.sh
+ - .github/build/shared/create-portable.sh
- .github/build/shared/create-sbom.py
- .github/build/shared/download-dependencies.sh
- .github/workflows/release.yml
@@ -16,6 +17,7 @@ on:
branches:
- main
paths:
+ - .github/build/shared/create-portable.sh
- .github/build/shared/create-sbom.py
- .github/workflows/release.yml
@@ -593,19 +595,7 @@ jobs:
- name: Create portable archive
run: |
- set -e
- mkdir -p "$PACKAGE_NAME/bin" "$PACKAGE_NAME/etc" "$PACKAGE_NAME/share"
- cp portable/usr/bin/magick "$PACKAGE_NAME/bin/"
- for utility in compare composite conjure convert identify magick-script mogrify montage stream; do
- ln -s magick "$PACKAGE_NAME/bin/$utility"
- done
- cp -a portable/usr/etc/ImageMagick-7 "$PACKAGE_NAME/etc/"
- cp -a portable/usr/share/ImageMagick-7 "$PACKAGE_NAME/share/"
- cp portable/usr/lib/ImageMagick-*/config-*/configure.xml "$PACKAGE_NAME/etc/ImageMagick-7/"
- cp ChangeLog.md LICENSE "$PACKAGE_NAME/"
- cp config/sRGB.icm "$PACKAGE_NAME/sRGB.icc"
- mkdir -p artifacts
- XZ_OPT="-9e" tar -cJf "artifacts/$PACKAGE_NAME.tar.xz" "$PACKAGE_NAME"
+ bash .github/build/shared/create-portable.sh
- name: Create SBOM
env:
@@ -704,19 +694,7 @@ jobs:
- name: Create portable archive
run: |
- set -e
- mkdir -p "$PACKAGE_NAME/bin" "$PACKAGE_NAME/etc" "$PACKAGE_NAME/share"
- cp portable/usr/bin/magick "$PACKAGE_NAME/bin/"
- for utility in compare composite conjure convert identify magick-script mogrify montage stream; do
- ln -s magick "$PACKAGE_NAME/bin/$utility"
- done
- cp -a portable/usr/etc/ImageMagick-7 "$PACKAGE_NAME/etc/"
- cp -a portable/usr/share/ImageMagick-7 "$PACKAGE_NAME/share/"
- cp portable/usr/lib/ImageMagick-*/config-*/configure.xml "$PACKAGE_NAME/etc/ImageMagick-7/"
- cp ChangeLog.md LICENSE "$PACKAGE_NAME/"
- cp config/sRGB.icm "$PACKAGE_NAME/sRGB.icc"
- mkdir -p artifacts
- XZ_OPT="-9e" tar -cJf "artifacts/$PACKAGE_NAME.tar.xz" "$PACKAGE_NAME"
+ bash .github/build/shared/create-portable.sh
- name: Create SBOM
env:
@@ -799,20 +777,7 @@ jobs:
- name: Create portable archive
run: |
- set -e
- mkdir -p "$PACKAGE_NAME/bin" "$PACKAGE_NAME/etc" "$PACKAGE_NAME/share"
- cp portable/usr/bin/magick "$PACKAGE_NAME/bin/"
- codesign --force --sign - "$PACKAGE_NAME/bin/magick"
- for utility in compare composite conjure convert identify magick-script mogrify montage stream; do
- ln -s magick "$PACKAGE_NAME/bin/$utility"
- done
- cp -a portable/usr/etc/ImageMagick-7 "$PACKAGE_NAME/etc/"
- cp -a portable/usr/share/ImageMagick-7 "$PACKAGE_NAME/share/"
- cp portable/usr/lib/ImageMagick-*/config-*/configure.xml "$PACKAGE_NAME/etc/ImageMagick-7/"
- cp ChangeLog.md LICENSE "$PACKAGE_NAME/"
- cp config/sRGB.icm "$PACKAGE_NAME/sRGB.icc"
- mkdir -p artifacts
- COPYFILE_DISABLE=1 XZ_OPT="-9e" tar -cJf "artifacts/$PACKAGE_NAME.tar.xz" "$PACKAGE_NAME"
+ bash .github/build/shared/create-portable.sh
- name: Create SBOM
env: