[enhancement](workflow) Use ccache to speed the BE UT (Clang) up (#11339)
This commit is contained in:
1
.github/actions/ccache-action
vendored
Submodule
1
.github/actions/ccache-action
vendored
Submodule
Submodule .github/actions/ccache-action added at bd43b7f5fb
8
.github/workflows/be-ut-clang.yml
vendored
8
.github/workflows/be-ut-clang.yml
vendored
@ -35,6 +35,12 @@ jobs:
|
||||
persist-credentials: false
|
||||
submodules: recursive
|
||||
|
||||
- name: Ccache ${{ github.ref }}
|
||||
uses: ./.github/actions/ccache-action
|
||||
with:
|
||||
key: ${{ github.ref }} (BE UT Clang)
|
||||
max-size: "1G"
|
||||
|
||||
- name: Paths filter
|
||||
uses: ./.github/actions/paths-filter
|
||||
id: filter
|
||||
@ -64,7 +70,7 @@ jobs:
|
||||
|
||||
sudo apt update
|
||||
sudo apt upgrade --yes
|
||||
sudo DEBIAN_FRONTEND=noninteractive apt install --yes tzdata ccache byacc
|
||||
sudo DEBIAN_FRONTEND=noninteractive apt install --yes tzdata byacc
|
||||
|
||||
# set timezone
|
||||
sudo ln -snf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
|
||||
|
||||
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -16,3 +16,6 @@
|
||||
[submodule ".github/actions/action-pr-title"]
|
||||
path = .github/actions/action-pr-title
|
||||
url = https://github.com/deepakputhraya/action-pr-title.git
|
||||
[submodule ".github/actions/ccache-action"]
|
||||
path = .github/actions/ccache-action
|
||||
url = https://github.com/hendrikmuhs/ccache-action
|
||||
|
||||
2
build.sh
2
build.sh
@ -285,6 +285,8 @@ if [ ${BUILD_BE} -eq 1 ] ; then
|
||||
fi
|
||||
MAKE_PROGRAM="$(which "${BUILD_SYSTEM}")"
|
||||
echo "-- Make program: ${MAKE_PROGRAM}"
|
||||
echo "-- Use ccache: ${CMAKE_USE_CCACHE}"
|
||||
|
||||
mkdir -p ${CMAKE_BUILD_DIR}
|
||||
cd ${CMAKE_BUILD_DIR}
|
||||
${CMAKE_CMD} -G "${GENERATOR}" \
|
||||
|
||||
@ -124,6 +124,7 @@ fi
|
||||
|
||||
MAKE_PROGRAM="$(which "${BUILD_SYSTEM}")"
|
||||
echo "-- Make program: ${MAKE_PROGRAM}"
|
||||
echo "-- Use ccache: ${CMAKE_USE_CCACHE}"
|
||||
|
||||
cd ${CMAKE_BUILD_DIR}
|
||||
${CMAKE_CMD} -G "${GENERATOR}" \
|
||||
|
||||
Reference in New Issue
Block a user