From 24b4abdfd4e674cfc910b0a343c585f458cf5a17 Mon Sep 17 00:00:00 2001 From: The412Banner Date: Sat, 26 Sep 2026 17:35:45 -0400 Subject: [PATCH] shadPS4 build: give only shadPS4 the ccache launcher FEXCore's CMake already wraps its compiles in ccache when it is installed, so the global CMAKE__COMPILER_LAUNCHER doubled it into "ccache sloppiness=time_macros ccache clang" and every compile failed. Pass the launcher to shadPS4's configure alone (patches/0005). --- tools/shadps4/build-in-debian.sh | 8 ++++---- tools/shadps4/patches/0005-ccache-for-shadps4.patch | 13 +++++++++++++ 2 files changed, 17 insertions(+), 4 deletions(-) create mode 100644 tools/shadps4/patches/0005-ccache-for-shadps4.patch diff --git a/tools/shadps4/build-in-debian.sh b/tools/shadps4/build-in-debian.sh index c90edf96c..b534290a0 100755 --- a/tools/shadps4/build-in-debian.sh +++ b/tools/shadps4/build-in-debian.sh @@ -53,11 +53,11 @@ done # only through it, and without it builds ALSA alone. export PKG_CONFIG_LIBDIR=/usr/lib/aarch64-linux-gnu/pkgconfig:/usr/share/pkgconfig pkg-config --modversion libpulse -# Every CMake project the build configures (FEXCore, shadPS4 and its externals) compiles through -# ccache; the cache lives in the workspace (.ccache) and the workflow keeps it between runs. +# FEXCore compiles through ccache on its own once it is installed, and patches/0005 hands +# shadPS4's configure the same launcher; the cache lives in the workspace (.ccache) and the +# workflow keeps it between runs. export CCACHE_DIR=$WORK/.ccache CCACHE_BASEDIR=$WORK CCACHE_NOHASHDIR=1 \ - CCACHE_COMPILERCHECK=content CCACHE_MAXSIZE=4G \ - CMAKE_C_COMPILER_LAUNCHER=ccache CMAKE_CXX_COMPILER_LAUNCHER=ccache + CCACHE_COMPILERCHECK=content CCACHE_MAXSIZE=4G ccache -z bash "$SRC/runtime/scripts/build-shadps4-arm64.sh" ccache -s diff --git a/tools/shadps4/patches/0005-ccache-for-shadps4.patch b/tools/shadps4/patches/0005-ccache-for-shadps4.patch new file mode 100644 index 000000000..5300d0fcf --- /dev/null +++ b/tools/shadps4/patches/0005-ccache-for-shadps4.patch @@ -0,0 +1,13 @@ +diff --git a/runtime/scripts/build-shadps4-arm64.sh b/runtime/scripts/build-shadps4-arm64.sh +index 49c35fa..2bdcba0 100644 +--- a/runtime/scripts/build-shadps4-arm64.sh ++++ b/runtime/scripts/build-shadps4-arm64.sh +@@ -74,6 +74,8 @@ cmake -S "$project_root" -B "$build_dir" -G Ninja \ + -DXEXT_LIB:FILEPATH="$arm64_xext_lib" \ + -DIMGUI_FONT_EMBED_EXECUTABLE="$host_font_embed" \ + -DCMAKE_BUILD_TYPE=Release \ ++ -DCMAKE_C_COMPILER_LAUNCHER=ccache \ ++ -DCMAKE_CXX_COMPILER_LAUNCHER=ccache \ + -DCMAKE_CXX_SCAN_FOR_MODULES=OFF \ + -DCMAKE_AR="$llvm_ar" \ + -DCMAKE_RANLIB="$llvm_ranlib" \