2021-05-26 11:52:28 +02:00
|
|
|
name: Build MSP430
|
|
|
|
|
|
|
|
on:
|
2023-05-25 11:53:32 +02:00
|
|
|
workflow_dispatch:
|
2021-05-26 11:52:28 +02:00
|
|
|
push:
|
2022-12-08 03:44:26 +01:00
|
|
|
paths:
|
2022-12-08 05:47:01 +01:00
|
|
|
- 'src/**'
|
|
|
|
- 'examples/**'
|
|
|
|
- 'lib/**'
|
|
|
|
- 'hw/**'
|
2023-12-18 14:07:17 +01:00
|
|
|
- 'tools/get_deps.py'
|
2023-02-01 10:36:39 +01:00
|
|
|
- '.github/workflows/build_msp430.yml'
|
2022-12-08 03:44:26 +01:00
|
|
|
pull_request:
|
|
|
|
branches: [ master ]
|
|
|
|
paths:
|
2022-12-08 05:47:01 +01:00
|
|
|
- 'src/**'
|
|
|
|
- 'examples/**'
|
|
|
|
- 'lib/**'
|
|
|
|
- 'hw/**'
|
2023-12-18 14:07:17 +01:00
|
|
|
- 'tools/get_deps.py'
|
2023-02-01 10:36:39 +01:00
|
|
|
- '.github/workflows/build_msp430.yml'
|
2021-05-26 11:52:28 +02:00
|
|
|
|
2022-12-04 15:08:47 +01:00
|
|
|
concurrency:
|
|
|
|
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
2023-03-17 09:54:25 +01:00
|
|
|
jobs:
|
2021-05-26 11:52:28 +02:00
|
|
|
build-msp430:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
family:
|
|
|
|
# Alphabetical order
|
|
|
|
- 'msp430'
|
2022-11-16 05:16:40 +01:00
|
|
|
|
2021-05-26 11:52:28 +02:00
|
|
|
steps:
|
|
|
|
- name: Setup Python
|
2022-11-06 09:17:00 +01:00
|
|
|
uses: actions/setup-python@v4
|
2022-11-16 05:16:40 +01:00
|
|
|
with:
|
|
|
|
python-version: '3.x'
|
2021-05-26 11:52:28 +02:00
|
|
|
|
|
|
|
- name: Checkout TinyUSB
|
2023-12-18 14:07:17 +01:00
|
|
|
uses: actions/checkout@v4
|
2021-10-12 19:57:45 +02:00
|
|
|
|
2021-05-26 11:52:28 +02:00
|
|
|
- name: Set Toolchain URL
|
|
|
|
run: echo >> $GITHUB_ENV TOOLCHAIN_URL=http://software-dl.ti.com/msp430/msp430_public_sw/mcu/msp430/MSPGCC/9_2_0_0/export/msp430-gcc-9.2.0.50_linux64.tar.bz2
|
|
|
|
|
|
|
|
- name: Cache Toolchain
|
2022-11-16 05:11:26 +01:00
|
|
|
uses: actions/cache@v3
|
2021-05-26 11:52:28 +02:00
|
|
|
id: cache-toolchain
|
|
|
|
with:
|
|
|
|
path: ~/cache/
|
|
|
|
key: ${{ runner.os }}-21-03-04-${{ env.TOOLCHAIN_URL }}
|
|
|
|
|
|
|
|
- name: Install Toolchain
|
|
|
|
if: steps.cache-toolchain.outputs.cache-hit != 'true'
|
|
|
|
run: |
|
|
|
|
mkdir -p ~/cache/toolchain
|
|
|
|
wget --progress=dot:mega $TOOLCHAIN_URL -O toolchain.tar.bz2
|
|
|
|
tar -C ~/cache/toolchain -xaf toolchain.tar.bz2
|
|
|
|
|
|
|
|
- name: Set Toolchain Path
|
|
|
|
run: echo >> $GITHUB_PATH `echo ~/cache/toolchain/*/bin`
|
|
|
|
|
2022-07-01 12:23:14 +02:00
|
|
|
- name: Get Dependencies
|
2023-05-26 10:25:55 +02:00
|
|
|
run: python3 tools/get_deps.py ${{ matrix.family }}
|
2022-07-01 12:23:14 +02:00
|
|
|
|
2021-05-26 11:52:28 +02:00
|
|
|
- name: Build
|
2023-11-23 05:46:39 +01:00
|
|
|
run: python3 tools/build_make.py ${{ matrix.family }}
|