forked from libretro/virtualjaguar-libretro
-
Notifications
You must be signed in to change notification settings - Fork 1
77 lines (65 loc) · 1.87 KB
/
c-cpp.yml
File metadata and controls
77 lines (65 loc) · 1.87 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
name: C/C++ CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
strategy:
fail-fast: false
matrix:
config:
# Linux
- displayTargetName: 'Linux x86_64 (GCC)'
artifact: 'virtualjaguar_libretro.so'
os: ubuntu-latest
cc: 'gcc'
cxx: 'g++'
- displayTargetName: 'Linux x86_64 (Clang)'
artifact: 'virtualjaguar_libretro.so'
os: ubuntu-latest
cc: 'clang'
cxx: 'clang++'
- displayTargetName: 'Linux aarch64'
artifact: 'virtualjaguar_libretro.so'
os: ubuntu-24.04-arm
cc: 'gcc'
cxx: 'g++'
# macOS
- displayTargetName: 'macOS arm64 (Clang)'
artifact: 'virtualjaguar_libretro.dylib'
os: macos-latest
cc: 'clang'
cxx: 'clang++'
# Windows
- displayTargetName: 'Windows x86_64 (MSYS2)'
artifact: 'virtualjaguar_libretro.dll'
os: windows-latest
cc: 'gcc'
cxx: 'g++'
shell: 'msys2 {0}'
name: build-${{ matrix.config.displayTargetName }}
runs-on: ${{ matrix.config.os }}
defaults:
run:
shell: ${{ matrix.config.shell || 'bash' }}
steps:
- uses: actions/checkout@v4
- name: Set up MSYS2
if: runner.os == 'Windows'
uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: false
install: >-
mingw-w64-x86_64-gcc
make
- name: Build
run: make -j4 CC=${{ matrix.config.cc }} CXX=${{ matrix.config.cxx }}
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.config.displayTargetName }}
path: ${{ matrix.config.artifact }}
if-no-files-found: error