From c1d2672492bed8f63d2b40ba644233312454201f Mon Sep 17 00:00:00 2001 From: yixinglu <2520865+yixinglu@users.noreply.github.com> Date: Thu, 23 Dec 2021 00:11:18 +0800 Subject: [PATCH 1/3] Use ninja to build project --- .github/workflows/pull_request.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index 08bfd000fbc..459ab33914f 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -95,6 +95,7 @@ jobs: -DCMAKE_C_COMPILER=$TOOLSET_CLANG_DIR/bin/gcc \ -DCMAKE_BUILD_TYPE=Release \ -DENABLE_TESTING=on \ + -GNinja \ -B build echo "::set-output name=j::10" ;; @@ -106,6 +107,7 @@ jobs: -DCMAKE_BUILD_TYPE=Debug \ -DENABLE_TESTING=on \ -DENABLE_COVERAGE=on \ + -GNinja \ -B build echo "::set-output name=j::10" ;; @@ -119,6 +121,7 @@ jobs: -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -DENABLE_ASAN=on \ -DENABLE_TESTING=on \ + -GNinja \ -B build echo "::set-output name=j::6" ;; @@ -126,8 +129,9 @@ jobs: - name: Make run: | ccache -z - cmake --build build/ -j $(nproc) + ninja -j $(nproc) ccache -s + working-directory: build/ - name: CTest env: ASAN_OPTIONS: fast_unwind_on_malloc=1 From fef7e61f0f47eebb5e35f93b42ce78f813b2762e Mon Sep 17 00:00:00 2001 From: yixinglu <2520865+yixinglu@users.noreply.github.com> Date: Thu, 23 Dec 2021 16:23:33 +0800 Subject: [PATCH 2/3] Replace clang dir with gcc dir --- .github/workflows/pull_request.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index 459ab33914f..f5ff0f4f93b 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -91,8 +91,8 @@ jobs: centos7) # build with Release type cmake \ - -DCMAKE_CXX_COMPILER=$TOOLSET_CLANG_DIR/bin/g++ \ - -DCMAKE_C_COMPILER=$TOOLSET_CLANG_DIR/bin/gcc \ + -DCMAKE_CXX_COMPILER=$TOOLSET_GCC_DIR/bin/g++ \ + -DCMAKE_C_COMPILER=$TOOLSET_GCC_DIR/bin/gcc \ -DCMAKE_BUILD_TYPE=Release \ -DENABLE_TESTING=on \ -GNinja \ @@ -102,8 +102,8 @@ jobs: ubuntu2004) # build with Debug type cmake \ - -DCMAKE_CXX_COMPILER=$TOOLSET_CLANG_DIR/bin/g++ \ - -DCMAKE_C_COMPILER=$TOOLSET_CLANG_DIR/bin/gcc \ + -DCMAKE_CXX_COMPILER=$TOOLSET_GCC_DIR/bin/g++ \ + -DCMAKE_C_COMPILER=$TOOLSET_GCC_DIR/bin/gcc \ -DCMAKE_BUILD_TYPE=Debug \ -DENABLE_TESTING=on \ -DENABLE_COVERAGE=on \ From 732b827846a0271ee0e514f056c1a4e1aec3aee2 Mon Sep 17 00:00:00 2001 From: yixinglu <2520865+yixinglu@users.noreply.github.com> Date: Thu, 23 Dec 2021 16:30:51 +0800 Subject: [PATCH 3/3] Update gcc version --- .github/workflows/pull_request.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index f5ff0f4f93b..fb614a7b022 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -59,7 +59,7 @@ jobs: - centos7 - ubuntu2004 compiler: - - gcc-9.2 + - gcc-9.3 - clang-10 exclude: - os: centos7