Skip to content

test

test #16

Workflow file for this run

name: ESWin EIC7700
on:
push:
paths:
- '.github/workflows/eswin-eic7700.yml'
- 'eswin-eic7700/**'
jobs:
build:
name: Build U-Boot for ESWin EIC7700
runs-on: ubuntu-latest
outputs:
artifact_ids: ${{ steps.upload-artifacts.outputs.artifact-id }}
strategy:
matrix:
include:
- board: milkv_megrez
defconfig: eic7700_milkv_megrez_defconfig
- board: eswin_ebc77
defconfig: eic7700_sbc_defconfig
- board: hifive_premier_p550
defconfig: hifive_premier_p550_defconfig
- board: eswin_eic7700_evb_a2
defconfig: eic7700_evb_a2_defconfig
steps:
- name: Install Dependencies
run: |
sudo apt-get update
sudo apt-get install -y gcc-riscv64-linux-gnu bc bison build-essential coccinelle \
device-tree-compiler dfu-util efitools flex gdisk graphviz imagemagick \
libgnutls28-dev libguestfs-tools libncurses-dev \
libpython3-dev libsdl2-dev libssl-dev lz4 lzma lzma-alone openssl \
pkg-config python3 python3-asteval python3-coverage python3-filelock \
python3-pkg-resources python3-pycryptodome python3-pyelftools \
python3-pytest python3-pytest-xdist python3-sphinxcontrib.apidoc \
python3-sphinx-rtd-theme python3-subunit python3-testtools \
python3-venv swig uuid-dev cmake gcc
- name: Checkout U-Boot Source
uses: actions/checkout@v5
with:
repository: openeuler-riscv/u-boot.git
ref: eswin-eic7700-vendor-2024.01
fetch-depth: 1
path: u-boot
- name: Checkout OpenSBI Source
uses: actions/checkout@v5
with:
repository: eswincomputing/opensbi.git
# branch opensbi-1.3-EIC7X as of 20251020
ref: 0a54714aa06568f41038aef0dad0e3ca0fe39dbb
fetch-depth: 1
path: opensbi
- name: Build U-Boot
run: |
mkdir -p build
make -C u-boot -j $(nproc) O=$(pwd)/build/u-boot CROSS_COMPILE=riscv64-linux-gnu- ${{ matrix.defconfig }}
make -C u-boot -j $(nproc) O=$(pwd)/build/u-boot CROSS_COMPILE=riscv64-linux-gnu-
- name: Build OpenSBI
run: |
make -C opensbi -j $(nproc) O=$(pwd)/build/opensbi CROSS_COMPILE=riscv64-linux-gnu- PLATFORM=eswin/eic770x FW_PAYLOAD=y FW_FDT_PATH=$(pwd)/build/u-boot/u-boot.dtb FW_PAYLOAD_PATH=$(pwd)/build/u-boot/u-boot.bin CHIPLET="BR2_CHIPLET_1" CHIPLET_DIE_AVAILABLE="BR2_CHIPLET_1_DIE0_AVAILABLE" MEM_MODE="BR2_MEMMODE_FLAT" PLATFORM_CLUSTER_X_CORE="BR2_CLUSTER_4_CORE"PLATFORM_RISCV_ISA=rv64imafdc_zicsr_zifencei ENABLE_VPU_SDK=0 ENABLE_ECC=0
- name: Checkout This Repo
uses: actions/checkout@v5
with:
fetch-depth: 1
submodules: true
path: u-boot-build
- name: Build Nsign
run: |
pushd u-boot-build/eswin-eic7700/
cmake -B build nsign
cmake --build build
popd
- name: Generate Firmware
run: |
pushd u-boot-build/eswin-eic7700/
./build/src/nsign bootchain.cfg
mv out/bootloader.bin out/bootloader-${{ matrix.board }}.bin
popd
- name: Upload Artifacts
id: upload-artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.board }}
path: u-boot-build/eswin-eic7700/out/bootloader-${{ matrix.board }}.bin
release:
name: Release Firmware for ESWin EIC7700
runs-on: ubuntu-latest
needs: build
# if: github.ref == 'refs/heads/master'
if: github.ref == 'refs/heads/enable_release'
permissions:
contents: write
steps:
- name: Fetch Artifact
uses: actions/download-artifact@v5
with:
merge-multiple: true
- name: Update Tag
uses: actions/github-script@v5
with:
script: |
github.rest.git.createRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: 'refs/tags/release-eswin-eic7700',
sha: context.sha
})
- name: Publish Release
uses: softprops/action-gh-release@v2
with:
name: Boot Firmware for ESWin EIC7700
tag_name: release-eswin-eic7700
body: "TBD"
files: ./*
make_latest: false