Skip to content

Commit ae45cbd

Browse files
committed
ci: cache for freebsd
1 parent 96be28c commit ae45cbd

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

.github/actions/freebsd/action.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ runs:
1414
with:
1515
release: '13.5'
1616
usesh: true
17-
copyback: false
17+
copyback: true
1818
# Temporarily disable sqlite, as FreeBSD ships it with disabled double quotes. We'll need to fix our tests.
1919
# https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=269889
2020
prepare: |
@@ -24,6 +24,7 @@ runs:
2424
2525
kldload accf_http
2626
pkg install -y \
27+
ccache \
2728
autoconf \
2829
bison \
2930
gmake \
@@ -49,8 +50,13 @@ runs:
4950
curl \
5051
$OPCACHE_TLS_TESTS_DEPS
5152
53+
export CCACHE_DIR=$GITHUB_WORKSPACE/.ccache
54+
ccache --set-config=max_size=256M
55+
ccache --set-config=compression=true
56+
ccache -z
57+
5258
./buildconf -f
53-
CC=clang CXX=clang++ \
59+
CC="ccache clang" CXX="ccache clang++" \
5460
./configure \
5561
--prefix=/usr/local \
5662
--enable-debug \

.github/workflows/push.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -407,5 +407,13 @@ jobs:
407407
steps:
408408
- name: git checkout
409409
uses: actions/checkout@v6
410+
- name: Restore ccache
411+
uses: actions/cache@v4
412+
with:
413+
path: .ccache
414+
key: "${{github.job}}-${{hashFiles('main/php_version.h')}}-${{github.sha}}"
415+
restore-keys: |
416+
${{github.job}}-${{hashFiles('main/php_version.h')}}-
417+
${{github.job}}-
410418
- name: FreeBSD
411419
uses: ./.github/actions/freebsd

0 commit comments

Comments
 (0)