Skip to content

Commit a2d7012

Browse files
Cache Support: Try 15
1 parent a52c237 commit a2d7012

File tree

1 file changed

+7
-13
lines changed

1 file changed

+7
-13
lines changed

.github/workflows/build.yml

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,11 @@ jobs:
6262
6363
- name: Setup ccache
6464
run: |
65+
mkdir -p $(pwd)/ccache/bazel # Ensure the directory exists
6566
echo "CCACHE_DIR=$(pwd)/ccache" >> $GITHUB_ENV
67+
echo "CCACHE_CPP2=true" >> $GITHUB_ENV
68+
echo "CCACHE_LOGFILE=/tmp/ccache.log" >> $GITHUB_ENV
69+
echo "CCACHE_LOGLEVEL=debug" >> $GITHUB_ENV
6670
echo "PATH=/usr/lib/ccache:/usr/local/bin:/opt/sdk-dat-arm/host/usr/bin/:$PATH" >> $GITHUB_ENV
6771
mkdir -p ~/ccache-links
6872
cd ~/ccache-links
@@ -80,7 +84,7 @@ jobs:
8084
- name: Configure ccache
8185
run: |
8286
mkdir -p $(pwd)/ccache/bazel # Ensure the directory exists
83-
ccache --set-config=cache_dir=$(pwd)/ccache
87+
ccache --set-config=cache_dir="$(pwd)/ccache"
8488
ccache --set-config=compression=true
8589
ccache --set-config=sloppiness=include_file_ctime,include_file_mtime
8690
@@ -97,6 +101,7 @@ jobs:
97101
run: |
98102
which ccache || echo "ccache not found!"
99103
which clang || echo "clang not found!"
104+
ls -l ~/ccache-links
100105
101106
- name: Set CONFIG Environment Variable
102107
run: |
@@ -261,19 +266,8 @@ jobs:
261266
#git config --global user.name "TheWildJames"
262267
#git add *
263268
#git commit -s -a -m "getting rid of -dirty"
264-
export HOSTCC="/usr/bin/ccache clang"
265-
export HOSTCXX="/usr/bin/ccache clang++"
266-
export CC="/usr/bin/ccache clang"
267-
sed -i 's/^HOSTCC=clang/HOSTCC=\/usr\/bin\/ccache clang/; s/^HOSTCXX=clang++/HOSTCXX=\/usr\/bin\/ccache clang++/; s/^CC=clang/CC=\/usr\/bin\/ccache clang/' ./kernel_platform/build/kernel/_setup_env.sh
268-
find ./kernel_platform/common -type f -name "Makefile" -exec sed -i \
269-
-e 's/^HOSTCC=clang/HOSTCC=\"\/usr\/bin\/ccache clang\"/' \
270-
-e 's/^HOSTCXX=clang++/HOSTCXX=\"\/usr\/bin\/ccache clang++\"/' \
271-
-e 's/^CC=clang/CC=\"\/usr\/bin\/ccache clang\"/' {} +
272-
find ./kernel_platform/msm-kernel -type f -name "Makefile" -exec sed -i \
273-
-e 's/^HOSTCC=clang/HOSTCC=\"\/usr\/bin\/ccache clang\"/' \
274-
-e 's/^HOSTCXX=clang++/HOSTCXX=\"\/usr\/bin\/ccache clang++\"/' \
275-
-e 's/^CC=clang/CC=\"\/usr\/bin\/ccache clang\"/' {} +
276269
./kernel_platform/oplus/build/oplus_build_kernel.sh ${{ inputs.soc }} gki
270+
ccache -s
277271
278272
- name: Copy Images
279273
run: |

0 commit comments

Comments
 (0)