fix a bug in MemoryModule.c:PerformBaseRelocation #337
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: [push, pull_request] | |
jobs: | |
matrix: | |
name: Generate matrix | |
runs-on: ubuntu-latest | |
outputs: | |
matrix: ${{ steps.set-matrix.outputs.matrix }} | |
steps: | |
- uses: actions/checkout@v4 | |
- id: set-matrix | |
run: | | |
TASKS=$(echo $(cat .github/workflows/matrix.json) | sed 's/ //g' ) | |
echo "matrix=$TASKS" >> $GITHUB_OUTPUT | |
sdist: | |
name: Source distribution | |
runs-on: windows-2019 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.8' | |
- name: Check Python install | |
run: | | |
which python | |
python --version | |
python -c "import struct; print(struct.calcsize('P') * 8)" | |
which pip | |
pip --version | |
- name: Install Python dependencies | |
run: | | |
python -m pip install -U pip setuptools wheel | |
python -m pip install -U cachetools pefile | |
- name: Build | |
run: python setup.py sdist | |
- name: Prepare for deployment | |
run: | | |
dir dist | |
Get-ChildItem dist -File | Foreach-Object {$sdistname = $_.Name} | |
echo $sdistname | |
echo "SDISTNAME=$sdistname" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
- name: Deploy | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ env.SDISTNAME }} | |
path: | | |
dist/${{ env.SDISTNAME }} | |
build: | |
needs: matrix | |
name: Build | |
runs-on: windows-2019 | |
strategy: | |
matrix: | |
cfg: ${{ fromJson(needs.matrix.outputs.matrix) }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.cfg.python-version }} | |
architecture: ${{ matrix.cfg.python-arch }} | |
- name: Check Python install | |
run: | | |
which python | |
python --version | |
python -c "import struct; print(struct.calcsize('P') * 8)" | |
which pip | |
pip --version | |
- name: Install Python dependencies | |
run: | | |
python -m pip install -U pip setuptools wheel | |
python -m pip install -U cachetools pefile | |
- name: Build | |
run: | | |
python setup.py bdist_wheel | |
- name: Prepare for deployment | |
run: | | |
dir dist | |
$ver = (findstr __version__ .\py2exe\version.py).split("'")[1] | |
echo $ver | |
echo "VER=$ver" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
$wheelname = python .github\helpers\get_wheel_name.py $ver | |
echo $wheelname | |
echo "WHEELNAME=$wheelname" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
- name: Deploy | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ env.WHEELNAME }} | |
path: | | |
dist/${{ env.WHEELNAME }} | |
test: | |
needs: [matrix, build] | |
name: Test | |
runs-on: windows-2022 | |
strategy: | |
matrix: | |
cfg: ${{ fromJson(needs.matrix.outputs.matrix) }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.cfg.python-version }} | |
architecture: ${{ matrix.cfg.python-arch }} | |
- name: Check Python install | |
run: | | |
which python | |
python --version | |
python -c "import struct; print(struct.calcsize('P') * 8)" | |
which pip | |
pip --version | |
- name: Install Python dependencies | |
run: | | |
python -m pip install -U pip setuptools wheel | |
- name: Prepare for test | |
run: | | |
$ver = (findstr __version__ .\py2exe\version.py).split("'")[1] | |
echo $ver | |
echo "VER=$ver" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
$wheelname = python .github\helpers\get_wheel_name.py $ver | |
echo $wheelname | |
echo "WHEELNAME=$wheelname" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
- name: Download artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
name: ${{ env.WHEELNAME }} | |
- name: Install | |
run: | | |
dir | |
pip install ${{ env.WHEELNAME }} | |
python -c "import py2exe" | |
- name: Test (synthetic) | |
run: | | |
cd tests | |
python test_modulefinder.py | |
- name: Test (functional) | |
if: ${{ matrix.cfg.run-tests == 'true' }} | |
run: | | |
cd tests | |
cd functional | |
python .\enable_tests.py | |
.\runner_freeze.ps1 |