Skip to content

Commit

Permalink
testing appimage support
Browse files Browse the repository at this point in the history
  • Loading branch information
lambdcalculus committed Jul 5, 2024
1 parent a1e13f6 commit 5951910
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 3 deletions.
44 changes: 41 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ jobs:
submodules: recursive

- name: Install Qt
uses: jurplel/install-qt-action@v3
uses: jurplel/install-qt-action@v4
with:
aqtversion: '==3.1.*'
version: '6.5.3'
Expand Down Expand Up @@ -173,6 +173,9 @@ jobs:
cmake . -D CMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE="${{ github.workspace }}/bin/imageformats/"
cmake --build . --config Release
# install plugin
cp plugins/imageformats/libqapng.so ${QT_ROOT_DIR}/plugins/imageformats
- name: Build
run: |
cmake .
Expand All @@ -185,6 +188,7 @@ jobs:
mkdir ./imageformats
cp ../qtapng/plugins/imageformats/libqapng.so ./imageformats
cp ../scripts/launch.sh .
cp ../README_LINUX.md .
chmod +x launch.sh
chmod +x Attorney_Online
Expand All @@ -200,8 +204,42 @@ jobs:
rm ./bin/base/themes/.gitattributes
rm -r ./bin/base/themes/.git
- name: Upload Artifact
- name: Create AppImage
shell: bash
run: |
# necessary, apparently
sudo apt install libxcb-cursor0
# from https://github.com/probonopd/go-appimage/blob/master/src/appimagetool/README.md
wget -c https://github.com/$(wget -q https://github.com/probonopd/go-appimage/releases/expanded_assets/continuous -O - | grep "appimagetool-.*-x86_64.AppImage" | head -n 1 | cut -d '"' -f 2)
mv appimagetool-*-x86_64.AppImage appimagetool
chmod +x appimagetool
mkdir -p AppDir/usr/bin
mkdir -p AppDir/usr/lib/plugins/imageformats
mkdir -p AppDir/usr/share/applications
cp bin/Attorney_Online AppDir/usr/bin
cp bin/lib*.so AppDir/usr/lib
cp scripts/Attorney_Online.desktop AppDir/usr/share/applications
cp data/logo-client.png AppDir/Attorney_Online.png
QTDIR=${QT_ROOT_DIR} ./appimagetool deploy AppDir/usr/share/applications/Attorney_Online.desktop
ARCH=x86_64 VERSION=2.11 ./appimagetool AppDir
chmod +x Attorney_Online-*-x86_64.AppImage
mkdir bin-appimage
cp -r bin/base bin-appimage
cp Attorney_Online-*-x86_64.AppImage bin-appimage
cp README_LINUX.md bin-appimage
- name: Upload Dynamic Artifact
uses: actions/upload-artifact@master
with:
name: Attorney_Online-Linux
name: Attorney_Online-Linux-Dynamic
path: ${{github.workspace}}/bin

- name: Upload AppImage Artifact
uses: actions/upload-artifact@master
with:
name: Attorney_Online-Linux-AppImage
path: ${{github.workspace}}/bin-appimage
26 changes: 26 additions & 0 deletions README_LINUX.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
## Running on Linux

There are two download options for running on Linux: the **dynamically-linked** build and the **AppImage**. The dynamic build is lighter, but may not run on older systems. The AppImage is a bit bigger, but should seamlessly on most systems.

### AppImage

If you downloaded the **AppImage** version, it should just be plug-and-play. If you run into errors or bugs, contact us in our [Discord server](https://discord.gg/wWvQ3pw) or open an [issue on Github](https://github.com/AttorneyOnline/AO2-Client/issues).

### Dynamic

If you downloaded the **dynamically-linked** version, use the `launch.sh` script to run AO.

You may need to install some libraries in your system. These are the commands to run on a terminal for some distributions:

* Arch Linux:
```
$ sudo pacman -S qt6-base qt6-tools qt6-websockets qt6-imageformats
```
* Fedora:
```
$ sudo dnf install qt6-qtbase qt6-qttools qt6-qtwebsockets qt6-qtimageformats
```
* Ubuntu 22.04 LTS:
```
$ sudo apt-get install qt6base-dev libqt6uitools6 libqt6websockets6 qt6-image-formats-plugins
```
7 changes: 7 additions & 0 deletions scripts/Attorney_Online.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[Desktop Entry]
Type=Application
Name=Attorney Online
Comment=The courtroom drama simulator
Exec=Attorney_Online
Icon=Attorney_Online
Categories=Game;

0 comments on commit 5951910

Please sign in to comment.