From 4a2cf53fbce50d689aa5c3745c5d23b03fa99005 Mon Sep 17 00:00:00 2001 From: Eberhard Beilharz Date: Fri, 11 Jul 2025 08:52:11 +0200 Subject: [PATCH] maint(windows): replace use of `wzzip` with `add_zip_files` This makes use of the new functionality refactored in the previous commit by replacing the use of the `wzzip` function with `add_zip_files`. Test-bot: skip --- developer/src/inst/build.sh | 3 +-- oem/firstvoices/windows/src/inst/build.sh | 4 ++-- resources/build/win/zip.inc.sh | 14 -------------- windows/src/desktop/inst/build.sh | 6 +++--- 4 files changed, 6 insertions(+), 21 deletions(-) delete mode 100644 resources/build/win/zip.inc.sh diff --git a/developer/src/inst/build.sh b/developer/src/inst/build.sh index 07260c8b1d..504811eb4b 100755 --- a/developer/src/inst/build.sh +++ b/developer/src/inst/build.sh @@ -22,7 +22,6 @@ builder_parse "$@" . "${KEYMAN_ROOT}/resources/build/win/environment.inc.sh" . "${KEYMAN_ROOT}/resources/build/win/wix.inc.sh" -. "${KEYMAN_ROOT}/resources/build/win/zip.inc.sh" . "${KEYMAN_ROOT}/resources/build/zip.inc.sh" # In dev environments, we'll hack the tier to alpha; CI sets this for us in real builds. @@ -234,7 +233,7 @@ function make-installer() { echo "Version=$KEYMAN_VERSION" >> setup.inf echo "MSIFileName=keymandeveloper.msi" >> setup.inf echo "Title=Keyman Developer ${KEYMAN_VERSION_WITH_TAG}" >>setup.inf - wzzip setup.zip keymandeveloper.msi setup.inf + add_zip_files setup.zip keymandeveloper.msi setup.inf cat "$DEVELOPER_PROGRAM/setup.exe" setup.zip > "keymandeveloper-$KEYMAN_VERSION.exe" wrap-signcode //d "Keyman Developer" "keymandeveloper-$KEYMAN_VERSION.exe" diff --git a/oem/firstvoices/windows/src/inst/build.sh b/oem/firstvoices/windows/src/inst/build.sh index ac6c309554..0d0767ae66 100755 --- a/oem/firstvoices/windows/src/inst/build.sh +++ b/oem/firstvoices/windows/src/inst/build.sh @@ -22,7 +22,7 @@ builder_parse "$@" . "$KEYMAN_ROOT/resources/build/win/environment.inc.sh" . "$KEYMAN_ROOT/resources/build/win/wix.inc.sh" -. "$KEYMAN_ROOT/resources/build/win/zip.inc.sh" +. "$KEYMAN_ROOT/resources/build/zip.inc.sh" # In dev environments, we'll hack the tier to alpha; CI sets this for us in real builds. if [[ -z ${KEYMAN_TIER+x} ]]; then @@ -85,7 +85,7 @@ function do_publish() { # Build self-extracting archive # create-setup-inf - wzzip firstvoices.zip firstvoices.msi license.html setup.inf setuptitle.png fv_all.kmp + add_zip_files firstvoices.zip firstvoices.msi license.html setup.inf setuptitle.png fv_all.kmp rm -f setup.inf cat "$WINDOWS_PROGRAM_APP/setup-redist.exe" firstvoices.zip > firstvoices.exe rm -f firstvoices.zip diff --git a/resources/build/win/zip.inc.sh b/resources/build/win/zip.inc.sh deleted file mode 100644 index 8765ee959d..0000000000 --- a/resources/build/win/zip.inc.sh +++ /dev/null @@ -1,14 +0,0 @@ - -WZZIPPATH="$ProgramFiles/7-zip/7z.exe" - -wzzip() { - if [[ $GO_FAST == 1 ]]; then - "$WZZIPPATH" a -mx1 "$@" - else - "$WZZIPPATH" a -mx9 "$@" - fi -} - -wzunzip() { - "$WZZIPPATH" e "$@" -} \ No newline at end of file diff --git a/windows/src/desktop/inst/build.sh b/windows/src/desktop/inst/build.sh index ca8df31c65..a490c32f06 100755 --- a/windows/src/desktop/inst/build.sh +++ b/windows/src/desktop/inst/build.sh @@ -21,7 +21,7 @@ builder_parse "$@" . "$KEYMAN_ROOT/resources/build/win/environment.inc.sh" . "$KEYMAN_ROOT/resources/build/win/wix.inc.sh" -. "$KEYMAN_ROOT/resources/build/win/zip.inc.sh" +. "$KEYMAN_ROOT/resources/build/zip.inc.sh" # In dev environments, we'll hack the tier to alpha; CI sets this for us in real builds. if [[ -z ${KEYMAN_TIER+x} ]]; then @@ -86,7 +86,7 @@ function do_publish() { # Build self-extracting archive # create-setup-inf - wzzip keymandesktop.zip keymandesktop.msi license.html setup.inf + add_zip_files keymandesktop.zip keymandesktop.msi license.html setup.inf rm -f setup.inf cat "$WINDOWS_PROGRAM_APP/setup-redist.exe" keymandesktop.zip > keymandesktop.exe rm -f keymandesktop.zip @@ -110,7 +110,7 @@ function copy-installer() { builder_if_release_build_level verify-installer-signatures # Copy the unsigned setup.exe for use in bundling scenarios; zip it up for clarity - wzzip "$KEYMAN_ROOT/windows/release/${KEYMAN_VERSION}/setup-redist.zip" "$WINDOWS_PROGRAM_APP/setup-redist.exe" + add_zip_files "${KEYMAN_ROOT}/windows/release/${KEYMAN_VERSION}/setup-redist.zip" "${WINDOWS_PROGRAM_APP}/setup-redist.exe" } function verify-program-signatures() {