diff options
Diffstat (limited to 'src/fmt/.github')
-rw-r--r-- | src/fmt/.github/issue_template.md | 6 | ||||
-rw-r--r-- | src/fmt/.github/pull_request_template.md | 6 | ||||
-rw-r--r-- | src/fmt/.github/workflows/doc.yml | 27 | ||||
-rw-r--r-- | src/fmt/.github/workflows/linux.yml | 94 | ||||
-rw-r--r-- | src/fmt/.github/workflows/macos.yml | 40 | ||||
-rw-r--r-- | src/fmt/.github/workflows/windows.yml | 92 |
6 files changed, 265 insertions, 0 deletions
diff --git a/src/fmt/.github/issue_template.md b/src/fmt/.github/issue_template.md new file mode 100644 index 000000000..8e39c5ba7 --- /dev/null +++ b/src/fmt/.github/issue_template.md @@ -0,0 +1,6 @@ +<!-- +Please make sure that the problem reproduces on the current master before +submitting an issue. +If possible please provide a repro on Compiler Explorer: +https://godbolt.org/z/fxccbh53W. +--> diff --git a/src/fmt/.github/pull_request_template.md b/src/fmt/.github/pull_request_template.md new file mode 100644 index 000000000..b70c27bfb --- /dev/null +++ b/src/fmt/.github/pull_request_template.md @@ -0,0 +1,6 @@ +<!-- +Please read the contribution guidelines before submitting a pull request: +https://github.com/fmtlib/fmt/blob/master/CONTRIBUTING.md. +By submitting this pull request, you agree that your contributions are licensed +under the {fmt} license, and agree to future changes to the licensing. +--> diff --git a/src/fmt/.github/workflows/doc.yml b/src/fmt/.github/workflows/doc.yml new file mode 100644 index 000000000..47c097746 --- /dev/null +++ b/src/fmt/.github/workflows/doc.yml @@ -0,0 +1,27 @@ +name: doc + +on: [push, pull_request] + +permissions: + contents: read + +jobs: + build: + # Use Ubuntu 20.04 because doxygen 1.8.13 from Ubuntu 18.04 is broken. + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + + - name: Create Build Environment + run: | + sudo apt update + sudo apt install doxygen python3-virtualenv + sudo npm install -g less clean-css + cmake -E make_directory ${{runner.workspace}}/build + + - name: Build + working-directory: ${{runner.workspace}}/build + env: + KEY: ${{secrets.KEY}} + run: $GITHUB_WORKSPACE/support/build-docs.py diff --git a/src/fmt/.github/workflows/linux.yml b/src/fmt/.github/workflows/linux.yml new file mode 100644 index 000000000..70085f5c6 --- /dev/null +++ b/src/fmt/.github/workflows/linux.yml @@ -0,0 +1,94 @@ +name: linux + +on: [push, pull_request] + +permissions: + contents: read + +jobs: + build: + runs-on: ${{ matrix.os }} + strategy: + matrix: + cxx: [g++-4.8, g++-10, clang++-9] + build_type: [Debug, Release] + std: [11] + os: [ubuntu-18.04] + include: + - cxx: g++-4.8 + install: sudo apt install g++-4.8 + os: ubuntu-18.04 + - cxx: g++-8 + build_type: Debug + std: 14 + install: sudo apt install g++-8 + os: ubuntu-18.04 + - cxx: g++-8 + build_type: Debug + std: 17 + install: sudo apt install g++-8 + os: ubuntu-18.04 + - cxx: g++-10 + build_type: Debug + std: 17 + os: ubuntu-18.04 + - cxx: g++-11 + build_type: Debug + std: 20 + os: ubuntu-20.04 + install: sudo apt install g++-11 + - cxx: clang++-8 + build_type: Debug + std: 17 + cxxflags: -stdlib=libc++ + os: ubuntu-18.04 + install: sudo apt install clang-8 libc++-8-dev libc++abi-8-dev + - cxx: clang++-9 + build_type: Debug + fuzz: -DFMT_FUZZ=ON -DFMT_FUZZ_LINKMAIN=ON + std: 17 + os: ubuntu-18.04 + - cxx: clang++-11 + build_type: Debug + std: 20 + os: ubuntu-20.04 + - cxx: clang++-11 + build_type: Debug + std: 20 + cxxflags: -stdlib=libc++ + os: ubuntu-20.04 + install: sudo apt install libc++-11-dev libc++abi-11-dev + - shared: -DBUILD_SHARED_LIBS=ON + + steps: + - uses: actions/checkout@v2 + + - name: Create Build Environment + run: | + ${{matrix.install}} + sudo apt update + sudo apt install locales-all + cmake -E make_directory ${{runner.workspace}}/build + + - name: Configure + working-directory: ${{runner.workspace}}/build + env: + CXX: ${{matrix.cxx}} + CXXFLAGS: ${{matrix.cxxflags}} + run: | + cmake -DCMAKE_BUILD_TYPE=${{matrix.build_type}} ${{matrix.fuzz}} ${{matrix.shared}} \ + -DCMAKE_CXX_STANDARD=${{matrix.std}} -DFMT_DOC=OFF \ + -DCMAKE_CXX_VISIBILITY_PRESET=hidden -DCMAKE_VISIBILITY_INLINES_HIDDEN=ON \ + -DFMT_PEDANTIC=ON -DFMT_WERROR=ON $GITHUB_WORKSPACE + + - name: Build + working-directory: ${{runner.workspace}}/build + run: | + threads=`nproc` + cmake --build . --config ${{matrix.build_type}} --parallel $threads + + - name: Test + working-directory: ${{runner.workspace}}/build + run: ctest -C ${{matrix.build_type}} + env: + CTEST_OUTPUT_ON_FAILURE: True diff --git a/src/fmt/.github/workflows/macos.yml b/src/fmt/.github/workflows/macos.yml new file mode 100644 index 000000000..24dd59588 --- /dev/null +++ b/src/fmt/.github/workflows/macos.yml @@ -0,0 +1,40 @@ +name: macos + +on: [push, pull_request] + +permissions: + contents: read + +jobs: + build: + runs-on: macos-10.15 + strategy: + matrix: + build_type: [Debug, Release] + include: + - shared: -DBUILD_SHARED_LIBS=ON + + steps: + - uses: actions/checkout@v2 + + - name: Create Build Environment + run: cmake -E make_directory ${{runner.workspace}}/build + + - name: Configure + working-directory: ${{runner.workspace}}/build + run: | + cmake -DCMAKE_BUILD_TYPE=${{matrix.build_type}} ${{matrix.shared}} \ + -DCMAKE_CXX_VISIBILITY_PRESET=hidden -DCMAKE_VISIBILITY_INLINES_HIDDEN=ON \ + -DFMT_DOC=OFF -DFMT_PEDANTIC=ON -DFMT_WERROR=ON $GITHUB_WORKSPACE + + - name: Build + working-directory: ${{runner.workspace}}/build + run: | + threads=`sysctl -n hw.logicalcpu` + cmake --build . --config ${{matrix.build_type}} --parallel $threads + + - name: Test + working-directory: ${{runner.workspace}}/build + run: ctest -C ${{matrix.build_type}} + env: + CTEST_OUTPUT_ON_FAILURE: True diff --git a/src/fmt/.github/workflows/windows.yml b/src/fmt/.github/workflows/windows.yml new file mode 100644 index 000000000..6e79f60c2 --- /dev/null +++ b/src/fmt/.github/workflows/windows.yml @@ -0,0 +1,92 @@ +name: windows + +on: [push, pull_request] + +permissions: + contents: read + +jobs: + build: + runs-on: ${{matrix.os}} + strategy: + matrix: + # windows-2019 has MSVC 2019 installed; + # windows-2022 has MSVC 2022 installed: + # https://github.com/actions/virtual-environments. + os: [windows-2019] + platform: [Win32, x64] + toolset: [v140, v141, v142] + standard: [14, 17, 20] + shared: ["", -DBUILD_SHARED_LIBS=ON] + build_type: [Debug, Release] + exclude: + - { toolset: v140, standard: 17 } + - { toolset: v140, standard: 20 } + - { toolset: v141, standard: 14 } + - { toolset: v141, standard: 20 } + - { toolset: v142, standard: 14 } + - { platform: Win32, toolset: v140 } + - { platform: Win32, toolset: v141 } + - { platform: Win32, standard: 14 } + - { platform: Win32, standard: 20 } + - { platform: x64, toolset: v140, shared: -DBUILD_SHARED_LIBS=ON } + - { platform: x64, toolset: v141, shared: -DBUILD_SHARED_LIBS=ON } + - { platform: x64, standard: 14, shared: -DBUILD_SHARED_LIBS=ON } + - { platform: x64, standard: 20, shared: -DBUILD_SHARED_LIBS=ON } + include: + - os: windows-2022 + platform: x64 + toolset: v143 + build_type: Debug + standard: 20 + + steps: + - uses: actions/checkout@v2 + + - name: Create Build Environment + run: cmake -E make_directory ${{runner.workspace}}/build + + - name: Configure + # Use a bash shell for $GITHUB_WORKSPACE. + shell: bash + working-directory: ${{runner.workspace}}/build + run: | + cmake -A ${{matrix.platform}} -T ${{matrix.toolset}} \ + -DCMAKE_CXX_STANDARD=${{matrix.standard}} \ + ${{matrix.shared}} -DCMAKE_BUILD_TYPE=${{matrix.build_type}} \ + $GITHUB_WORKSPACE + + - name: Build + working-directory: ${{runner.workspace}}/build + run: | + $threads = (Get-CimInstance Win32_ComputerSystem).NumberOfLogicalProcessors + cmake --build . --config ${{matrix.build_type}} --parallel $threads + + - name: Test + working-directory: ${{runner.workspace}}/build + run: ctest -C ${{matrix.build_type}} -V + env: + CTEST_OUTPUT_ON_FAILURE: True + + mingw: + runs-on: windows-latest + defaults: + run: + shell: msys2 {0} + strategy: + matrix: + sys: [ mingw64, mingw32, ucrt64 ] + steps: + - uses: msys2/setup-msys2@v2 + with: + release: false + msystem: ${{matrix.sys}} + pacboy: cc:p cmake:p ninja:p lld:p + - uses: actions/checkout@v2 + - name: Configure + run: cmake -B ../build -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Debug + env: { LDFLAGS: -fuse-ld=lld } + - name: Build + run: cmake --build ../build + - name: Test + run: ctest -j `nproc` --test-dir ../build |