Skip to content

Commit

Permalink
ci: add ubuntu-noble
Browse files Browse the repository at this point in the history
  • Loading branch information
sithlord48 committed Feb 16, 2025
1 parent 6366e52 commit b82e856
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 28 deletions.
64 changes: 37 additions & 27 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ on:
env:
QtVersion: 6.8.2
QtKey: "6.8.2"
PackageGLOB: "Black_Chocobo-*.*"
BuildType: Release
cmakeConfigure: "cmake -S. -Bbuild -DQT_DEFAULT_MAJOR_VERSION=6 -DCMAKE_BUILD_TYPE=Release"
debianRequirments: "build-essential git zlib1g-dev cmake qt6-tools-dev qt6-tools-dev-tools qt6-l10n-tools qt6-declarative-dev qt6-base-dev libqt6svg6-dev qt6-base-dev-tools qt6-translations-l10n libqt6core5compat6-dev libgl1-mesa-dev rename wget curl devscripts"
Expand Down Expand Up @@ -55,6 +54,14 @@ jobs:
os: ubuntu-22.04-arm
debArch: aarch64

- name: noble
os: ubuntu-24.04
debArch: x86_64

- name: noble
os: ubuntu-24.04-arm
debArch: aarch64

steps:
- name: Checkout
uses: sithlord48/[email protected]
Expand Down Expand Up @@ -91,7 +98,7 @@ jobs:
, os: ubuntu-22.04
, QT_INST_DIR: /opt
, ff7tkPrefix: /opt/ff7tk
, ff7tkPackage: ff7tk-continuous-linux_X86_64.tar.gz
, ff7tkPackage: ff7tk-continuous-linux_x86_64.tar.gz
, install_ff7tk: "sudo tar -xf ff7tk-continuous-linux_x86_64.tar.gz --one-top-level=/opt/ff7tk"
, extraCMakeConfig: "-DCMAKE_INSTALL_PREFIX=/usr"
, installBC: ""
Expand Down Expand Up @@ -155,40 +162,43 @@ jobs:
if: runner.os == 'Linux'
run: echo /opt/ff7tk/lib | sudo tee /etc/ld.so.conf.d/ff7tk.conf


- name: Configure
run: cmake -S. -DQT_DEFAULT_MAJOR_VERSION=6 -DCMAKE_BUILD_TYPE=Release -DCPACK_PACKAGE_LABEL="${{env.BCVersion}}" -Dff7tk_DIR=${{matrix.config.ff7tkPrefix}}/lib/cmake/ff7tk ${{matrix.config.extraCMakeConfig}}

- name: Build Black_Chocobo
id: main_build
shell: bash
run: |
cmake -S. -DQT_DEFAULT_MAJOR_VERSION=6 -DCMAKE_BUILD_TYPE=Release -DCPACK_PACKAGE_VERSION="${{env.BCVersion}}" -Dff7tk_DIR=${{matrix.config.ff7tkPrefix}}/lib/cmake/ff7tk ${{matrix.config.extraCMakeConfig}}
cmake --build . --config ${{env.BuildType}} --target package
- name: Build AppImage (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update -y > /dev/null
sudo apt-get install -qqq libxkbcommon-x11-0 libxcb-cursor0 > /dev/null
make DESTDIR=appdir install
wget -qc "https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage"
wget -qc "https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage"
chmod a+x linuxdeploy*.AppImage
export VERSION="${{env.BCVersion}}"
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${{ matrix.config.ff7tkPrefix }}/lib
export PATH=$PATH:/opt/Qt/${{env.QtVersion}}/gcc_64/libexec
mkdir -p ./appdir/usr/share/ff7tk/translations
mkdir -p ./appdir/usr/plugins/iconengines
cp /opt/Qt/${{ env.QtVersion }}/gcc_64/plugins/iconengines/libqsvgicon.so ./appdir/usr/plugins/iconengines/libqsvgicon.so
cp ${{matrix.config.ff7tkPrefix}}/share/ff7tk/translations/*.qm ./appdir/usr/share/ff7tk/translations
./linuxdeploy-x86_64.AppImage --appdir=appdir --output appimage \
-e src/blackchocobo \
-d deploy/io.github.sithlord48.blackchocobo.desktop \
-i deploy/blackchocobo.png \
--plugin=qt
if [[ "${{github.runner.os}}" != "linux" ]]; then
cmake --build . --config ${{env.BuildType}} --target package
else
sudo apt-get update -y > /dev/null
sudo apt-get install -qqq libxkbcommon-x11-0 libxcb-cursor0 > /dev/null
make DESTDIR=appdir install
wget -qc "https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage"
wget -qc "https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage"
chmod a+x linuxdeploy*.AppImage
export VERSION="${{env.BCVersion}}"
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${{ matrix.config.ff7tkPrefix }}/lib
export PATH=$PATH:/opt/Qt/${{env.QtVersion}}/gcc_64/libexec
mkdir -p ./appdir/usr/share/ff7tk/translations
mkdir -p ./appdir/usr/plugins/iconengines
cp /opt/Qt/${{ env.QtVersion }}/gcc_64/plugins/iconengines/libqsvgicon.so ./appdir/usr/plugins/iconengines/libqsvgicon.so
cp ${{matrix.config.ff7tkPrefix}}/share/ff7tk/translations/*.qm ./appdir/usr/share/ff7tk/translations
./linuxdeploy-x86_64.AppImage --appdir=appdir --output appimage \
-e src/blackchocobo \
-d deploy/io.github.sithlord48.blackchocobo.desktop \
-i deploy/blackchocobo.png \
--plugin=qt
fi
- name: Upload
uses: actions/upload-artifact@v4
with:
name: artifact-${{matrix.config.name}}
path: |
${{github.workspace}}/${{env.PackageGLOB}}
${{github.workspace}}/Black_Chocobo-*.*
${{github.workspace}}/blackchocobo[-_]*.*
release_assets:
Expand Down
3 changes: 2 additions & 1 deletion deploy/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -117,14 +117,15 @@ endif()
SET_OS_INFO()
set(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${PACKAGE_VERSION_LABEL}-${OS_STRING}")

set(CPACK_DEBIAN_FILE_NAME "blackchocobo-${PACKAGE_VERSION_LABEL}-${OS_STRING}")
set(CPACK_DEBIAN_PACKAGE_NAME "blackchocobo")
set(CPACK_DEBIAN_PACKAGE_MAINTAINER "[email protected]")
set(CPACK_DEBIAN_PACKAGE_DEPENDS "libff7tk (>= ${REQUIRED_FF7TK_VERSION}) | libff7tk-all (>=${REQUIRED_FF7TK_VERSION}), qt6-qpa-plugins")
set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS ON)

if(CMAKE_SYSTEM_NAME MATCHES "Linux")
#install generic files needed for linux package
set(CPACK_GENERATOR "TXZ")
set(CPACK_GENERATOR "TGZ")
EXECUTE_PROCESS( COMMAND uname -m COMMAND tr -d '\n' OUTPUT_VARIABLE ARCHITECTURE)
elseif(CMAKE_SYSTEM_NAME MATCHES "Windows")
set(CPACK_PACKAGE_INSTALL_DIRECTORY "Black_Chocobo")
Expand Down

0 comments on commit b82e856

Please sign in to comment.