1212# See the License for the specific language governing permissions and
1313# limitations under the License.
1414
15- name : Build Release
15+ name : Build and Test
1616
1717on :
1818 push :
@@ -30,55 +30,56 @@ permissions:
3030 contents : read
3131
3232jobs :
33- clang-release :
33+ build-and-test :
34+ name : ${{ matrix.name }}
3435 runs-on : ubuntu-24.04
3536 timeout-minutes : 120
3637 strategy :
3738 fail-fast : false
39+ matrix :
40+ include :
41+ - name : gcc-release
42+ cc : gcc-14
43+ cxx : g++-14
44+ build_args : --build_type Release
45+ - name : clang-release
46+ build_args : --build_type Release
47+ - name : gcc-debug
48+ cc : gcc-14
49+ cxx : g++-14
50+ - name : clang-debug
51+ fetch_depth : ' 0' # fetch the PR target branch history for clang-tidy
52+ build_args : >-
53+ --check_clang_tidy
54+ --lint_git_target_commit "origin/${{ github.base_ref || github.event.repository.default_branch }}"
55+ - name : asan-ubsan
56+ build_args : --enable_asan --enable_ubsan
57+ - name : tsan
58+ skip_rust : true
59+ build_args : --enable_tsan
3860 steps :
3961 - name : Checkout paimon-cpp
4062 uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
4163 with :
4264 lfs : true
65+ fetch-depth : ${{ matrix.fetch_depth || '1' }}
4366 - name : Setup ccache
4467 uses : ./.github/actions/setup-ccache
4568 with :
46- cache-key-prefix : ccache-clang-release
69+ cache-key-prefix : ccache-${{ matrix.name }}
4770 - name : Install Rust toolchain (tantivy-fts)
71+ if : ${{ !matrix.skip_rust }}
4872 shell : bash
4973 run : ci/scripts/setup_rust.sh
5074 - name : Build Paimon
5175 shell : bash
5276 env :
53- CC : clang
54- CXX : clang++
55- run : ci/scripts/build_paimon.sh $(pwd) false false Release
56- - name : Show ccache statistics
57- if : always()
58- run : ccache -s
59- gcc-release :
60- runs-on : ubuntu-24.04
61- timeout-minutes : 120
62- strategy :
63- fail-fast : false
64- steps :
65- - name : Checkout paimon-cpp
66- uses : actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
67- with :
68- lfs : true
69- - name : Setup ccache
70- uses : ./.github/actions/setup-ccache
71- with :
72- cache-key-prefix : ccache-gcc-release
73- - name : Install Rust toolchain (tantivy-fts)
74- shell : bash
75- run : ci/scripts/setup_rust.sh
76- - name : Build Paimon
77- shell : bash
78- env :
79- CC : gcc-14
80- CXX : g++-14
81- run : ci/scripts/build_paimon.sh $(pwd) false false Release
77+ CC : ${{ matrix.cc || 'clang' }}
78+ CXX : ${{ matrix.cxx || 'clang++' }}
79+ run : >-
80+ ci/scripts/build_paimon.sh
81+ --source_dir "$(pwd)"
82+ ${{ matrix.build_args }}
8283 - name : Show ccache statistics
8384 if : always()
8485 run : ccache -s
0 commit comments