Skip to content

Commit

Permalink
Merge pull request #25 from oyama/feature/build-windows
Browse files Browse the repository at this point in the history
Create CMake windows
  • Loading branch information
oyama authored Jun 8, 2024
2 parents 2941c42 + 778c15e commit fb9eb76
Show file tree
Hide file tree
Showing 2 changed files with 58 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/choco_packages.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="gcc-arm-embedded" version="10.2.1" />
<package id="cmake" version="3.25.2" installArguments="ADD_CMAKE_TO_PATH=System" />
<package id="mingw" version="12.2.0" />
<package id="ninja" version="1.11.1" />
</packages>
51 changes: 51 additions & 0 deletions .github/workflows/cmake-windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Build on Windows
on:
workflow_dispatch:
push:
branches:
- 'test_workflow'
- 'main'
env:
BUILD_TYPE: Release

jobs:
build:
runs-on: windows-latest
steps:
- name: Clean workspace
shell: bash
run: |
echo "Cleaning up previous run"
rm -rf "${{ github.workspace }}/pico-sdk"
rm -rf "${{ github.workspace }}/pico-vfs"
- name: Checkout pico-sdk
uses: actions/checkout@v4
with:
repository: raspberrypi/pico-sdk
ref: master
path: pico-sdk
- name: Checkout pico-sdk submodules
working-directory: ${{github.workspace}}/pico-sdk
run: git submodule update --init

- name: Checkout pico-vfs
uses: actions/checkout@v4
with:
path: pico-vfs
- name: Checkout pico-vfs submodules
working-directory: ${{github.workspace}}/pico-vfs
run: git submodule update --init

- name: Install dependencies
working-directory: ${{github.workspace}}/pico-vfs
run: choco install .github/workflows/choco_packages.config

- name: Build firmware
working-directory: ${{github.workspace}}/pico-vfs
shell: bash
run: |
mkdir build
cd build
cmake .. -G Ninja -DPICO_SDK_PATH=../../pico-sdk -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DPICO_BOARD=pico
cmake --build . --target tests

0 comments on commit fb9eb76

Please sign in to comment.