Skip to content

Commit 017a788

Browse files
authored
Merge pull request #23 from PyO3/pypy
Collect PyPy DLLs
2 parents 45a450c + 8d7c767 commit 017a788

File tree

2 files changed

+25
-7
lines changed

2 files changed

+25
-7
lines changed

.github/workflows/dll.yml

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,29 +10,47 @@ jobs:
1010
name: Collect pythonXY.dll
1111
runs-on: windows-latest
1212
steps:
13-
- uses: actions/setup-python@v2
13+
- uses: actions/setup-python@v4
14+
with:
15+
python-version: "pypy3.8"
16+
- uses: actions/setup-python@v4
17+
with:
18+
python-version: "pypy3.9"
19+
- uses: actions/setup-python@v4
1420
with:
1521
python-version: "3.7"
16-
- uses: actions/setup-python@v2
22+
- uses: actions/setup-python@v4
1723
with:
1824
python-version: "3.8"
19-
- uses: actions/setup-python@v2
25+
- uses: actions/setup-python@v4
2026
with:
2127
python-version: "3.9"
22-
- uses: actions/setup-python@v2
28+
- uses: actions/setup-python@v4
2329
with:
2430
python-version: "3.10"
25-
- uses: actions/setup-python@v2
31+
- uses: actions/setup-python@v4
2632
with:
2733
python-version: "3.11-dev"
2834
- name: Copy pythonXY.dll
2935
shell: bash
3036
run: |
37+
set -e
3138
for VER in 3.7 3.8 3.9 3.10 3.11; do
3239
VER_NUM=$(echo $VER | sed 's/\.//')
3340
PREFIX=$(py -$VER -c "import sys; print(sys.base_prefix, end='')")
3441
cp "$PREFIX/python$VER_NUM.dll" .
3542
done
43+
44+
# PyPy 3.7 & 3.8 uses libpypy3-c.dll
45+
PREFIX=$(pypy3.8 -c "import sys; print(sys.base_prefix, end='')")
46+
cp "$PREFIX/libpypy3-c.dll" .
47+
48+
# PyPy 3.9 and later use libpypy3.Y-c.dll
49+
for VER in 3.9; do
50+
VER_NUM=$(echo $VER | sed 's/\.//')
51+
PREFIX=$(pypy$VER -c "import sys; print(sys.base_prefix, end='')")
52+
cp "$PREFIX/libpypy$VER-c.dll" .
53+
done
3654
ls *.dll
3755
- name: Upload DLLs
3856
uses: actions/upload-artifact@v2

.github/workflows/update.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ jobs:
5454
shell: bash
5555
run: |
5656
set -e
57-
for f in dll/python*.dll; do
57+
for f in dll/*.dll; do
5858
gendef $f
5959
done
6060
ls -lrth *.def
@@ -65,6 +65,6 @@ jobs:
6565
branch: update-pythonxy
6666
delete-branch: true
6767
add-paths: |
68-
src/python*.def
68+
src/*.def
6969
title: 'Update pythonXY.def'
7070
commit-message: 'chore: Update pythonXY.def'

0 commit comments

Comments
 (0)