Skip to content

Commit

Permalink
build ci:add msvc windows native ci workflow
Browse files Browse the repository at this point in the history
Signed-off-by: xuxin19 <[email protected]>
  • Loading branch information
xuxin930 committed Oct 9, 2024
1 parent 77821fb commit dc1a026
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -331,3 +331,43 @@ jobs:
name: msys2-${{matrix.boards}}-builds
path: buildartifacts/
continue-on-error: true

# Build with MSVC in Windows native
msvc:
needs: Fetch-Source
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
# Set up Python environment and install kconfiglib
- name: Set up Python and install kconfiglib
uses: actions/setup-python@v2
with:
python-version: '3.x' # specify the desired Python version
- name: Install kconfiglib
run: |
pip install kconfiglib
- run: git config --global core.autocrlf false

- name: Download Source Artifact
uses: actions/download-artifact@v4
with:
name: source-bundle
path: .

- name: Extract sources
run: 7z x sources.tar.gz -y

# Build the project using the given CMake commands
- name: Configure and build with CMake
run: |
dir
cd sources/nuttx
cmake -B vs2022 -DBOARD_CONFIG=sim/windows -G"Visual Studio 17 2022" -A Win32
cmake --build vs2022
- uses: actions/upload-artifact@v4
with:
name: msvc-builds
path: buildartifacts/
continue-on-error: true

0 comments on commit dc1a026

Please sign in to comment.