From d297ecb9798e9b2b823621ca5749d1124f77e707 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thorbj=C3=B8rn=20Lindeijer?= Date: Fri, 17 Jan 2025 10:42:00 +0100 Subject: [PATCH 1/2] Fixed qaseprite compile on Windows (#4147) The `aseprite-msvc-dynamic-runtime.patch` is gone after its target `CMakeLists.txt` was merged into the qaseprite one. Check out the 1.0 tag to avoid future breakage in case changes are made to the plugin. Also use the new `update-submodules.sh` script to check out only the required submodules. The snap has been updated as well to use the 1.0 source archive. (cherry picked from commit 959100548c416fe4c31323cbf4eff68d4c4d1635) --- .github/workflows/packages.yml | 13 +++++++------ appveyor.yml | 7 ++----- snap/snapcraft.yaml | 3 ++- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/.github/workflows/packages.yml b/.github/workflows/packages.yml index 7b8f342dae..eb8aac1169 100644 --- a/.github/workflows/packages.yml +++ b/.github/workflows/packages.yml @@ -72,7 +72,7 @@ jobs: with: repository: mapeditor/qaseprite path: qaseprite - submodules: 'recursive' + ref: '1.0' - name: Install dependencies run: | @@ -128,8 +128,10 @@ jobs: - name: Install qaseprite plugin working-directory: qaseprite run: | + ./update-submodules.sh --minimal cmake -B build -DCMAKE_BUILD_TYPE=Release \ -DUSE_SHARED_ZLIB=on \ + -DUSE_SHARED_LIBPNG=on \ -DUSE_SHARED_PIXMAN=on \ -DUSE_SHARED_FREETYPE=on \ -DUSE_SHARED_HARFBUZZ=on @@ -242,7 +244,7 @@ jobs: with: repository: mapeditor/qaseprite path: qaseprite - submodules: 'recursive' + ref: '1.0' - name: Install Qt uses: jurplel/install-qt-action@v4 @@ -268,6 +270,7 @@ jobs: - name: Install qaseprite plugin working-directory: qaseprite run: | + ./update-submodules.sh --no-zlib cmake -B build -DCMAKE_BUILD_TYPE=Release \ -DUSE_SHARED_ZLIB=on \ -DCMAKE_OSX_ARCHITECTURES='${{ matrix.cmake_architectures }}' @@ -369,7 +372,7 @@ jobs: with: repository: mapeditor/qaseprite path: qaseprite - submodules: 'recursive' + ref: '1.0' - name: Install Qt uses: jurplel/install-qt-action@v4 @@ -406,9 +409,7 @@ jobs: - name: Install qaseprite plugin working-directory: qaseprite run: | - pushd aseprite - patch -p1 < ../aseprite-msvc-dynamic-runtime.patch - popd + ./update-submodules.sh pushd aseprite/laf patch -p1 < ../../laf-msvc-dynamic-runtime.patch popd diff --git a/appveyor.yml b/appveyor.yml index 0d1211a4a7..279bc21200 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -51,11 +51,8 @@ build_script: - if defined MINGW git clone --depth 1 -b release https://github.com/facebook/zstd.git - if defined MINGW cd zstd/lib & set CC=gcc & mingw32-make -j2 libzstd.a & cd ../../ - echo Building qaseprite - - git clone --depth 1 --recurse-submodules https://github.com/mapeditor/qaseprite.git - - cd qaseprite - - cd aseprite - - patch -p1 < ..\aseprite-msvc-dynamic-runtime.patch - - cd laf + - git clone --depth 1 --recurse-submodules --shallow-submodules --branch 1.0 https://github.com/mapeditor/qaseprite.git + - cd qaseprite\aseprite\laf - patch -p1 < ..\..\laf-msvc-dynamic-runtime.patch - cd ..\.. - if defined MINGW cmake -B build -DCMAKE_BUILD_TYPE=Release -G "MinGW Makefiles" diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml index e1737143f8..8390ca4191 100644 --- a/snap/snapcraft.yaml +++ b/snap/snapcraft.yaml @@ -72,11 +72,12 @@ parts: after: [desktop-qt5] qaseprite: - source: https://github.com/mapeditor/qaseprite.git + source: https://github.com/mapeditor/qaseprite/releases/download/1.0/qaseprite-1.0-source.tar.gz plugin: cmake cmake-parameters: - -DCMAKE_BUILD_TYPE=Release - -DUSE_SHARED_ZLIB=on + - -DUSE_SHARED_LIBPNG=on - -DUSE_SHARED_PIXMAN=on - -DUSE_SHARED_FREETYPE=on - -DUSE_SHARED_HARFBUZZ=on From aca6370747ed82d38b08414f39a332f889987edf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thorbj=C3=B8rn=20Lindeijer?= Date: Thu, 23 Jan 2025 17:52:39 +0100 Subject: [PATCH 2/2] CI: Updated to qaseprite 1.0.1 (#4151) Now qaseprite uses qt_add_plugin, which fixes the plugin's extension on macOS and unifies the file name to qaseprite.dll between MinGW and MSVC. --- .github/workflows/packages.yml | 6 +++--- appveyor.yml | 2 +- dist/win/installer.qbs | 4 +--- 3 files changed, 5 insertions(+), 7 deletions(-) diff --git a/.github/workflows/packages.yml b/.github/workflows/packages.yml index eb8aac1169..0375c894b1 100644 --- a/.github/workflows/packages.yml +++ b/.github/workflows/packages.yml @@ -72,7 +72,7 @@ jobs: with: repository: mapeditor/qaseprite path: qaseprite - ref: '1.0' + ref: '1.0.1' - name: Install dependencies run: | @@ -244,7 +244,7 @@ jobs: with: repository: mapeditor/qaseprite path: qaseprite - ref: '1.0' + ref: '1.0.1' - name: Install Qt uses: jurplel/install-qt-action@v4 @@ -372,7 +372,7 @@ jobs: with: repository: mapeditor/qaseprite path: qaseprite - ref: '1.0' + ref: '1.0.1' - name: Install Qt uses: jurplel/install-qt-action@v4 diff --git a/appveyor.yml b/appveyor.yml index 279bc21200..0500b3d186 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -51,7 +51,7 @@ build_script: - if defined MINGW git clone --depth 1 -b release https://github.com/facebook/zstd.git - if defined MINGW cd zstd/lib & set CC=gcc & mingw32-make -j2 libzstd.a & cd ../../ - echo Building qaseprite - - git clone --depth 1 --recurse-submodules --shallow-submodules --branch 1.0 https://github.com/mapeditor/qaseprite.git + - git clone --depth 1 --recurse-submodules --shallow-submodules --branch 1.0.1 https://github.com/mapeditor/qaseprite.git - cd qaseprite\aseprite\laf - patch -p1 < ..\..\laf-msvc-dynamic-runtime.patch - cd ..\.. diff --git a/dist/win/installer.qbs b/dist/win/installer.qbs index 13b16254b6..7119f9b645 100644 --- a/dist/win/installer.qbs +++ b/dist/win/installer.qbs @@ -60,9 +60,7 @@ WindowsInstallerPackage { defs.push("RpMap"); var imageFormatsPath = FileInfo.joinPaths(Qt.core.pluginPath, "imageformats") - if (File.exists(FileInfo.joinPaths(imageFormatsPath, "libqaseprite.dll"))) - defs.push("AsepriteImageFormatPlugin=libqaseprite.dll"); - else if (File.exists(FileInfo.joinPaths(imageFormatsPath, "qaseprite.dll"))) + if (File.exists(FileInfo.joinPaths(imageFormatsPath, "qaseprite.dll"))) defs.push("AsepriteImageFormatPlugin=qaseprite.dll"); // Since Qt 6.2 we rely on the schannel backend.