Skip to content

ci: add GH action to test compilation on Zephyr #7

ci: add GH action to test compilation on Zephyr

ci: add GH action to test compilation on Zephyr #7

name: compilation on zephyr
on:
# will be triggered on PR events
pull_request:
types:
- opened
- synchronize
paths:
- ".github/workflows/compilation_on_zephyr.yml"
- "build-scripts/**"
- "core/**"
- "!core/deps/**"
- "product-mini/**"
- "wamr-compiler/**"
- "wamr-sdk/**"
# will be triggered on push events
push:
branches:
- main
- "dev/**"
paths:
- ".github/workflows/compilation_on_zephyr.yml"
- "build-scripts/**"
- "core/**"
- "!core/deps/**"
- "product-mini/**"
- "wamr-compiler/**"
- "wamr-sdk/**"
# allow to be triggered manually
workflow_dispatch:
# Cancel any in-flight jobs for the same PR/branch so there's only one active
# at a time
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build_product_mini_on_zephyr:
runs-on: ubuntu-latest
container:
image: ghcr.io/zephyrproject-rtos/ci:latest
options: --user root
strategy:
matrix:
target: [nucleo_f767zi]
steps:
- name: Checkout zephyr working directory
uses: actions/checkout@v4
with:
repository: zephyrproject-rtos/zephyr
path: zephyr
- name: Checkout wasm-micro-runtime
uses: actions/checkout@v4
with:
path: wasm-micro-runtime
- name: Build for ${{ matrix.target }}
working-directory: ./wasm-micro-runtime/product-mini/platforms/zephyr/simple
run: |
west -z '${{ github.workspace }}/zephyr' build -b ${{ matrix.target }} . -p always -- -DWAMR_BUILD_TARGET=THUMBV7