let's try reusing the build for the AppImage
removes the need to build everything twice
This commit is contained in:
parent
ed27ab96af
commit
9976ed78b3
|
@ -1,57 +0,0 @@
|
||||||
name: AppImage
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
|
|
||||||
runs-on: ubuntu-22.04
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v1
|
|
||||||
- name: Install dependencies
|
|
||||||
run: |
|
|
||||||
sudo rm -f /etc/apt/sources.list.d/dotnetdev.list /etc/apt/sources.list.d/microsoft-prod.list
|
|
||||||
sudo apt update
|
|
||||||
sudo apt install cmake extra-cmake-modules libpcap0.8-dev libsdl2-dev qt6-{base,base-private,multimedia,tools}-dev qt6-qpa-plugins libslirp0 libslirp-dev libarchive-dev libzstd-dev --allow-downgrades libfuse2
|
|
||||||
- name: Create build environment
|
|
||||||
run: mkdir ${{runner.workspace}}/build
|
|
||||||
- name: Configure
|
|
||||||
working-directory: ${{runner.workspace}}/build
|
|
||||||
run: cmake $GITHUB_WORKSPACE -DUSE_QT6=ON
|
|
||||||
- name: Make
|
|
||||||
working-directory: ${{runner.workspace}}/build
|
|
||||||
run: |
|
|
||||||
make -j$(nproc --all)
|
|
||||||
- name: Prepare AppDir for AppImage
|
|
||||||
working-directory: ${{runner.workspace}}/build
|
|
||||||
run: |
|
|
||||||
make install DESTDIR=AppDir
|
|
||||||
mv ./AppDir/usr/local/bin ./AppDir/usr/bin
|
|
||||||
mv ./AppDir/usr/local/share ./AppDir/usr/share
|
|
||||||
rm -rf ./AppDir/usr/local
|
|
||||||
- name: Prepare necessary Tools for building the AppImage
|
|
||||||
working-directory: ${{runner.workspace}}/build
|
|
||||||
run: |
|
|
||||||
wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage
|
|
||||||
wget https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage
|
|
||||||
chmod a+x linuxdeploy-x86_64.AppImage
|
|
||||||
chmod a+x linuxdeploy-plugin-qt-x86_64.AppImage
|
|
||||||
- name: Build the AppImage
|
|
||||||
working-directory: ${{runner.workspace}}/build
|
|
||||||
env:
|
|
||||||
QMAKE: /usr/lib/qt6/bin/qmake
|
|
||||||
run: |
|
|
||||||
./linuxdeploy-x86_64.AppImage --appdir AppDir --plugin qt --output appimage
|
|
||||||
mkdir dist
|
|
||||||
cp ./melonDS*.AppImage ./dist
|
|
||||||
- uses: actions/upload-artifact@v1
|
|
||||||
with:
|
|
||||||
name: melonDS-appimage-x86_64
|
|
||||||
path: ${{runner.workspace}}/build/dist
|
|
|
@ -14,24 +14,56 @@ jobs:
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-22.04
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v3
|
||||||
|
name: Check out sources
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo rm -f /etc/apt/sources.list.d/dotnetdev.list /etc/apt/sources.list.d/microsoft-prod.list
|
sudo rm -f /etc/apt/sources.list.d/dotnetdev.list /etc/apt/sources.list.d/microsoft-prod.list
|
||||||
sudo apt update
|
sudo apt update
|
||||||
sudo apt install cmake extra-cmake-modules libpcap0.8-dev libsdl2-dev qt6-{base,base-private,multimedia}-dev libslirp0 libslirp-dev libarchive-dev libzstd-dev --allow-downgrades
|
sudo apt install --allow-downgrades cmake ninja-build extra-cmake-modules libpcap0.8-dev libsdl2-dev \
|
||||||
- name: Create build environment
|
qt6-{base,base-private,multimedia}-dev libslirp0 libslirp-dev libarchive-dev libzstd-dev --allow-downgrades
|
||||||
run: mkdir ${{runner.workspace}}/build
|
|
||||||
- name: Configure
|
- name: Configure
|
||||||
working-directory: ${{runner.workspace}}/build
|
run: cmake -B build -G Ninja -DUSE_QT6=ON -DCMAKE_INSTALL_PREFIX=/
|
||||||
run: cmake $GITHUB_WORKSPACE -DUSE_QT6=ON
|
- name: Build
|
||||||
- name: Make
|
|
||||||
working-directory: ${{runner.workspace}}/build
|
|
||||||
run: |
|
run: |
|
||||||
make -j$(nproc --all)
|
cmake --build build
|
||||||
mkdir dist
|
mkdir dist
|
||||||
cp melonDS dist
|
DESTDIR="$PWD/dist" cmake --install build
|
||||||
- uses: actions/upload-artifact@v1
|
- uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: melonDS-ubuntu-x86_64
|
name: melonDS-ubuntu-x86_64
|
||||||
path: ${{runner.workspace}}/build/dist
|
path: ${{runner.workspace}}/build/dist
|
||||||
|
|
||||||
|
appimage:
|
||||||
|
name: AppImage
|
||||||
|
runs-on: ubuntu-22.04
|
||||||
|
needs: [ build ]
|
||||||
|
continue-on-error: true
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
sudo apt update
|
||||||
|
sudo apt install --allow-downgrades \
|
||||||
|
libpcap0.8-dev libsdl2-dev qt6-{base,base-private,multimedia,tools}-dev qt6-qpa-plugins \
|
||||||
|
libslirp0 libarchive libzstd libfuse2
|
||||||
|
- name: Download build artifact
|
||||||
|
uses: actions/download-artifact@v4
|
||||||
|
with:
|
||||||
|
name: melonDS-ubuntu-x86_64
|
||||||
|
path: AppDir
|
||||||
|
- name: Prepare necessary Tools for building the AppImage
|
||||||
|
run: |
|
||||||
|
wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage
|
||||||
|
wget https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage
|
||||||
|
chmod a+x linuxdeploy-x86_64.AppImage
|
||||||
|
chmod a+x linuxdeploy-plugin-qt-x86_64.AppImage
|
||||||
|
- name: Build the AppImage
|
||||||
|
env:
|
||||||
|
QMAKE: /usr/lib/qt6/bin/qmake
|
||||||
|
run: |
|
||||||
|
./linuxdeploy-x86_64.AppImage --appdir AppDir --plugin qt --output appimage
|
||||||
|
- uses: actions/upload-artifact@v4
|
||||||
|
with:
|
||||||
|
name: melonDS-appimage-x86_64
|
||||||
|
path: melonDS*.AppImage
|
||||||
|
|
Loading…
Reference in New Issue