-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (40 loc) · 1.17 KB
/
linux.yml
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
name: Linux
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Install Premake
if: steps.cache-premake.outputs.cache-hit != 'true'
run: |
wget https://github.com/premake/premake-core/releases/download/v5.0.0-alpha16/premake-5.0.0-alpha16-linux.tar.gz
tar -xzvf premake-5.0.0-alpha16-linux.tar.gz
sudo mv premake5 /usr/local/bin/
- name: Install Clang
run: |
sudo apt update
sudo apt install -y clang
- name: Set CC and CXX environment variables
run: |
echo "CC=clang" >> $GITHUB_ENV
echo "CXX=clang++" >> $GITHUB_ENV
- name: Cache Compilation Outputs
uses: actions/cache@v2
with:
path: |
output/**/bin/
output/**/obj/
key: ${{ runner.os }}-compilation-${{ hashFiles('**/*.cpp', '**/*.h') }}
restore-keys: |
${{ runner.os }}-compilation-
- name: Run Premake
run: premake5 gmake
- name: Compile Project
run: make config=debug CC=clang