Make sub-binaries of sub-binaries sub-binaries #1552
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Copyright 2022 Paul Guyot <pguyot@kallisys.net> | |
# | |
# SPDX-License-Identifier: Apache-2.0 OR LGPL-2.1-or-later | |
# | |
name: STM32 Build | |
on: | |
push: | |
paths: | |
- '.github/workflows/stm32-build.yaml' | |
- 'CMakeLists.txt' | |
- 'src/platforms/stm32/**' | |
- 'src/libAtomVM/**' | |
pull_request: | |
paths: | |
- '.github/workflows/stm32-build.yaml' | |
- 'CMakeLists.txt' | |
- 'src/platforms/stm32/**' | |
- 'src/libAtomVM/**' | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref != 'refs/heads/master' && github.ref || github.run_id }} | |
cancel-in-progress: true | |
jobs: | |
stm32: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/cache@v3 | |
id: builddeps-cache | |
with: | |
path: | | |
/home/runner/arm-gnu-toolchain-11.3.rel1-x86_64-arm-none-eabi | |
/home/runner/libopencm3 | |
key: ${{ runner.os }}-build-deps | |
- name: Install arm-embedded toolchain | |
if: ${{ steps.builddeps-cache.outputs.cache-hit != 'true' }} | |
working-directory: /home/runner | |
run: | | |
set -euo pipefail | |
cd /home/runner | |
wget https://developer.arm.com/-/media/Files/downloads/gnu/11.3.rel1/binrel/arm-gnu-toolchain-11.3.rel1-x86_64-arm-none-eabi.tar.xz \ | |
--output-document=$RUNNER_TEMP/arm-gnu-toolchain-11.3.rel1-x86_64-arm-none-eabi.tar.xz | |
tar xJf $RUNNER_TEMP/arm-gnu-toolchain-11.3.rel1-x86_64-arm-none-eabi.tar.xz | |
pwd && ls | |
- name: Checkout and build libopencm3 | |
if: ${{ steps.builddeps-cache.outputs.cache-hit != 'true' }} | |
working-directory: /home/runner | |
run: | | |
set -euo pipefail | |
cd /home/runner | |
test -d libopencm3 && rm -fr libopencm3 | |
export PATH=/home/runner/arm-gnu-toolchain-11.3.rel1-x86_64-arm-none-eabi/bin:${PATH} | |
git clone https://github.com/libopencm3/libopencm3.git -b v0.8.0 | |
cd libopencm3 | |
make | |
- name: "Install deps" | |
run: sudo apt install -y cmake gperf | |
- name: Checkout repo | |
uses: actions/checkout@v3 | |
- name: Build | |
shell: bash | |
working-directory: ./src/platforms/stm32/ | |
run: | | |
set -euo pipefail | |
export PATH=/home/runner/arm-gnu-toolchain-11.3.rel1-x86_64-arm-none-eabi/bin:${PATH} | |
mkdir build | |
cd build | |
cmake .. -DCMAKE_TOOLCHAIN_FILE=cmake/arm-toolchain.cmake -DLIBOPENCM3_DIR=/home/runner/libopencm3 | |
make -j |