aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/build.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/build.yml')
-rw-r--r--.github/workflows/build.yml74
1 files changed, 74 insertions, 0 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