build-ubuntu.yml 1.2 KB
Newer Older
1
name: CMake Build (Ubuntu x86-64)
2

3
4
5
6
7
8
9
on:
  push:
    branches:
      - master
  pull_request:
    branches:
      - master
10
11
12
13
14
15
16

env:
  BUILD_TYPE: Release
  CMAKE_VERSION: 3.15.2

jobs:
  build:
17

18
    runs-on: ubuntu-20.04
19

20
21
22
23
24
25
    steps:
    - uses: actions/checkout@v1
    - name: Install dependencies
      shell: bash
      working-directory: ${{runner.workspace}}
      run: | # Fetch a new version of CMake, because the default is too old.
26
        sudo rm -f /etc/apt/sources.list.d/dotnetdev.list /etc/apt/sources.list.d/microsoft-prod.list \
27
        && sudo apt-get update \
28
        && sudo apt-get install cmake libcurl4-gnutls-dev libpcap0.8-dev libsdl2-dev qt5-default libslirp-dev
29
30
31
32
33
    - name: Create build environment
      run: mkdir ${{runner.workspace}}/build
    - name: Configure
      shell: bash
      working-directory: ${{runner.workspace}}/build
34
      run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE
35
36
37
    - name: Make
      shell: bash
      working-directory: ${{runner.workspace}}/build
38
39
40
      run: |
        make -j$(nproc --all) \
        && mkdir dist \
Arisotura's avatar
Arisotura committed
41
        && cp melonDS dist
Raphaël Zumer's avatar
Raphaël Zumer committed
42
43
44
    - uses: actions/upload-artifact@v1
      with:
        name: melonDS
45
        path: ${{runner.workspace}}/build/dist