aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows')
-rw-r--r--.github/workflows/build.yml74
-rw-r--r--.github/workflows/c-cpp.yml133
2 files changed, 74 insertions, 133 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
new file mode 100644
index 0000000..36d4c89
--- /dev/null
+++ b/.github/workflows/build.yml
@@ -0,0 +1,74 @@
+name: Build
+on:
+ push:
+ branches:
+ - main
+ - tmp
+ pull_request:
+ branches:
+ - main
+ - tmp
+ types: [opened, synchronize, reopened]
+ release:
+ types: [created]
+ schedule:
+ - cron: "0 13 * * 1"
+
+env:
+ WERROR: 1
+ Q:
+
+jobs:
+ test:
+ name: ${{ matrix.os }}
+ runs-on: ${{ matrix.os }}
+ strategy:
+ fail-fast: true
+ matrix:
+ os: ["ubuntu-latest", "ubuntu-22.04"]
+ include:
+ - compiler: "gcc"
+ os: "ubuntu-latest"
+ - compiler: "gcc-9"
+ os: "ubuntu-22.04"
+
+ steps:
+ - uses: actions/checkout@v2
+ with:
+ fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
+ - name: Install Ubuntu Prerequisites
+ if: startsWith(matrix.os, 'ubuntu')
+ run: |
+ sudo apt-get update
+ sudo apt-get install autoconf automake bison build-essential cmake flex libtool pkg-config gettext
+ sudo apt-get install ${{ matrix.compiler }} lcov osslsigncode
+ - name: Print Help
+ run: |
+ make help
+ - name: Build Toolchain, CRTs and EASTL
+ run: |
+ make deps
+ - name: Build Examples
+ run: |
+ make examples
+ - name: Install Examples
+ run: |
+ make examples-install DESTDIR=$(realpath _install)
+ ls -alh _install
+ test -r _install/codesign-ca-cert.crt -a -r _install/dpp-example.bat -a -r _install/dpp-example-cplusplus.bat -a -r _install/dpp-example-cplusplus-EASTL.bat -a -r _install/dpp-example.sys -a -r _install/dpp-example-cplusplus.sys -a -r _install/dpp-example-cplusplus-EASTL.sys
+ - name: Test
+ run: |
+ ./_install/dpp-example-cplusplus-EASTL.run
+ - name: Package
+ run: |
+ make package
+ - name: Cleanup
+ run: |
+ make deps-clean
+ make deps-distclean
+ - name: Upload Package
+ if: startsWith(matrix.os, 'ubuntu-latest')
+ uses: actions/upload-artifact@v4
+ with:
+ name: mingw-w64-dpp-package
+ path: mingw-w64-dpp.tar
diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml
deleted file mode 100644
index 0be723e..0000000
--- a/.github/workflows/c-cpp.yml
+++ /dev/null
@@ -1,133 +0,0 @@
-name: EASTL Build & Test Pipeline
-
-on:
- push:
- branches: [ master ]
- pull_request:
- branches: [ master ]
-
-jobs:
- checkout:
- name: Checkout EASTL and submodules
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v2
- with:
- path: EASTL/
- - run: cd EASTL/ && git submodule update --init
- - name: Upload checked out code
- uses: actions/upload-artifact@v2.3.1
- with:
- name: Code
- path: EASTL/
-
- build:
- needs: checkout
-
- strategy:
- fail-fast: false
- matrix:
- os: [ windows-latest, ubuntu-latest ]
- compiler: [ clang, gcc, msvc ]
- configuration: [ Debug, Release ]
- std_iter_compatibility: [ std_iter_category_disabled, std_iter_category_enabled ]
- exclude:
- - os: windows-latest
- compiler: gcc
- - os: windows-latest
- compiler: clang
- - os: ubuntu-latest
- compiler: msvc
- include:
- - os: windows-latest
- compiler: msvc
- cxxflags: '/std:c++20 /Zc:char8_t'
- - os: ubuntu-latest
- compiler: clang
- cc: 'clang-14'
- cxx: 'clang++-14'
- cxxflags: '-std=c++20'
- - os: ubuntu-latest
- compiler: gcc
- cc: 'gcc-12'
- cxx: 'g++-12'
- cxxflags: '-std=c++2a'
-
- name: Build EASTL
- runs-on: ${{ matrix.os }}
-
- steps:
- - name: Download a Build Artifact
- uses: actions/download-artifact@v2.1.0
- with:
- name: Code
- path: Code/
-
- - run: mkdir build
- - run: cd build && cmake ../Code -DEASTL_BUILD_BENCHMARK:BOOL=ON -DEASTL_BUILD_TESTS:BOOL=ON -DEASTL_STD_ITERATOR_CATEGORY_ENABLED:BOOL=${{ contains(matrix.std_iter_compatibility, 'enabled') && 'ON' || 'OFF' }}
- env:
- CXXFLAGS: ${{ matrix.cxxflags }}
- CXX: ${{ matrix.cxx }}
- CC: ${{ matrix.cc }}
- - run: cd build && cmake --build . --config ${{ matrix.configuration }}
- - name: Upload binaries
- uses: actions/upload-artifact@v2.3.1
- with:
- name: Binaries-${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.configuration }}
- path: build/
-
- test:
- needs: build
- name: Run EASTL tests
- strategy:
- fail-fast: false
- matrix:
- os: [ windows-latest, ubuntu-latest ]
- compiler: [ clang, msvc, gcc ]
- configuration: [ Debug, Release ]
- exclude:
- - os: windows-latest
- compiler: gcc
- - os: windows-latest
- compiler: clang
- - os: ubuntu-latest
- compiler: msvc
- runs-on: ${{ matrix.os }}
-
- steps:
- - name: Download a Build Artifact
- uses: actions/download-artifact@v2.1.0
- with:
- name: Binaries-${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.configuration }}
- path: Binaries/
- - if: matrix.os == 'ubuntu-latest'
- run: chmod 755 ./Binaries/test/EASTLTest
- - run: cd Binaries/test && ctest -C ${{ matrix.configuration }} -V
-
- benchmark:
- needs: build
- name: Run EASTL benchmarks
- strategy:
- fail-fast: false
- matrix:
- os: [ windows-latest, ubuntu-latest ]
- compiler: [ clang, msvc, gcc ]
- configuration: [ Release ]
- exclude:
- - os: windows-latest
- compiler: gcc
- - os: windows-latest
- compiler: clang
- - os: ubuntu-latest
- compiler: msvc
- runs-on: ${{ matrix.os }}
-
- steps:
- - name: Download a Build Artifact
- uses: actions/download-artifact@v2.1.0
- with:
- name: Binaries-${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.configuration }}
- path: Binaries/
- - if: matrix.os == 'ubuntu-latest'
- run: chmod 755 ./Binaries/benchmark/EASTLBenchmarks
- - run: cd Binaries/benchmark && ctest -C ${{ matrix.configuration }} -V