-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
cecdba0
commit 8e1f377
Showing
2 changed files
with
120 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
# SPDX-FileCopyrightText: 2025 Ledger SAS | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
name: Sentry kernel build on Windows | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
# using /home/build as home, as buildbot is using user build. Cache is still in /cache | ||
# This allows the usage of automated ssh key installation step | ||
|
||
jobs: | ||
build: | ||
name: build | ||
defaults: | ||
run: | ||
shell: bash | ||
runs-on: windows-latest | ||
steps: | ||
- name: install prerequisites pkg | ||
uses: msys2/setup-msys2@v2 | ||
with: | ||
msystem: MINGW64 | ||
update: true | ||
install: >- | ||
base-devel | ||
git | ||
wget | ||
curl | ||
dtc | ||
libssh2 | ||
python | ||
python-pip | ||
- name: XXX git permission quirk XXX | ||
run: | | ||
git config --global --add safe.directory $GITHUB_WORKSPACE | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
fetch-tags: true | ||
set-safe-directory: true | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.12' | ||
- name: Clone cross-files | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: 'main' | ||
repository: 'outpost-os/meson-cross-files' | ||
path: crossfiles | ||
- name: Setup Rust toolchain | ||
uses: dtolnay/rust-toolchain@v1 | ||
with: | ||
toolchain: nightly | ||
targets: thumbv7m-none-eabi,thumbv7em-none-eabi,thumbv7em-none-eabihf | ||
components: clippy,rustfmt | ||
- name: Setup C toolchain | ||
uses: outpost-os/action-setup-compiler@v1 | ||
with: | ||
compiler: gcc | ||
triple: arm-none-eabi | ||
ref: 13.2.Rel1 | ||
workspace: $GITHUB_WORKSPACE | ||
- name: deploy local deps | ||
run: | | ||
pip config set global.break-system-packages true | ||
pip install --user -r requirements.txt | ||
shell: msys2 {0} | ||
- name: defconfig | ||
run: | | ||
defconfig configs/nucleo_u5a5_autotest_defconfig | ||
shell: msys2 {0} | ||
- name: Meson Build | ||
uses: outpost-os/action-meson@main | ||
with: | ||
cross_files: 'support/meson/msys2.ini' | ||
actions: '["prefetch", "setup", "compile"]' | ||
options: '-Dconfig=.config -Ddts=dts/examples/$nucleo_u5a5_autotest.dts -Ddts-include-dirs=dts' | ||
shell: msys2 {0} | ||
- name: Meson postcheck | ||
if: failure() | ||
run: | | ||
cat builddir/meson-logs/meson-log.txt |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
[constants] | ||
# Gcc triple, no diff between various arm-none-eabi targets, using | ||
# supplementary arguments to precise | ||
cross_triple = 'arm-none-eabi' | ||
# llvm triple, target-explicit, needed by Rust | ||
cross_toolchain = 'C:\Users\runneradmin\gcc-arm-none-eabi-13.2.1-win32-x64\arm-gnu-toolchain-13.2.Rel1-mingw-w64-i686-arm-none-eabi\' | ||
cross_compile = cross_toolchain + 'bin\' + cross_triple + '-' | ||
[host_machine] | ||
system = 'baremetal' | ||
cpu_family = 'arm' | ||
cpu = 'cortex-m4' | ||
endian = 'little' | ||
exe_wrapper = 'qemu-arm-static' | ||
[binaries] | ||
c = cross_compile + 'gcc' | ||
cpp = cross_compile + 'g++' | ||
ar = cross_compile + 'gcc-ar' | ||
ranlib = cross_compile + 'gcc-ranlib' | ||
strip = cross_compile + 'strip' | ||
objcopy = cross_compile + 'objcopy' | ||
clang = 'clang' | ||
rust_ld = 'gcc' | ||
rust = 'rustc' | ||
pkg-config = 'pkg-config' | ||
[properties] | ||
sysroot = cross_toolchain + cross_triple |