From 073250691bc1b458db1b8ce8a6375e98b1077ebd Mon Sep 17 00:00:00 2001 From: Escary <81011361+pflyly@users.noreply.github.com> Date: Tue, 10 Jun 2025 19:23:56 +0100 Subject: [PATCH 1/3] add ccache --- .github/workflows/appimage.yml | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/.github/workflows/appimage.yml b/.github/workflows/appimage.yml index c2b69a841ee7..dd8fc7118fe5 100644 --- a/.github/workflows/appimage.yml +++ b/.github/workflows/appimage.yml @@ -20,6 +20,7 @@ on: - 'Tools/**' - '.{editorconfig,gitattributes,gitignore}' - 'appveyor.yml' + workflow_dispatch: {} env: SDL_AUDIODRIVER: "dummy" #"disk" @@ -40,7 +41,10 @@ jobs: runs-on: ${{ matrix.os }} container: ghcr.io/pkgforge-dev/archlinux:latest - + env: + CCACHE_DIR: ${{ github.workspace }}/.ccache + CCACHE_COMPILERCHECK: content + CCACHE_SLOPPINESS: time_macros steps: - name: Install git run: pacman -Syu --noconfirm git @@ -65,11 +69,13 @@ jobs: git remote add upstream https://github.com/hrydgard/ppsspp.git # fetching from official repo as a fallback git fetch --deepen=15000 --no-recurse-submodules --tags upstream || exit 0 - #- name: Setup ccache # Doesn't support archlinux container? - # uses: hendrikmuhs/ccache-action@v1.2 - # with: - # key: "linux-appimage-${{ matrix.id }}" - # create-symlink: true + - name: Set up ccache for ${{ matrix.id }} + uses: actions/cache@v4.2.3 + with: + path: ${{ env.CCACHE_DIR }} + key: ${{ runner.os }}-ccache-${{ matrix.id }}-${{ github.sha }} + restore-keys: | + ${{ runner.os }}-ccache-${{ matrix.id }}- - name: Install dependencies shell: bash @@ -108,6 +114,7 @@ jobs: git \ cmake \ clang \ + ccache \ llvm-libs \ llvm \ lld \ @@ -178,7 +185,7 @@ jobs: #./b.sh --release --no-sdl2 --no-png mkdir -p build pushd build - cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DUSE_SYSTEM_LIBSDL2=OFF -DUSE_SYSTEM_LIBPNG=OFF -DUSE_SYSTEM_FFMPEG=OFF .. + cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DUSE_SYSTEM_LIBSDL2=OFF -DUSE_SYSTEM_LIBPNG=OFF -DUSE_SYSTEM_FFMPEG=OFF -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache .. make -j$(nproc) popd From b1927db527136d66c7ec91d9d163fc037ed57d8e Mon Sep 17 00:00:00 2001 From: Escary <81011361+pflyly@users.noreply.github.com> Date: Tue, 10 Jun 2025 19:40:03 +0100 Subject: [PATCH 2/3] add ccache output stats --- .github/workflows/appimage.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/appimage.yml b/.github/workflows/appimage.yml index dd8fc7118fe5..ec225a9fca1c 100644 --- a/.github/workflows/appimage.yml +++ b/.github/workflows/appimage.yml @@ -188,6 +188,7 @@ jobs: cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DUSE_SYSTEM_LIBSDL2=OFF -DUSE_SYSTEM_LIBPNG=OFF -DUSE_SYSTEM_FFMPEG=OFF -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache .. make -j$(nproc) popd + ccache -s -v - name: Create AppImage shell: bash From c2c045a274c5fee8a069d7c03b1ac4a5e2948913 Mon Sep 17 00:00:00 2001 From: Escary <81011361+pflyly@users.noreply.github.com> Date: Tue, 10 Jun 2025 19:57:38 +0100 Subject: [PATCH 3/3] remove not needed manual build trriger --- .github/workflows/appimage.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/appimage.yml b/.github/workflows/appimage.yml index ec225a9fca1c..305dec90e231 100644 --- a/.github/workflows/appimage.yml +++ b/.github/workflows/appimage.yml @@ -20,7 +20,6 @@ on: - 'Tools/**' - '.{editorconfig,gitattributes,gitignore}' - 'appveyor.yml' - workflow_dispatch: {} env: SDL_AUDIODRIVER: "dummy" #"disk"