forked from libyal/libpff
-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (48 loc) · 1.73 KB
/
build_wheel.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: build_wheel
on: [push, pull_request]
permissions: read-all
jobs:
build_wheel:
runs-on: ubuntu-22.04
strategy:
matrix:
include:
- python-version: '3.9'
- python-version: '3.12'
steps:
- uses: actions/checkout@v4
- name: Install build dependencies
run: |
sudo add-apt-repository universe &&
sudo add-apt-repository -y ppa:deadsnakes/ppa &&
sudo apt-get update &&
sudo apt-get install -y autoconf automake autopoint build-essential git libtool pkg-config python${{ matrix.python-version }} python${{ matrix.python-version }}-dev python${{ matrix.python-version }}-venv python3-distutils python3-pip python3-setuptools
- name: Download test data
run: |
if test -x "synctestdata.sh"; then ./synctestdata.sh; fi
- name: Prepare build
run: |
./synclibs.sh --use-head && ./autogen.sh && ./configure && make sources >/dev/null
- name: Create virtual environment
run: |
rm -rf venv
python${{ matrix.python-version }} -m venv venv
echo "$(pwd)/venv/bin" >> $GITHUB_PATH
- name: Install Python dependencies
run: |
python -m pip install \
'build' \
'mypy' \
'setuptools>=65' \
'wheel'
- name: Build libpff-python wheel
run: |
python -m build --no-isolation --outdir=dist --wheel
python -m pip install --no-index --find-links=dist libpff-python
python tests/runtests.py
- name: Build pypff-stubs wheel
working-directory: stubs
run: |
python -m build --outdir=dist --wheel
python -m pip install --no-index --find-links=dist pypff-stubs
mypy --strict -c 'import pypff; reveal_type(pypff.file)'