Skip to content

Commit 5582799

Browse files
committed
syntax
1 parent 07677fd commit 5582799

File tree

1 file changed

+69
-68
lines changed

1 file changed

+69
-68
lines changed

.github/actions/build-xbuildenv/action.yml

+69-68
Original file line numberDiff line numberDiff line change
@@ -5,81 +5,82 @@ description: This composite action encapsulates the build job for creating the c
55
on:
66
workflow_call:
77

8-
runs:
9-
using: "composite"
10-
steps:
11-
- uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
12-
with:
13-
python-version: "3.12"
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
13+
with:
14+
python-version: "3.12"
1415

15-
- uses: actions/setup-node@v4
16-
with:
17-
node-version: 22
16+
- uses: actions/setup-node@v4
17+
with:
18+
node-version: 22
1819

19-
- name: Install system-level dependencies
20-
run: |
21-
sudo apt-get update
22-
sudo apt-get install -y --no-install-recommends \
23-
cmake bzip2 ccache f2c g++ gfortran git make \
24-
patch pkg-config swig unzip wget xz-utils \
25-
autoconf autotools-dev automake texinfo dejagnu \
26-
build-essential libtool libltdl-dev \
27-
gnupg2 libdbus-glib-1-2 sudo sqlite3 \
28-
ninja-build jq xxd
20+
- name: Install system-level dependencies
21+
run: |
22+
sudo apt-get update
23+
sudo apt-get install -y --no-install-recommends \
24+
cmake bzip2 ccache f2c g++ gfortran git make \
25+
patch pkg-config swig unzip wget xz-utils \
26+
autoconf autotools-dev automake texinfo dejagnu \
27+
build-essential libtool libltdl-dev \
28+
gnupg2 libdbus-glib-1-2 sudo sqlite3 \
29+
ninja-build jq xxd
2930
30-
- name: Cache ccache outputs
31-
uses: actions/cache/restore@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
32-
with:
33-
path: /tmp/ccache
34-
key: ccache-${{ hashFiles('Makefile.envs') }}
31+
- name: Cache ccache outputs
32+
uses: actions/cache/restore@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
33+
with:
34+
path: /tmp/ccache
35+
key: ccache-${{ hashFiles('Makefile.envs') }}
3536

36-
- name: Check out Pyodide, and the NumPy v2 mirror branch
37-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
38-
with:
39-
repository: pyodide/pyodide
40-
ref: main
41-
path: pyodide_checkout
42-
submodules: recursive
37+
- name: Check out Pyodide, and the NumPy v2 mirror branch
38+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
39+
with:
40+
repository: pyodide/pyodide
41+
ref: main
42+
path: pyodide_checkout
43+
submodules: recursive
4344

44-
- name: Restore cached built packages
45-
uses: actions/cache/restore@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
46-
with:
47-
path: |
48-
pyodide_checkout/packages/.libs/*
49-
pyodide_checkout/packages/.artifacts/*
50-
pyodide_checkout/dist/*.whl
51-
key: pyodide-packages-${{ hashFiles('pyodide_checkout/packages/recipes/**/*.yaml') }}
45+
- name: Restore cached built packages
46+
uses: actions/cache/restore@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
47+
with:
48+
path: |
49+
pyodide_checkout/packages/.libs/*
50+
pyodide_checkout/packages/.artifacts/*
51+
pyodide_checkout/dist/*.whl
52+
key: pyodide-packages-${{ hashFiles('pyodide_checkout/packages/recipes/**/*.yaml') }}
5253

53-
- run: echo "PYODIDE_JOBS=$(nproc)" >> "$GITHUB_ENV"
54+
- run: echo "PYODIDE_JOBS=$(nproc)" >> "$GITHUB_ENV"
5455

55-
- name: Build Pyodide packages with NumPy v2 enabled
56-
working-directory: pyodide_checkout/
57-
run: |
58-
source pyodide_env.sh
59-
ccache -z
60-
make -C emsdk
61-
make -C cpython
62-
pip install -e ./pyodide-build
63-
PYODIDE_PACKAGES="numpy,scipy,cffi" make
64-
ccache -s
56+
- name: Build Pyodide packages with NumPy v2 enabled
57+
working-directory: pyodide_checkout/
58+
run: |
59+
source pyodide_env.sh
60+
ccache -z
61+
make -C emsdk
62+
make -C cpython
63+
pip install -e ./pyodide-build
64+
PYODIDE_PACKAGES="numpy,scipy,cffi" make
65+
ccache -s
6566
66-
- name: Save ccached outputs
67-
uses: actions/cache/save@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
68-
with:
69-
path: /tmp/ccache
70-
key: ccache-${{ hashFiles('Makefile.envs') }}
67+
- name: Save ccached outputs
68+
uses: actions/cache/save@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
69+
with:
70+
path: /tmp/ccache
71+
key: ccache-${{ hashFiles('Makefile.envs') }}
7172

72-
- name: Create cross-build environment
73-
working-directory: pyodide_checkout/
74-
run: |
75-
python tools/create_xbuildenv.py .
76-
tar cjf xbuildenv.tar.bz2 ./xbuildenv/
73+
- name: Create cross-build environment
74+
working-directory: pyodide_checkout/
75+
run: |
76+
python tools/create_xbuildenv.py .
77+
tar cjf xbuildenv.tar.bz2 ./xbuildenv/
7778
78-
- name: Upload cross-build environment
79-
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
80-
with:
81-
name: cross-build-env
82-
path: |
83-
pyodide_checkout/xbuildenv.tar.bz2
84-
if-no-files-found: error
85-
retention-days: 1
79+
- name: Upload cross-build environment
80+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
81+
with:
82+
name: cross-build-env
83+
path: |
84+
pyodide_checkout/xbuildenv.tar.bz2
85+
if-no-files-found: error
86+
retention-days: 1

0 commit comments

Comments
 (0)