Build chiaki-ng weekly #58
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build chiaki-ng weekly | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "30 1 * * 1" | |
jobs: | |
create-release: | |
name: Upload weekly release | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.ref }} | |
- name: generate release notes | |
working-directory: ${{ github.workspace }} | |
run: | | |
echo -e "Weekly Test Build\n" > release_notes.md | |
- uses: ncipollo/release-action@v1 | |
id: maker | |
with: | |
prerelease: true | |
commit: ${{ github.sha }} | |
tag: weekly-canary-release-${{ github.sha }} | |
allowUpdates: true | |
bodyFile: "${{ github.workspace }}/release_notes.md" | |
token: "${{ secrets.RELEASE_PAT }}" | |
- uses: sgpublic/delete-release-action@v1.2 | |
with: | |
repo: 'streetpea/chiaki-ng' | |
release-drop: false | |
pre-release-drop: true | |
pre-release-keep-count: 1 | |
pre-release-drop-tag: true | |
draft-drop: false | |
env: | |
GITHUB_TOKEN: ${{ github.token }} | |
outputs: | |
upload_url: ${{ steps.maker.outputs.upload_url }} | |
build-win_x64: | |
name: Build chiaki-ng win_x64 (VC) | |
runs-on: windows-latest | |
permissions: | |
contents: write | |
needs: create-release | |
env: | |
CC: clang-cl.exe | |
CXX: clang-cl.exe | |
VULKAN_SDK: C:\VulkanSDK\ | |
triplet: x64-windows | |
vcpkg_baseline: 42bb0d9e8d4cf33485afb9ee2229150f79f61a1f | |
dep_folder: deps | |
libplacebo_tag: v7.349.0 | |
defaults: | |
run: | |
shell: powershell | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
- name: Set vcpkg installed dir | |
run: | | |
echo "VCPKG_INSTALLED_DIR=${{ github.workspace }}\build\vcpkg_installed" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
- name: Setup Vulkan | |
run: | | |
$ProgressPreference = 'SilentlyContinue' | |
$ver = (Invoke-WebRequest -Uri "https://vulkan.lunarg.com/sdk/latest.json" | ConvertFrom-Json).windows | |
echo Version $ver | |
Invoke-WebRequest -Uri "https://sdk.lunarg.com/sdk/download/$ver/windows/vulkansdk-windows-X64-$ver.exe" -OutFile VulkanSDK.exe | |
echo Downloaded | |
.\VulkanSDK.exe --root ${{ env.VULKAN_SDK }} --accept-licenses --default-answer --confirm-command install | |
- name: Set up Ninja | |
run: choco install ninja | |
- name: Set up Clang | |
uses: egor-tensin/setup-clang@v1 | |
with: | |
version: 18 | |
- name: Setup MSVC | |
uses: ilammy/msvc-dev-cmd@v1 | |
- name: Setup Qt | |
uses: jurplel/install-qt-action@v4 | |
with: | |
version: "6.8.*" | |
host: 'windows' | |
target: 'desktop' | |
modules: 'qtwebengine qtpositioning qtwebchannel qtwebsockets qtserialport' | |
- name: Install pip dependencies | |
run: | | |
${{ env.pythonLocation }}\python.exe -m pip install --upgrade pip | |
${{ env.pythonLocation }}\python.exe -m pip install --upgrade setuptools wheel | |
${{ env.pythonLocation }}\python.exe -m pip install --user --upgrade scons protobuf grpcio-tools pyinstaller | |
${{ env.pythonLocation }}\python.exe -m pip install --user --upgrade meson | |
${{ env.pythonLocation }}\python.exe -c 'import google.protobuf; print(google.protobuf.__file__)' | |
- name: Setup ffmpeg | |
run: | | |
$ProgressPreference = 'SilentlyContinue' | |
Invoke-WebRequest -UseBasicParsing -Uri "https://github.com/streetpea/FFmpeg-Builds/releases/download/latest/ffmpeg-n7.1-latest-win64-gpl-shared-7.1.zip" -OutFile ".\ffmpeg-n7.1-latest-win64-gpl-shared-7.1.zip" | |
Expand-Archive -LiteralPath "ffmpeg-n7.1-latest-win64-gpl-shared-7.1.zip" -DestinationPath "." | |
Rename-Item "ffmpeg-n7.1-latest-win64-gpl-shared-7.1" "${{ env.dep_folder }}" | |
- name: Build SPIRV-Cross | |
run: | | |
git clone https://github.com/KhronosGroup/SPIRV-Cross.git | |
cd SPIRV-Cross | |
cmake ` | |
-DCMAKE_BUILD_TYPE=Release ` | |
-DCMAKE_INSTALL_PREFIX="${{ github.workspace }}\${{ env.dep_folder }}" ` | |
-DSPIRV_CROSS_SHARED=ON ` | |
-S . ` | |
-B build ` | |
-G Ninja | |
cmake --build build --config Release | |
cmake --install build | |
- name: Setup shaderc | |
run: | | |
$ProgressPreference = 'SilentlyContinue' | |
$url = ((Invoke-WebRequest -UseBasicParsing -Uri "https://storage.googleapis.com/shaderc/badges/build_link_windows_vs2019_release.html").Content | Select-String -Pattern 'url=(.*)"').Matches.Groups[1].Value | |
Invoke-WebRequest -UseBasicParsing -Uri $url -OutFile .\shaderc.zip | |
Expand-Archive -LiteralPath "shaderc.zip" -DestinationPath "." | |
cp "./install/*" "./${{ env.dep_folder }}" -Force -Recurse | |
rm "./install" -r -force | |
- name: Setup vcpkg | |
uses: lukka/run-vcpkg@v11 | |
with: | |
vcpkgGitCommitId: ${{ env.vcpkg_baseline }} | |
runVcpkgInstall: true | |
vcpkgJsonGlob: "vcpkg.json" | |
- name: Build libplacebo | |
run: | | |
git clone --recursive https://github.com/haasn/libplacebo.git | |
cd libplacebo | |
git checkout --recurse-submodules ${{ env.libplacebo_tag }} | |
meson setup ` | |
--prefix "${{ github.workspace }}\${{ env.dep_folder }}" ` | |
--native-file ../meson.ini ` | |
"--pkg-config-path=['${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\lib\pkgconfig','${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\share\pkgconfig','${{ github.workspace }}\${{ env.dep_folder }}\lib\pkgconfig']" ` | |
"--cmake-prefix-path=['${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}', '${{ env.VULKAN_SDK }}', '${{ github.workspace }}\${{ env.dep_folder }}']" ` | |
-Dc_args="/I ${{ env.VULKAN_SDK }}Include" ` | |
-Dcpp_args="/I ${{ env.VULKAN_SDK }}Include" ` | |
-Dc_link_args="/LIBPATH:${{ env.VULKAN_SDK }}Lib" ` | |
-Dcpp_link_args="/LIBPATH:${{ env.VULKAN_SDK }}Lib" ` | |
-Ddemos=false ` | |
./build | |
ninja -C./build | |
ninja -C./build install | |
- name: Apply Patches | |
run: | | |
git apply --ignore-whitespace --verbose --directory=third-party/gf-complete/ scripts/windows-vc/gf-complete.patch | |
- name: Configure chiaki-ng | |
run: | | |
cmake ` | |
-S . ` | |
-B build ` | |
-G Ninja ` | |
-DCMAKE_TOOLCHAIN_FILE:STRING="vcpkg/scripts/buildsystems/vcpkg.cmake" ` | |
-DCMAKE_EXPORT_COMPILE_COMMANDS:BOOL=TRUE ` | |
-DCMAKE_BUILD_TYPE=Release ` | |
-DCHIAKI_ENABLE_CLI=OFF ` | |
-DCHIAKI_GUI_ENABLE_SDL_GAMECONTROLLER=ON ` | |
-DCHIAKI_ENABLE_STEAMDECK_NATIVE=OFF ` | |
-DPYTHON_EXECUTABLE="${{ env.pythonLocation }}\python.exe" ` | |
-DCMAKE_PREFIX_PATH="${{ github.workspace }}\${{ env.dep_folder }};${{ env.VULKAN_SDK }}" | |
- name: Build chiaki-ng | |
run: | | |
cmake --build build --config Release --clean-first --target chiaki | |
- name: Prepare Qt deployment package | |
run: | | |
mkdir chiaki-ng-Win | |
cp build\gui\chiaki.exe chiaki-ng-Win | |
cp build\third-party\cpp-steam-tools\cpp-steam-tools.dll chiaki-ng-Win | |
cp scripts\qtwebengine_import.qml gui\src\qml\ | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\libcrypto-*-x64.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\libssl-*-x64.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\SDL2.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\hidapi.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\fftw3.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\opus.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\libspeexdsp.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\lcms2.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\miniupnpc.dll" chiaki-ng-Win | |
cp "${env:VCPKG_INSTALLED_DIR}\${{ env.triplet }}\bin\json-c.dll" chiaki-ng-Win | |
cp "${{ github.workspace }}\${{ env.dep_folder }}\bin\swresample-*.dll" chiaki-ng-Win | |
cp "${{ github.workspace }}\${{ env.dep_folder }}\bin\avcodec-*.dll" chiaki-ng-Win | |
cp "${{ github.workspace }}\${{ env.dep_folder }}\bin\avutil-*.dll" chiaki-ng-Win | |
cp "${{ github.workspace }}\${{ env.dep_folder }}\bin\avformat-*.dll" chiaki-ng-Win | |
cp "${{ github.workspace }}\${{ env.dep_folder }}\bin\libplacebo-*.dll" chiaki-ng-Win | |
cp "${{ github.workspace }}\${{ env.dep_folder }}\bin\shaderc_shared.dll" chiaki-ng-Win | |
cp "${{ github.workspace }}\${{ env.dep_folder }}\bin\spirv-cross-c-shared.dll" chiaki-ng-Win | |
windeployqt.exe --no-translations --qmldir=gui\src\qml --release chiaki-ng-Win\chiaki.exe | |
- name: Package chiaki-ng | |
run: | | |
$CHIAKI_VERSION_MAJOR = (Select-String -Path .\CMakeLists.txt -Pattern 'set\(CHIAKI_VERSION_MAJOR ([0-9]+)\)') | %{$_.Matches.Groups[1].value} | |
$CHIAKI_VERSION_MINOR = (Select-String -Path .\CMakeLists.txt -Pattern 'set\(CHIAKI_VERSION_MINOR ([0-9]+)\)') | %{$_.Matches.Groups[1].value} | |
$CHIAKI_VERSION_PATCH = (Select-String -Path .\CMakeLists.txt -Pattern 'set\(CHIAKI_VERSION_PATCH ([0-9]+)\)') | %{$_.Matches.Groups[1].value} | |
$RELEASE_PACKAGE_FILE = "chiaki-ng-win_x64-VC-portable-$CHIAKI_VERSION_MAJOR.$CHIAKI_VERSION_MINOR.$CHIAKI_VERSION_PATCH-test-build-${{ github.sha }}.zip" | |
Compress-Archive chiaki-ng-Win $RELEASE_PACKAGE_FILE | |
$release_filepath = Get-ChildItem $RELEASE_PACKAGE_FILE | %{$_[0].FullName} | |
echo "RELEASE_PACKAGE_PATH=$release_filepath" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: ${{ env.RELEASE_PACKAGE_PATH }} | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
- name: Compile .ISS to .EXE Installer | |
uses: Minionguyjpro/Inno-Setup-Action@v1.2.2 | |
with: | |
path: "scripts/chiaki-ng.iss" | |
options: /O+ | |
- name: Rename installer | |
run: | | |
cp chiaki-ng-windows-installer.exe chiaki-ng-win_x64-VC-installer.exe | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: chiaki-ng-win_x64-VC-installer.exe | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
build-windows_arm64-msys2: | |
name: Build windows msys2 arm version | |
runs-on: windows-11-arm | |
permissions: | |
contents: write | |
needs: create-release | |
defaults: | |
run: | |
shell: msys2 {0} | |
steps: | |
- name: Disable autocrlf | |
shell: pwsh | |
run: | | |
git config --global core.autocrlf false | |
git config --global core.eol lf | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- uses: msys2/setup-msys2@v2 | |
with: | |
msystem: clangarm64 | |
update: true | |
install: git | |
pacboy: >- | |
ca-certificates:p | |
cc:p | |
cmake:p | |
curl:p | |
diffutils:p | |
fast_float:p | |
fftw:p | |
hidapi:p | |
json-c:p | |
lcms2:p | |
libdovi:p | |
meson:p | |
miniupnpc:p | |
gcc:p | |
nasm:p | |
ninja:p | |
openssl:p | |
opus:p | |
pkgconf:p | |
protobuf:p | |
python:p | |
python-psutil:p | |
python-glad:p | |
python-jinja:p | |
python-pip:p | |
qt6-base:p | |
qt6-declarative:p | |
qt6-svg:p | |
SDL2:p | |
shaderc:p | |
speexdsp:p | |
spirv-cross:p | |
vulkan:p | |
vulkan-headers:p | |
- name: Install python protobuf and zip | |
run: | | |
pip install protobuf | |
pacman -S git make unzip zip --noconfirm | |
- name: Build libbplacebo | |
run: | | |
scripts/build-libplacebo-windows-arm.sh | |
- name: Setup ffmpeg | |
run: | | |
curl -LO https://github.com/streetpea/FFmpeg-Builds/releases/download/latest/ffmpeg-n7.1-latest-winarm64-gpl-shared-7.1.zip | |
unzip ffmpeg-n7.1-latest-winarm64-gpl-shared-7.1.zip | |
cp -a "ffmpeg-n7.1-latest-winarm64-gpl-shared-7.1/bin/." /clangarm64/bin | |
cp -a "ffmpeg-n7.1-latest-winarm64-gpl-shared-7.1/include/." /clangarm64/include | |
cp -a "ffmpeg-n7.1-latest-winarm64-gpl-shared-7.1/lib/." /clangarm64/lib | |
- name: Configure chiaki-ng | |
run: | | |
cmake -S . -B build -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCHIAKI_ENABLE_CLI=OFF | |
- name: Build chiaki-ng | |
run: | | |
cmake --build build --config Release --clean-first --target chiaki | |
- name: Deploy chiaki-ng | |
run: | | |
mkdir chiaki-ng-Win | |
cp build/gui/chiaki.exe chiaki-ng-Win/ | |
export PATH="${{ github.workspace }}/build/third-party/cpp-steam-tools:/clangarm64/share/qt6/bin/:${PATH}" | |
export QT_PLUGIN_PATH="/clangarm64/share/qt6/plugins" | |
export QML2_IMPORT_PATH="/clangarm64/share/qt6/qml" | |
echo chiaki-ng-Win/chiaki.exe > tmp0.txt | |
while [ -e tmp0.txt ] | |
do | |
cp tmp0.txt tmp.txt | |
rm tmp0.txt | |
sort -u tmp.txt -o tmp.txt | |
ldd $(<tmp.txt) | grep -v ":" | cut -d " " -f3 | grep -iv "system32" | grep -iv "not" | xargs -d $'\n' sh -c 'for arg do if [ -n "$arg" ] && [ ! -e "chiaki-ng-Win/${arg##*/}" ]; then echo "Copied $arg"; cp "$arg" chiaki-ng-Win/ ; echo "$arg" >> tmp0.txt; fi; done' | |
done | |
windeployqt6.exe --no-translations --qmldir=gui/src/qml chiaki-ng-Win/chiaki.exe | |
- name: Package chiaki-ng | |
run: | | |
CHIAKI_VERSION_MAJOR="$(grep 'CHIAKI_VERSION_MAJOR' CMakeLists.txt | grep -Eo '[0-9]')" | |
CHIAKI_VERSION_MINOR="$(grep 'CHIAKI_VERSION_MINOR' CMakeLists.txt | grep -Eo '[0-9]')" | |
CHIAKI_VERSION_PATCH="$(grep 'CHIAKI_VERSION_PATCH' CMakeLists.txt | grep -Eo '[0-9]')" | |
RELEASE_PACKAGE_FILE="chiaki-ng-win_arm64-MSYS2-portable-$CHIAKI_VERSION_MAJOR.$CHIAKI_VERSION_MINOR.$CHIAKI_VERSION_PATCH-test-build-${{ github.sha }}.zip" | |
zip -r $RELEASE_PACKAGE_FILE chiaki-ng-Win | |
echo "RELEASE_PACKAGE_PATH=${RELEASE_PACKAGE_FILE}" >> $GITHUB_ENV | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: ${{ env.RELEASE_PACKAGE_PATH }} | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
- name: Compile .ISS to .EXE Installer | |
uses: Minionguyjpro/Inno-Setup-Action@v1.2.2 | |
with: | |
path: "scripts/chiaki-ng.iss" | |
options: /O+ | |
- name: Rename installer | |
run: | | |
cp chiaki-ng-windows-installer.exe chiaki-ng-win_arm64-MSYS2-installer.exe | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: chiaki-ng-win_arm64-MSYS2-installer.exe | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
build-mac_arm64_github: | |
name: Build macOSX arm64 version Github | |
runs-on: macos-14 | |
permissions: | |
contents: write | |
needs: create-release | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Install protobuf | |
run: | | |
pip3 install --user 'protobuf>=5,<6' --break-system-packages | |
- name: Install brew dependencies | |
run: | | |
brew update | |
brew uninstall pkgconfig || true | |
brew install streetpea/streetpea/chiaki-ng-qt@6 ffmpeg pkgconfig opus openssl cmake ninja nasm sdl2 protobuf@29 speexdsp libplacebo wget python-setuptools json-c miniupnpc | |
- name: Configure chiaki-ng | |
run: | | |
cmake -S . -B build -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCHIAKI_ENABLE_CLI=OFF -DCHIAKI_ENABLE_STEAMDECK_NATIVE=OFF -DCMAKE_PREFIX_PATH="$(brew --prefix)/opt/@openssl@3;$(brew --prefix)/opt/chiaki-ng-qt@6;$(brew --prefix)/opt/protobuf@29" | |
- name: Build chiaki-ng | |
run: | | |
export CPATH=$(brew --prefix)/opt/ffmpeg/include | |
cmake --build build --config Release --clean-first --target chiaki | |
- name: Deploy chiaki-ng | |
run: | | |
cp -a build/gui/chiaki.app chiaki-ng.app | |
cp scripts/qtwebengine_import.qml gui/src/qml/ | |
$(brew --prefix)/opt/chiaki-ng-qt@6/bin/macdeployqt chiaki-ng.app -qmldir="$PWD/gui/src/qml" -libpath=$(brew --prefix)/lib | |
mkdir -p chiaki-ng.app/Contents/Resources/vulkan/icd.d | |
wget https://github.com/KhronosGroup/MoltenVK/releases/download/v1.2.11-artifacts/MoltenVK-macos.tar && tar xf MoltenVK-macos.tar | |
cp MoltenVK/MoltenVK/dylib/macOS/* chiaki-ng.app/Contents/Resources/vulkan/icd.d | |
$(brew --prefix)/opt/chiaki-ng-qt@6/bin/macdeployqt chiaki-ng.app -qmldir="$PWD/gui/src/qml" -libpath=$(brew --prefix)/lib | |
ln -s ../../../../../../../Frameworks chiaki-ng.app/Contents/Frameworks/QtWebEngineCore.framework/Helpers/QtWebEngineProcess.app/Contents | |
ln -s libvulkan.1.dylib chiaki-ng.app/Contents/Frameworks/vulkan | |
codesign --force --entitlements gui/entitlements.xml --deep --sign - chiaki-ng.app | |
hdiutil create -srcfolder chiaki-ng.app chiaki-ng.dmg | |
codesign --force --entitlements gui/entitlements.xml --deep --sign - chiaki-ng.dmg | |
cp chiaki-ng.dmg chiaki-ng-macos_arm64-Release.dmg | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: | | |
chiaki-ng-macos_arm64-Release.dmg | |
if-no-files-found: error | |
upload-release-files: true | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
build-appimage_x64: | |
name: Build chiaki-ng appimage_x64 | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
needs: create-release | |
steps: | |
- name: Setup Podman | |
run: | | |
sudo apt update | |
sudo apt-get -y install podman | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
path: 'chiaki-ng' | |
- name: Add QmlWebEngine Import | |
working-directory: chiaki-ng | |
run: | | |
cp scripts/qtwebengine_import.qml gui/src/qml/ | |
- name: Run build script | |
working-directory: chiaki-ng | |
run: | | |
set -xe | |
podman run --rm \ | |
-v "`pwd`:/build/chiaki" \ | |
-w "/build/chiaki" \ | |
--device /dev/fuse \ | |
--cap-add SYS_ADMIN \ | |
-t docker.io/streetpea/chiaki-ng-builder:qt6.9 \ | |
/bin/bash -c "sudo -E scripts/build-appimage.sh /build/appdir" | |
cp appimage/chiaki-ng.AppImage appimage/chiaki-ng.AppImage_x86_64 | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: | | |
chiaki-ng/appimage/chiaki-ng.AppImage_x86_64 | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
build-appimage_arm64: | |
name: Build chiaki-ng appimage_arm64 | |
runs-on: ubuntu-24.04-arm | |
permissions: | |
contents: write | |
needs: create-release | |
steps: | |
- name: Setup Podman | |
run: | | |
sudo apt update | |
sudo apt-get -y install podman | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
path: 'chiaki-ng' | |
- name: Add QmlWebEngine Import | |
working-directory: chiaki-ng | |
run: | | |
cp scripts/qtwebengine_import.qml gui/src/qml/ | |
- name: Run build script | |
working-directory: chiaki-ng | |
run: | | |
set -xe | |
podman run --rm \ | |
-v "`pwd`:/build/chiaki" \ | |
-w "/build/chiaki" \ | |
--device /dev/fuse \ | |
--cap-add SYS_ADMIN \ | |
-t docker.io/streetpea/chiaki-ng-builder:qt6.7 \ | |
/bin/bash -c "sudo -E scripts/build-appimage.sh /build/appdir" | |
cp appimage/chiaki-ng.AppImage appimage/chiaki-ng.AppImage_arm64 | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: | | |
chiaki-ng/appimage/chiaki-ng.AppImage_arm64 | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
build-switch_x64: | |
name: Build chiaki-ng switch_x64 | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
needs: create-release | |
steps: | |
- name: Setup Docker | |
run: | | |
sudo apt update | |
sudo apt-get -y install docker-ce-cli | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
path: 'chiaki-ng' | |
- name: Run build script | |
working-directory: chiaki-ng | |
run: | | |
chmod +x scripts/switch/run-docker-build-chiaki.sh | |
scripts/switch/run-docker-build-chiaki.sh | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: | | |
chiaki-ng/build_switch/switch/chiaki-ng.nro | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
build-flatpak_x64: | |
name: Build chiaki-ng flatpak bundle x64 | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
needs: create-release | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
path: 'chiaki-ng' | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y \ | |
git \ | |
flatpak \ | |
flatpak-builder | |
- name: Setup Flatpak Builder Environment | |
run: | | |
flatpak remote-add --user --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo | |
flatpak install org.kde.Sdk//6.8 -y | |
flatpak install org.kde.Platform//6.8 -y | |
flatpak install io.qt.qtwebengine.BaseApp//6.8 -y | |
flatpak update --appstream --assumeyes | |
- name: Build Flatpak package | |
working-directory: chiaki-ng | |
run: | | |
flatpak-builder --repo=chiaki-ng --force-clean build-dir scripts/flatpak/io.github.streetpea.Chiaki4deck.yaml | |
- name: Bundle Flatpak app | |
working-directory: chiaki-ng | |
run: | | |
flatpak build-bundle chiaki-ng chiaki-ng-x64.flatpak io.github.streetpea.Chiaki4deck --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo | |
flatpak build-bundle chiaki-ng --runtime chiaki-ng-x64-debug.flatpak io.github.streetpea.Chiaki4deck.Debug --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: | | |
chiaki-ng/chiaki-ng-x64.flatpak | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: | | |
chiaki-ng/chiaki-ng-x64-debug.flatpak | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
build-flatpak_arm64: | |
name: Build chiaki-ng flatpak bundle arm64 | |
runs-on: ubuntu-24.04-arm | |
permissions: | |
contents: write | |
needs: create-release | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
path: 'chiaki-ng' | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y \ | |
git \ | |
flatpak \ | |
flatpak-builder | |
- name: Setup Flatpak Builder Environment | |
run: | | |
flatpak remote-add --user --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo | |
flatpak install org.kde.Sdk//6.8 -y | |
flatpak install org.kde.Platform//6.8 -y | |
flatpak install io.qt.qtwebengine.BaseApp//6.8 -y | |
flatpak update --appstream --assumeyes | |
- name: Build Flatpak package | |
working-directory: chiaki-ng | |
run: | | |
flatpak-builder --repo=chiaki-ng --force-clean build-dir scripts/flatpak/io.github.streetpea.Chiaki4deck.yaml | |
- name: Bundle Flatpak app | |
working-directory: chiaki-ng | |
run: | | |
flatpak build-bundle chiaki-ng chiaki-ng-arm64.flatpak io.github.streetpea.Chiaki4deck --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo | |
flatpak build-bundle chiaki-ng --runtime chiaki-ng-arm64-debug.flatpak io.github.streetpea.Chiaki4deck.Debug --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: | | |
chiaki-ng/chiaki-ng-arm64.flatpak | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} | |
- name: Upload chiaki-ng Artifact | |
uses: nanoufo/action-upload-artifacts-and-release-assets@v2 | |
with: | |
path: | | |
chiaki-ng/chiaki-ng-arm64-debug.flatpak | |
upload-release-files: true | |
if-no-files-found: error | |
release-upload-url: ${{ needs.create-release.outputs.upload_url }} |