Skip to content

9dbc01db13cb9ac87c495432af4a16d328918b8c #728

9dbc01db13cb9ac87c495432af4a16d328918b8c

9dbc01db13cb9ac87c495432af4a16d328918b8c #728

Workflow file for this run

name: Build Cemu
on:
push:
workflow_call:
inputs:
deploymode:
required: false
type: string
env:
VCPKG_ROOT: "${{github.workspace}}/dependencies/vcpkg"
VCPKG_BINARY_SOURCES: 'clear;nuget,GitHub,readwrite'
jobs:
build-ubuntu:
strategy:
fail-fast: false
matrix:
compiler: [clang++-12] # [g++-11, clang++-12] # [g++-11] #
build: [Release] # [Release,Debug]
include:
#- compiler: g++-11
# cc: gcc-11
# deb: gcc-11 g++-11
- compiler: clang++-12
cc: clang-12
deb: clang-12
name: Build Ubuntu ${{ matrix.build }}
runs-on: ubuntu-20.04
env:
CACHEDIR: ~/.ccache
steps:
- name: Checkout Upstream Repo
uses: actions/checkout@v3
with:
repository: SSimco/Cemu
ref: 9dbc01db13cb9ac87c495432af4a16d328918b8c
submodules: recursive
- name: Checkout AppImage Repo
uses: actions/checkout@v3
with:
clean: false
path: ci
- name: cache
uses: actions/cache@v3
with:
path: |
~/.ccache
key: build-${{github.run_id}}
restore-keys: |
build
- name: Setup release mode parameters (for deploy)
#if: ${{ inputs.deploymode == 'release' }}
run: |
echo "BUILD_MODE=${{ matrix.build }}" >> $GITHUB_ENV
echo "BUILD_FLAGS=" >> $GITHUB_ENV
echo "Build mode is release"
- name: "Install system dependencies"
run: |
sudo apt update -qq
sudo apt install -y ccache apksigner zipalign
- uses: actions/setup-java@v3
with:
distribution: 'oracle'
java-version: '17'
- name: "Fetch full history for vcpkg submodule"
run: |
cd dependencies/vcpkg
git fetch --unshallow
git pull --all
- name: "Create cache dir"
run: |
if [[ ! -e ${{ env.CACHEDIR }} ]]; then mkdir ${{ env.CACHEDIR }}; fi
ls -al ${{ env.CACHEDIR }}
- name: Fixes (Android)
run: |
echo "Android Fixes"
#sed -i 's|Exec=cemu|Exec=Cemu|g' dist/linux/info.cemu.Cemu.desktop ## wayland build
#git apply ci/scripts/xdg.patch
#sed -i 40,43d src/CMakeLists.txt
- name: "Bootstrap vcpkg"
run: |
bash ./dependencies/vcpkg/bootstrap-vcpkg.sh
- name: 'Setup NuGet Credentials for vcpkg'
shell: 'bash'
run: |
mono `./dependencies/vcpkg/vcpkg fetch nuget | tail -n 1` \
sources add \
-source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json" \
-storepasswordincleartext \
-name "GitHub" \
-username "${{ github.repository_owner }}" \
-password "${{ secrets.GITHUB_TOKEN }}"
mono `./dependencies/vcpkg/vcpkg fetch nuget | tail -n 1` \
setapikey "${{ secrets.GITHUB_TOKEN }}" \
-source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json"
- name: "Build Cemu"
run: |
cd src/android
chmod +x ./gradlew
./gradlew assembleRelease
- name: "Prepare artifact"
run: |
if [ ! -z ${{ secrets.SECRETS_FILE_CONTENTS }} ]; then
echo "Secrets file valid"
fi
cd src/android
base64 --decode <<< "${{ secrets.SECRETS_FILE_CONTENTS }}" > ks.jks
mkdir -p ${{ github.workspace }}/artifacts
cp ./app/build/outputs/apk/release/app-release-unsigned.apk ${{ github.workspace }}/artifacts/cemu-release.apk
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: cemu-android
path: |
artifacts