Update cpp.yml #353
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: C++ CI | |
| on: [push] | |
| jobs: | |
| build-ubuntu-gcc-14: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| config: | |
| - {compiler-options: "-Wall -Wextra -std=c++20"} | |
| - {compiler-options: "-Wall -Wextra -std=c++23"} | |
| - {compiler-options: "-Wall -Wextra -Wno-sign-compare -std=c++26"} | |
| - {compiler-options: "-fanalyzer -Wno-analyzer-null-dereference -std=c++26"} | |
| steps: | |
| - uses: actions/checkout@v2 | |
| # - name: install g++ | |
| # run: | | |
| # sudo add-apt-repository ppa:ubuntu-toolchain-r/test | |
| # sudo apt update | |
| # sudo apt-get install g++-14 | |
| - name: compile | |
| run: | | |
| cd cpp | |
| find . -name '*.cpp' -print0 | xargs -n1 -0 g++-14 ${{ matrix.config.compiler-options }} | |
| build-ubuntu-clang: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: install clang | |
| run: | | |
| #wget http://mirrors.kernel.org/ubuntu/pool/main/libf/libffi/libffi7_3.3-4_amd64.deb | |
| #sudo dpkg -i libffi7_3.3-4_amd64.deb | |
| sudo apt-key adv --fetch-keys https://apt.llvm.org/llvm-snapshot.gpg.key | |
| sudo add-apt-repository "deb http://apt.llvm.org/noble/ llvm-toolchain-noble main" | |
| sudo apt-get install clang-21 | |
| - name: compile | |
| run: | | |
| cd cpp | |
| find . -name '*.cpp' -print0 | xargs -n1 -0 clang++-21 -Wall -Wextra -std=c++26 | |
| build-macos-clang: | |
| runs-on: macos-latest | |
| strategy: | |
| matrix: | |
| config: | |
| - {compiler-options: "-Wall -Wextra -std=c++2b -isystem"} | |
| - {compiler-options: "-Wall -Wextra -Wno-sign-compare -std=c++2b -isystem"} | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: compile | |
| run: | | |
| cd cpp | |
| mkdir bits | |
| echo $'#include <algorithm>\n#include <iterator>\n#include <vector>\n#include <set>\n#include <map>\n#include <unordered_set>\n#include <unordered_map>\n#include <queue>\n#include <deque>\n#include <stack>\n#include <iostream>\n#include <iomanip>\n#include <complex>\n#include <cassert>\n#include <random>\n#include <chrono>\n#include <functional>\n#include <array>\n#include <bitset>\n#include <numeric>\n' > bits/stdc++.h | |
| find . -name '*.cpp' -print0 | xargs -n1 -0 clang++ ${{ matrix.config.compiler-options }} . | |
| build-windows-visual-cpp-17: | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: compile | |
| shell: cmd | |
| run: | | |
| call "%ProgramFiles%\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvars32.bat" | |
| cd cpp | |
| mkdir bits | |
| C:\msys64\usr\bin\echo.exe -e '#include \74vector\76\n#include \74set\76\n#include \74map\76\n#include \74unordered_set\76\n#include \74unordered_map\76\n#include \74queue\76\n#include \74deque\76\n#include \74stack\76\n#include \74iostream\76\n#include \74iomanip\76\n#include \74complex\76\n#include \74cassert\76\n#include \74random\76\n#include \74chrono\76\n#include \74functional\76\n#include \74array\76\n#include \74bitset\76\n#include \74numeric\76\n' > bits\stdc++.h | |
| C:\msys64\usr\bin\find . -name '*.cpp' -print0 | C:\msys64\usr\bin\xargs -n1 -0 cl //std:c++17 //EHsc //I . | |
| build-windows-visual-cpp-20: | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: compile | |
| shell: cmd | |
| run: | | |
| call "%ProgramFiles%\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvars32.bat" | |
| cd cpp | |
| mkdir bits | |
| C:\msys64\usr\bin\echo.exe -e '#include \74vector\76\n#include \74set\76\n#include \74map\76\n#include \74unordered_set\76\n#include \74unordered_map\76\n#include \74queue\76\n#include \74deque\76\n#include \74stack\76\n#include \74iostream\76\n#include \74iomanip\76\n#include \74complex\76\n#include \74cassert\76\n#include \74random\76\n#include \74chrono\76\n#include \74functional\76\n#include \74array\76\n#include \74bitset\76\n#include \74numeric\76\n' > bits\stdc++.h | |
| C:\msys64\usr\bin\find . -name '*.cpp' -print0 | C:\msys64\usr\bin\xargs -n1 -0 cl //std:c++20 //EHsc //I . |