Skip to content

Commit 119da09

Browse files
committed
CI: Try setup Unix build with emlearn_trees as USER_C_MODULE
1 parent 92cddf7 commit 119da09

File tree

2 files changed

+33
-3
lines changed

2 files changed

+33
-3
lines changed

.github/workflows/build.yaml

+31-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,37 @@ name: Build modules
44
on: [push, pull_request]
55

66
jobs:
7-
test:
7+
8+
test_static:
9+
permissions:
10+
contents: write
11+
runs-on: ubuntu-24.04
12+
env:
13+
MPY_DIR: ./micropython
14+
MICROPYTHON_BIN: ./micropython/ports/unix/build-standard/micropython
15+
steps:
16+
- uses: actions/checkout@v4
17+
with:
18+
submodules: true
19+
- name: Install OS dependencies
20+
run: sudo add-apt-repository universe
21+
- uses: actions/setup-python@v5
22+
with:
23+
python-version: '3.10'
24+
- uses: actions/checkout@v4
25+
with:
26+
repository: jonnor/micropython
27+
path: micropython
28+
ref: v1.25preview-linking
29+
- name: Install Python dependencies
30+
run: pip install -r requirements.txt
31+
- name: Setup MicroPython X86
32+
working-directory: micropython
33+
run: source tools/ci.sh && ci_unix_32bit_setup && ci_unix_build_helper VARIANT=standard USER_C_MODULES=`pwd`/src/
34+
- name: Run test on x64
35+
run: make emlearn_trees.results V=1
36+
37+
test_dynamic:
838
permissions:
939
contents: write
1040
runs-on: ubuntu-24.04

Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ $(MODULES_PATH)/emlearn_iir_q15.mpy:
3737
$(MODULES_PATH)/emlearn_arrayutils.mpy:
3838
make -C src/emlearn_arrayutils/ ARCH=$(ARCH) MPY_DIR=$(MPY_DIR_ABS) V=1 clean dist
3939

40-
emlearn_trees.results: $(MODULES_PATH)/emlearn_trees.mpy
41-
MICROPYPATH=$(MODULES_PATH) $(MICROPYTHON_BIN) tests/test_trees.py
40+
emlearn_trees.results:
41+
$(MICROPYTHON_BIN) tests/test_trees.py
4242

4343
emlearn_neighbors.results: $(MODULES_PATH)/emlearn_neighbors.mpy
4444
MICROPYPATH=$(MODULES_PATH) $(MICROPYTHON_BIN) tests/test_neighbors.py

0 commit comments

Comments
 (0)