Skip to content

Commit

Permalink
Add a new job to build and test cross-builds in the JIT workflow
Browse files Browse the repository at this point in the history
* **Cross-Build Job**
  - Add a new job named `Cross-Builds` to the JIT workflow
  - Checkout code using `actions/checkout@v2`
  - Set up Python using `actions/setup-python@v2`
  - Install build-essential dependencies
  - Build host Python and install it
  - Configure cross-build with the host Python
  - Run tests in the build directory
  - Install cross-build
  - Run tests with the installed Python
  • Loading branch information
gianfrancomauro committed Nov 30, 2024
1 parent 7aa74e3 commit 29d2791
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/jit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -167,3 +167,38 @@ jobs:
- name: Run tests
run: |
./python -m test --multiprocess 0 --timeout 4500 --verbose2 --verbose3
cross-build:
name: Cross-Builds
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'

- name: Install dependencies
run: sudo apt-get install -y build-essential

- name: Build host Python
run: |
./configure --prefix=$PWD/workdir/host-python
make -j4
make install
- name: Configure cross-build
run: |
./configure --with-build-python=$PWD/workdir/host-python/bin/python --prefix=$PWD/workdir/cross-python
make -j4
- name: Run tests in build directory
run: ./python -m test test_sysconfig test_site test_embed

- name: Install cross-build
run: make install

- name: Run tests with installed Python
run: $PWD/workdir/cross-python/bin/python -m test test_sysconfig test_site test_embed

0 comments on commit 29d2791

Please sign in to comment.