diff --git a/.github/workflows/pr-compile-check.yaml b/.github/workflows/pr-compile-check.yaml index dd982fab26e..835e7d55fcc 100644 --- a/.github/workflows/pr-compile-check.yaml +++ b/.github/workflows/pr-compile-check.yaml @@ -73,3 +73,26 @@ jobs: run: | ldd ./bin/fluent-bit working-directory: build + + # Sanity check for compilation w/ CXX support + pr-compile-without-cxx: + runs-on: ubuntu-latest + timeout-minutes: 60 + strategy: + fail-fast: false + steps: + - name: Setup environment + run: | + sudo apt-get update + sudo apt-get install -y bison cmake flex gcc libssl-dev libyaml-dev + + - name: Checkout Fluent Bit code + uses: actions/checkout@v4 + + - name: Compile w/ CXX support + run: | + export nparallel=$(( $(getconf _NPROCESSORS_ONLN) > 8 ? 8 : $(getconf _NPROCESSORS_ONLN) )) + cmake ../ + cat CMakeCache.txt | grep -q CMAKE_CXX_COMPILER-NOTFOUND + make -j $nparallel + working-directory: build