Create initial GitHub Workflows setup
So far it consists of following builds: - GCC 9.1 (Ubuntu 18.04) - GCC 8.3 (Ubuntu 18.04) - GCC 7.4 (Ubuntu 18.04 default) - GCC 5.4 (Ubuntu 16.04 default) - Clang 10.0 (macOS 10.14 Mojave default) - Clang 6.0 (Ubuntu 18.04) Workflow also defines static code analysis using Clang 6 (Ubuntu 18.04), which does not indicate results directly in PRs yet, but uploads a static analysis report as a build artifact.
This commit is contained in:
parent
398c02cc01
commit
58857e25e2
2 changed files with 126 additions and 0 deletions
97
.github/workflows/compilation.yml
vendored
Normal file
97
.github/workflows/compilation.yml
vendored
Normal file
|
@ -0,0 +1,97 @@
|
|||
name: Compilation
|
||||
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
|
||||
build_gcc9:
|
||||
name: "GCC 9 (ubuntu-18.04)"
|
||||
runs-on: ubuntu-18.04
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: "Install packages"
|
||||
run: sudo apt-get install g++-9 libsdl1.2-dev libsdl-net1.2-dev libsdl-sound1.2-dev
|
||||
- name: Build
|
||||
env:
|
||||
CC: gcc-9
|
||||
CXX: g++-9
|
||||
run: |
|
||||
# build steps
|
||||
set -x
|
||||
$CXX --version
|
||||
./autogen.sh
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
|
||||
build_gcc8:
|
||||
name: "GCC 8 (ubuntu-18.04)"
|
||||
runs-on: ubuntu-18.04
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: "Install packages"
|
||||
run: sudo apt-get install g++-8 libsdl1.2-dev libsdl-net1.2-dev libsdl-sound1.2-dev
|
||||
- name: Build
|
||||
env:
|
||||
CC: gcc-8
|
||||
CXX: g++-8
|
||||
run: |
|
||||
# build steps
|
||||
set -x
|
||||
$CXX --version
|
||||
./autogen.sh
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
|
||||
build_ubuntu:
|
||||
name: "GCC"
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-18.04, ubuntu-16.04]
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: "Install packages"
|
||||
run: sudo apt-get install libsdl1.2-dev libsdl-net1.2-dev libsdl-sound1.2-dev
|
||||
- name: Build
|
||||
run: |
|
||||
# build steps
|
||||
set -x
|
||||
g++ --version
|
||||
./autogen.sh
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
|
||||
build_clang:
|
||||
name: "Clang 6 (ubuntu-18.04)"
|
||||
runs-on: ubuntu-18.04
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: "Install packages"
|
||||
run: sudo apt-get install libsdl1.2-dev libsdl-net1.2-dev libsdl-sound1.2-dev
|
||||
- name: Build
|
||||
env:
|
||||
CC: clang
|
||||
CXX: clang++
|
||||
run: |
|
||||
# build steps
|
||||
set -x
|
||||
$CXX --version
|
||||
./autogen.sh
|
||||
./configure
|
||||
make -j "$(nproc)"
|
||||
|
||||
build_macos:
|
||||
name: "Clang (macOS-10.14)"
|
||||
runs-on: macOS-10.14
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: "Install packages"
|
||||
run: brew install automake libpng sdl sdl_net sdl_sound
|
||||
- name: Build
|
||||
run: |
|
||||
# build steps
|
||||
set -x
|
||||
clang++ --version
|
||||
./autogen.sh
|
||||
./configure
|
||||
make -j "$(sysctl -n hw.physicalcpu)"
|
29
.github/workflows/static.yml
vendored
Normal file
29
.github/workflows/static.yml
vendored
Normal file
|
@ -0,0 +1,29 @@
|
|||
name: Static code analysis
|
||||
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
|
||||
build_clang_static_analyser:
|
||||
name: "Clang static analyzer"
|
||||
runs-on: ubuntu-18.04
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: "Install packages"
|
||||
run: sudo apt-get install libsdl1.2-dev libsdl-net1.2-dev libsdl-sound1.2-dev python3-setuptools
|
||||
- name: "Install scan-build (Python version)"
|
||||
run: sudo pip3 install scan-build
|
||||
- name: Build
|
||||
run: |
|
||||
# build steps
|
||||
set -x
|
||||
g++ --version
|
||||
./autogen.sh
|
||||
./configure
|
||||
intercept-build make -j "$(nproc)"
|
||||
- name: Analyze
|
||||
run: analyze-build -v -o report --html-title="dosbox-staging (${GITHUB_SHA:0:8})"
|
||||
- uses: actions/upload-artifact@master
|
||||
with:
|
||||
name: report
|
||||
path: report
|
Loading…
Add table
Reference in a new issue