Skip to content

Commit

Permalink
Install ccache on old ubuntus
Browse files Browse the repository at this point in the history
  • Loading branch information
fdr400 committed Jan 5, 2025
1 parent 1c6537f commit 8100b81
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 25 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/alpine.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,6 @@ jobs:
with:
fetch-depth: 0

- name: Setup latest Alpine Linux
uses: jirutka/setup-alpine@v1

- name: Restore cached directories
id: restore-cache
uses: actions/cache/restore@v4
Expand All @@ -44,6 +41,13 @@ jobs:
alpine-cache-dir ${{github.ref}} run-
alpine-cache-dir
- name: Setup latest Alpine Linux
uses: jirutka/setup-alpine@v1
with:
volumes: |
${{env.CCACHE_DIR}}:${{env.CCACHE_DIR}}
${{env.CPM_SOURCE_CACHE}}:${{env.CPM_SOURCE_CACHE}}
- name: Install dependencies
shell: alpine.sh --root {0}
run: |
Expand Down
52 changes: 30 additions & 22 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -128,14 +128,6 @@ jobs:
sudo docker image prune --all --force
df -h
- name: Setup ccache
run: |
sudo apt update
sudo apt install ccache
ccache -M 3.0GB
ccache -s
ccache -p
- name: Add confluentinc repositories
if: matrix.os != 'ubuntu-24.04'
run: |
Expand Down Expand Up @@ -164,20 +156,6 @@ jobs:
sudo ln -sf /usr/bin/clang-format-14 /usr/bin/clang-format
clang-format --version
- name: Install grpc, protobuf and abseil
if: matrix.os == 'ubuntu-20.04'
run: |
sudo apt install ninja-build
git clone --recursive --depth 1 -b v1.45.0 https://github.com/grpc/grpc new_grpc
GRPC_BUILD_ENABLE_CCACHE=true \
cmake -GNinja -S./new_grpc -B./new_grpc/build \
-DABSL_PROPAGATE_CXX_STD=ON -DABSL_ENABLE_INSTALL=ON
cmake --build new_grpc/build -j$(nproc)
sudo cmake --install new_grpc/build
rm -rf new_grpc
ccache -s
ccache -p
- name: Add missing repositories
run: |
sudo apt update
Expand Down Expand Up @@ -215,6 +193,36 @@ jobs:
sudo apt purge -y libpq5 libpq-dev postgresql-*
sudo apt install --allow-downgrades -y clickhouse-common-static redis-server postgresql $(cat scripts/docs/en/deps/${{matrix.os}}.md | tr '\n' ' ')
- name: Install ccache
if: matrix.os == 'ubuntu-20.04'
run: |
sudo apt remove --purge -y ccache
git clone --depth 1 -b v4.10.2 https://github.com/ccache/ccache.git
cd ccache
cmake -S . -B build -D ENABLE_TESTING=OFF -DSTATIC_LINK=ON -DCMAKE_BUILD_TYPE=Release
cmake --build build -j$(nproc)
sudo cmake --install build
- name: Setup ccache
run: |
which ccache
ccache --version
ccache -M 3.0GB
ccache -s -v
- name: Install grpc, protobuf and abseil
if: matrix.os == 'ubuntu-20.04'
run: |
sudo apt install ninja-build
git clone --recursive --depth 1 -b v1.45.0 https://github.com/grpc/grpc new_grpc
GRPC_BUILD_ENABLE_CCACHE=true \
cmake -GNinja -S./new_grpc -B./new_grpc/build \
-DABSL_PROPAGATE_CXX_STD=ON -DABSL_ENABLE_INSTALL=ON
cmake --build new_grpc/build -j$(nproc)
sudo cmake --install new_grpc/build
rm -rf new_grpc
ccache -s -v
- name: Install g++-8
if: matrix.info == 'g++-8 + debug'
run: |
Expand Down

0 comments on commit 8100b81

Please sign in to comment.