name: Windows ARM64 Installer (MSYS2 + Inno Setup) on: push: branches: [master] pull_request: branches: [master] jobs: windows_arm64_installer: runs-on: windows-11-arm steps: - uses: actions/checkout@v4 # MSYS2 build environment (ARM64 toolchain) - uses: msys2/setup-msys2@v2 with: msystem: CLANGARM64 update: true install: >- git mingw-w64-clang-aarch64-toolchain mingw-w64-clang-aarch64-meson mingw-w64-clang-aarch64-ninja mingw-w64-clang-aarch64-pkgconf mingw-w64-clang-aarch64-gettext-tools mingw-w64-clang-aarch64-libxml2 mingw-w64-clang-aarch64-winpthreads mingw-w64-clang-aarch64-python-cffi mingw-w64-clang-aarch64-gtk2 mingw-w64-clang-aarch64-gtk-update-icon-cache mingw-w64-clang-aarch64-luajit mingw-w64-clang-aarch64-desktop-file-utils mingw-w64-clang-aarch64-ntldd - name: Configure shell: msys2 {0} run: | set -euxo pipefail export PATH="/clangarm64/bin:$PATH" rm -rf build dist mkdir -p dist # Ensure Meson uses the CLANGARM64 gettext tooling (has ITS data) export MSGFMT="/clangarm64/bin/msgfmt" # Belt + suspenders: make sure the linker sees winpthreads export LIBRARY_PATH="/clangarm64/lib:${LIBRARY_PATH:-}" export LDFLAGS="-lwinpthread ${LDFLAGS:-}" meson setup build \ --prefix=/ \ -Dtext-frontend=true \ -Ddbus=disabled \ -Dwith-upd=false \ -Dwith-perl=false \ -Dc_link_args=-lwinpthread \ -Dcpp_link_args=-lwinpthread - name: Build shell: msys2 {0} run: | set -euxo pipefail export PATH="/clangarm64/bin:$PATH" ninja -C build - name: Test shell: msys2 {0} run: | set -euxo pipefail export PATH="/clangarm64/bin:$PATH" ninja -C build test || true - name: Stage install shell: msys2 {0} run: | set -euxo pipefail export PATH="/clangarm64/bin:$PATH" DESTDIR="$PWD/dist" ninja -C build install - name: Harvest runtime DLL dependencies shell: msys2 {0} run: | set -euxo pipefail export PATH="/clangarm64/bin:$PATH" # Copy DLL deps for EXEs + plugins into dist/bin for f in dist/bin/zoitechat.exe dist/bin/zoitechat-text.exe dist/lib/zoitechat/plugins/*.dll; do [ -e "$f" ] || continue ntldd -R "$f" | tr '\\' '/' | grep -E '^/clangarm64/bin/.*\.dll$' | while read -r dll; do cp -n "$dll" dist/bin/ || true done done - name: Install Inno Setup shell: pwsh run: | $ErrorActionPreference = "Stop" if (-not (Get-Command iscc.exe -ErrorAction SilentlyContinue)) { winget install --id JRSoftware.InnoSetup -e --accept-package-agreements --accept-source-agreements } iscc.exe /? - name: Build ARM64 installer shell: pwsh run: | $ErrorActionPreference = "Stop" iscc.exe "installer\zoitechat-arm64.iss" - uses: actions/upload-artifact@v4 with: name: zoitechat-windows-arm64-installer path: installer\Output\ZoiteChat-ARM64-Setup.exe