add support for integration tool app image in releases#213
add support for integration tool app image in releases#213MatPoliquin wants to merge 2 commits intomasterfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds support for building a Linux AppImage for the Gym Retro Integration UI tool as part of the release workflow. The AppImage can be built on pull requests, manual dispatches, or during releases, and is automatically attached to GitHub releases.
Changes:
- Added a new
build_integration_linuxjob that builds the gym-retro-integration UI binary with Qt5 on ubuntu-20.04 - Configured the build to create an AppImage package using linuxdeploy and linuxdeploy-plugin-qt
- Set up artifact upload for integration-appimage and automatic attachment to GitHub releases
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| env: | ||
| QMAKE: /usr/lib/qt5/bin/qmake | ||
| run: | | ||
| wget -q https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage | ||
| wget -q https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage | ||
| chmod +x linuxdeploy-x86_64.AppImage linuxdeploy-plugin-qt-x86_64.AppImage | ||
|
|
There was a problem hiding this comment.
The QMAKE environment variable path may be incorrect for ubuntu-20.04. The typical path for qmake on Ubuntu is /usr/lib/x86_64-linux-gnu/qt5/bin/qmake or /usr/bin/qmake depending on how Qt5 is installed. The path /usr/lib/qt5/bin/qmake may not exist on ubuntu-20.04. Consider using which qmake to dynamically find qmake, or verify the correct path for Qt5 on ubuntu-20.04.
| env: | |
| QMAKE: /usr/lib/qt5/bin/qmake | |
| run: | | |
| wget -q https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage | |
| wget -q https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage | |
| chmod +x linuxdeploy-x86_64.AppImage linuxdeploy-plugin-qt-x86_64.AppImage | |
| run: | | |
| wget -q https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage | |
| wget -q https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage | |
| chmod +x linuxdeploy-x86_64.AppImage linuxdeploy-plugin-qt-x86_64.AppImage | |
| # Determine qmake path dynamically for ubuntu-20.04 and similar | |
| QMAKE_PATH="$(command -v qmake || echo /usr/lib/x86_64-linux-gnu/qt5/bin/qmake)" | |
| export QMAKE="$QMAKE_PATH" |
| cp build-integration/gym-retro-integration AppDir/usr/bin/ | ||
| cp build-integration/stable_retro/cores/*_libretro.so AppDir/usr/bin/stable_retro/cores/ | ||
| cp build-integration/stable_retro/cores/*.json AppDir/usr/bin/stable_retro/cores/ | ||
| cp src/ui/logo.ico AppDir/usr/share/icons/hicolor/256x256/apps/stable-retro-integration.ico |
There was a problem hiding this comment.
The .ico file format is not the standard for Linux desktop icons. The freedesktop.org Desktop Entry Specification and Linux packaging tools expect PNG or SVG format icons. The linuxdeploy tool may not properly handle .ico files. Consider either: (1) converting logo.ico to PNG format before copying, or (2) using a tool like ImageMagick to convert it during the build. The Icon field in the desktop file (line 108) should reference the base name without extension, which would work correctly if the file is converted to PNG.
|
|
||
| - name: Rename AppImage | ||
| run: | | ||
| VERSION="${GITHUB_REF_NAME#v}" |
There was a problem hiding this comment.
The GITHUB_REF_NAME variable will be empty or have unexpected values when this workflow runs on pull requests or workflow_dispatch events (which are allowed by the if condition on line 57). This will result in a malformed filename like "stable-retro-integration--x86_64.AppImage" with a double dash. Consider providing a fallback version (e.g., using git describe or a default value) for non-release builds, or separate the artifact naming logic from the release-specific naming.
| VERSION="${GITHUB_REF_NAME#v}" | |
| VERSION="${GITHUB_REF_NAME#v}" | |
| if [ -z "$VERSION" ]; then | |
| VERSION="dev" | |
| fi |
No description provided.