Repository navigation
84 lines (72 loc) · 2.11 KB
/
Copy pathlinux_build.yml
File metadata and controls
84 lines (72 loc) · 2.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: Linux Make
on:
push:
paths:
- '**.c'
- '**.cpp'
- '**.cxx'
- '**.h'
- '**.hpp'
- '**.hxx'
- '**.yml'
- '**/premake*.lua'
- 'premake*.lua'
branches: [ "develop" ]
pull_request:
branches: [ "develop" ]
paths:
- '**.c'
- '**.cpp'
- '**.cxx'
- '**.h'
- '**.hpp'
- '**.hxx'
- '**.yml'
- '**/premake*.lua'
- 'premake*.lua'
env:
PROJECT_NAME: auto_tests
BUILD_PLATFORM: x64
TESTS: ds_tests ppmem_tests scripting_tests
EXE_SUFFIX:
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- configuration: Debug
make_config: debug
- configuration: Release
make_config: release
steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.ACTIONSPAT }}
submodules: recursive
- name: Setup AppImageTool
uses: AnimMouse/setup-appimage@v1
with:
name: appimagetool
url: https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage
- name: Install dependencies 1
run: sudo add-apt-repository universe && sudo apt-get update && sudo apt-get install -y build-essential libsdl2-dev libopenal-dev libxxf86vm-dev
- name: Install dependencies 2
run: ./utils/linux_dev_prepare.sh
- name: Generate Makefile
working-directory: ${{env.GITHUB_WORKSPACE}}
run: ./utils/premake5 --file=premake5-tests.lua gmake2
- name: make
working-directory: ./build/${{env.PROJECT_NAME}}
run: make config=${{matrix.make_config}}_${{env.BUILD_PLATFORM}} -j10
- name: Run tests
working-directory: ./build/${{env.PROJECT_NAME}}/bin/${{env.BUILD_PLATFORM}}/${{matrix.configuration}}
timeout-minutes: 10
run: |
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$(pwd)
failed=""
for test in $TESTS; do
./$test || failed="$failed $test"
done
if [ -n "$failed" ]; then echo "::error::Failed tests:$failed"; exit 1; fi