summaryrefslogtreecommitdiff
path: root/.github/workflows/build.yaml
blob: 91788c4076b6fa60fd167e0b405bceac67ddb741 (plain)
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
name: Build

on:
  workflow_dispatch:
  pull_request:
  push:
    branches: ["actions"]

jobs:
  build:
    strategy:
      matrix:
        os: [windows-2022, macos-11]
        configuration: [RelWithDebInfoOS]
        addrsize: [64]
        include:
          - os: windows-2022
            configuration: RelWithDebInfoOS
            addrsize: 32
    runs-on: ${{ matrix.os }}
    env:
      AUTOBUILD_CONFIGURATION: ${{ matrix.configuration }}
      AUTOBUILD_ADDRSIZE: ${{ matrix.addrsize }}
      AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables
      AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables
      AUTOBUILD_VSVER: "170"
    steps:
      - name: Checkout code
        uses: actions/checkout@v3

      - name: Checkout build variables
        uses: actions/checkout@v3
        with:
          repository: secondlife/build-variables
          ref: viewer
          path: .build-variables
      
      - name: Install autobuild 
        run: pip3 install autobuild

      - name: Cache autobuild packages
        uses: actions/cache@v3
        id: cache-installables
        with:
          path: .autobuild-installables
          key: ${{ matrix.os }}-${{ matrix.addrsize }}-${{ matrix.configuration }}-${{ hashFiles('autobuild.xml') }} 

      - name: Build
        shell: bash
        run: |
          pip install llsd # Required by viewer tests
          autobuild configure
          autobuild build --no-configure