This repository has been archived by the owner on Jan 24, 2025. It is now read-only.
Update manifest for NCS 2.6.1 #16
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
--- | |
name: Build Firmware | |
on: | |
pull_request: | |
workflow_dispatch: | |
env: | |
ZEPHYR_SDK_VERSION: 0.16.5-1 | |
PROJ_DIR: project | |
BUILD_DIR: build | |
SAMPLES_DIR: bl5340pa_samples | |
DTM_DIR: nrf/samples/bluetooth/direct_test_mode | |
MANIFEST_DIR: bl5340pa_manifest | |
ARTIFACT_NAME: BL5340PA_samples | |
DEBUG: true | |
jobs: | |
firmware: | |
name: Build Firmware | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Initial Checkout | |
uses: actions/checkout@v4 | |
with: | |
path: ${{env.PROJ_DIR}}/${{env.MANIFEST_DIR}} | |
- if: ${{env.DEBUG}} | |
run: | | |
pwd | |
ls -la | |
ls -la ${{env.PROJ_DIR}} | |
ls -la ${{env.PROJ_DIR}}/${{env.MANIFEST_DIR}} | |
- name: Cache Source Code | |
uses: actions/cache@v4 | |
with: | |
path: ${{env.PROJ_DIR}} | |
key: ${{runner.os}}-source-${{hashFiles(format('{0}/{1}/west.yml', env.PROJ_DIR, env.MANIFEST_DIR))}} | |
- name: Cache PIP | |
uses: actions/cache@v4 | |
with: | |
path: ~/.cache/pip | |
key: ${{runner.os}}-pip | |
- name: Install Zephyr Tools | |
run: | | |
sudo apt update | |
sudo apt install --no-install-recommends git cmake ninja-build gperf \ | |
ccache dfu-util device-tree-compiler wget \ | |
python3-dev python3-pip python3-setuptools python3-tk python3-wheel xz-utils file \ | |
make gcc gcc-multilib g++-multilib libsdl2-dev libmagic1 | |
- name: Install West | |
run: | | |
pip install west | |
- name: Install Zephyr SDK | |
run: | | |
wget https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v${{env.ZEPHYR_SDK_VERSION}}/zephyr-sdk-${{env.ZEPHYR_SDK_VERSION}}_linux-x86_64_minimal.tar.xz | |
tar -xvf zephyr-sdk-${{env.ZEPHYR_SDK_VERSION}}_linux-x86_64_minimal.tar.xz -C /opt | |
/opt/zephyr-sdk-${{env.ZEPHYR_SDK_VERSION}}/setup.sh -h -c -t arm-zephyr-eabi | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
path: ${{env.PROJ_DIR}}/${{env.MANIFEST_DIR}} | |
- name: Pull Source Code and Save a copy of the manifest | |
run: | | |
set -x | |
cd ${{env.PROJ_DIR}} | |
rm -rf .west | |
west init -l ${{env.MANIFEST_DIR}} | |
west update -f always | |
- name: Install Python Dependencies | |
run: | | |
set -x | |
cd ${{env.PROJ_DIR}} | |
pip install -r zephyr/scripts/requirements.txt | |
pip install -r nrf/scripts/requirements.txt | |
pip install -r bootloader/mcuboot/scripts/requirements.txt | |
- name: Build Firmware | |
run: | | |
set -x | |
cd ${{env.PROJ_DIR}} | |
west twister -O ../${{env.BUILD_DIR}} -T ${{env.SAMPLES_DIR}} -c --overflow-as-errors --exclude-tag should_fail | |
west twister -O ../${{env.BUILD_DIR}} -T ${{env.DTM_DIR}} --overflow-as-errors --exclude-tag should_fail | |
- if: ${{env.DEBUG}} | |
run: | | |
pwd | |
ls -la | |
ls -la ${{env.PROJ_DIR}} | |
- name: Store Artifacts | |
# always run this step to store build logs for debugging | |
if: always() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{env.ARTIFACT_NAME}} | |
if-no-files-found: error | |
path: | |
${{env.BUILD_DIR}}/**/*.log | |
${{env.BUILD_DIR}}/**/autoconf.h | |
${{env.BUILD_DIR}}/**/zephyr.hex | |
${{env.BUILD_DIR}}/**/merged.hex | |
${{env.BUILD_DIR}}/**/merged_domains.hex | |
${{env.BUILD_DIR}}/**/*.lst | |
${{env.BUILD_DIR}}/**/*.map | |
${{env.BUILD_DIR}}/**/*.elf |