ci: use python venv for firmware builds
This commit is contained in:
14
.github/workflows/build.yml
vendored
14
.github/workflows/build.yml
vendored
@ -150,18 +150,23 @@ jobs:
|
|||||||
- name: Install dependencies (macOS)
|
- name: Install dependencies (macOS)
|
||||||
run: |
|
run: |
|
||||||
brew install dfu-util
|
brew install dfu-util
|
||||||
pip3 install PyYAML
|
python3 -m venv environment && source environment/bin/activate
|
||||||
|
python3 -m pip install PyYAML
|
||||||
if: matrix.os == 'macos-latest'
|
if: matrix.os == 'macos-latest'
|
||||||
|
|
||||||
- name: Install dependencies (Ubuntu)
|
- name: Install dependencies (Ubuntu)
|
||||||
run: |
|
run: |
|
||||||
|
python3 -m venv environment && source environment/bin/activate
|
||||||
|
python3 -m pip install PyYAML
|
||||||
sudo apt install dfu-util
|
sudo apt install dfu-util
|
||||||
if: matrix.os == 'ubuntu-latest'
|
if: matrix.os == 'ubuntu-latest'
|
||||||
|
|
||||||
- name: Build libopencm3
|
- name: Build libopencm3
|
||||||
shell: bash
|
shell: bash
|
||||||
working-directory: ${{github.workspace}}/firmware/libopencm3/
|
working-directory: ${{github.workspace}}/firmware/libopencm3/
|
||||||
run: make
|
run: |
|
||||||
|
source ../../environment/bin/activate
|
||||||
|
make
|
||||||
|
|
||||||
- name: Create Build Environment
|
- name: Create Build Environment
|
||||||
run: cmake -E make_directory ${{github.workspace}}/firmware/build
|
run: cmake -E make_directory ${{github.workspace}}/firmware/build
|
||||||
@ -174,5 +179,6 @@ jobs:
|
|||||||
- name: Build
|
- name: Build
|
||||||
working-directory: ${{github.workspace}}/firmware/build
|
working-directory: ${{github.workspace}}/firmware/build
|
||||||
shell: bash
|
shell: bash
|
||||||
run: cmake --build . --config Release
|
run: |
|
||||||
|
source ../../environment/bin/activate
|
||||||
|
cmake --build . --config Release
|
||||||
|
Reference in New Issue
Block a user