mirror of
https://github.com/myhdl/myhdl.git
synced 2024-12-14 07:44:38 +08:00
Add windows actions, python3.11 for core and ghdl (#410)
* Add initial actions for winows, include core and ghdl, iverilog is not working yet * Rename some steps to show linux providence * Rename some steps to show linux providence
This commit is contained in:
parent
35bd903371
commit
5ec3d08d2e
92
.github/workflows/test_checkin.yml
vendored
92
.github/workflows/test_checkin.yml
vendored
@ -22,23 +22,22 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
pyflakes myhdl
|
pyflakes myhdl
|
||||||
|
|
||||||
build_ghdl:
|
build_ghdl_linux:
|
||||||
#uses: daxzio/setup-eda/.github/workflows/setup_ghdl.yml@main
|
#uses: daxzio/setup-eda/.github/workflows/setup_ghdl.yml@main
|
||||||
uses: ./.github/workflows/setup_ghdl.yml
|
uses: ./.github/workflows/setup_ghdl.yml
|
||||||
build_iverilog:
|
build_iverilog_linux:
|
||||||
#uses: daxzio/setup-eda/.github/workflows/setup_iverilog.yml@main
|
#uses: daxzio/setup-eda/.github/workflows/setup_iverilog.yml@main
|
||||||
uses: ./.github/workflows/setup_iverilog.yml
|
uses: ./.github/workflows/setup_iverilog.yml
|
||||||
|
|
||||||
build_code:
|
build_code_linux:
|
||||||
|
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false # So that one fail doesn't stop remaining tests
|
fail-fast: false # So that one fail doesn't stop remaining tests
|
||||||
matrix:
|
matrix:
|
||||||
python-version: ["3.7", "3.8", "3.9", "3.10", "pypy-3.9", "3.11"]
|
python-version: ["3.7", "3.8", "3.9", "3.10", "pypy-3.9", "3.11"]
|
||||||
os: [ubuntu-latest]
|
|
||||||
target: [core, iverilog, ghdl]
|
target: [core, iverilog, ghdl]
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ubuntu-latest
|
||||||
needs: [run_lint, build_ghdl, build_iverilog]
|
needs: [run_lint, build_ghdl_linux, build_iverilog_linux]
|
||||||
|
|
||||||
env:
|
env:
|
||||||
CI_TARGET: ${{ matrix.target }}
|
CI_TARGET: ${{ matrix.target }}
|
||||||
@ -46,32 +45,33 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
|
- name: Report Environment
|
||||||
|
run: |
|
||||||
|
echo "Runing tests with env set to : ${CI_TARGET}"
|
||||||
- name: Cache GHDL
|
- name: Cache GHDL
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
path: ${{ needs.build_ghdl.outputs.cache_dir }}
|
path: ${{ needs.build_ghdl_linux.outputs.cache_dir }}
|
||||||
key: ${{ needs.build_ghdl.outputs.cache_key }}
|
key: ${{ needs.build_ghdl_linux.outputs.cache_key }}
|
||||||
- name: Cache Icarus
|
- name: Cache Icarus
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
path: ${{ needs.build_iverilog.outputs.cache_dir }}
|
path: ${{ needs.build_iverilog_linux.outputs.cache_dir }}
|
||||||
key: ${{ needs.build_iverilog.outputs.cache_key }}
|
key: ${{ needs.build_iverilog_linux.outputs.cache_key }}
|
||||||
- name: Add to PATH
|
- name: Add to PATH
|
||||||
run: |
|
run: |
|
||||||
echo "${{ needs.build_ghdl.outputs.cache_dir }}/bin" >> $GITHUB_PATH
|
echo "${{ needs.build_ghdl_linux.outputs.cache_dir }}/bin" >> $GITHUB_PATH
|
||||||
echo "${{ needs.build_iverilog.outputs.cache_dir }}/bin" >> $GITHUB_PATH
|
echo "${{ needs.build_iverilog_linux.outputs.cache_dir }}/bin" >> $GITHUB_PATH
|
||||||
- name: Set up Python ${{ matrix.python-version }}
|
- name: Set up Python ${{ matrix.python-version }}
|
||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: ${{ matrix.python-version }}
|
python-version: ${{ matrix.python-version }}
|
||||||
|
cache: 'pip'
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
python -m pip install --upgrade pip
|
python -m pip install --upgrade pip
|
||||||
python -m pip install --upgrade -r requirements.txt
|
python -m pip install --upgrade -r requirements.txt
|
||||||
python -m pip install .
|
python -m pip install .
|
||||||
- name: Report Environment
|
|
||||||
run: |
|
|
||||||
echo "Runing tests with env set to : ${CI_TARGET}"
|
|
||||||
- name: Install depenacy for ghdl
|
- name: Install depenacy for ghdl
|
||||||
if: ${{ env.CI_TARGET == 'ghdl' }}
|
if: ${{ env.CI_TARGET == 'ghdl' }}
|
||||||
run: |
|
run: |
|
||||||
@ -80,10 +80,70 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
make ${CI_TARGET}
|
make ${CI_TARGET}
|
||||||
|
|
||||||
|
build_code_windows:
|
||||||
|
|
||||||
|
strategy:
|
||||||
|
fail-fast: false # So that one fail doesn't stop remaining tests
|
||||||
|
matrix:
|
||||||
|
python-version: ["3.11"]
|
||||||
|
#target: [core, iverilog, ghdl]
|
||||||
|
target: [core, ghdl]
|
||||||
|
runs-on: windows-latest
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
shell: msys2 {0}
|
||||||
|
needs: [run_lint]
|
||||||
|
|
||||||
|
env:
|
||||||
|
CI_TARGET: ${{ matrix.target }}
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- uses: msys2/setup-msys2@v2
|
||||||
|
with:
|
||||||
|
msystem: MINGW64
|
||||||
|
path-type: inherit
|
||||||
|
update: true
|
||||||
|
pacboy: >-
|
||||||
|
make:p
|
||||||
|
- name: Report Environment
|
||||||
|
run: |
|
||||||
|
echo "Runing tests with env set to : ${{ env.CI_TARGET }}"
|
||||||
|
|
||||||
|
- if: ${{ env.CI_TARGET == 'ghdl' }}
|
||||||
|
uses: ghdl/setup-ghdl-ci@nightly
|
||||||
|
with:
|
||||||
|
backend: llvm
|
||||||
|
- if: ${{ env.CI_TARGET == 'iverilog' }}
|
||||||
|
name: Choco iverilog
|
||||||
|
run: |
|
||||||
|
choco install --yes ${{ env.CI_TARGET }}
|
||||||
|
- if: ${{ env.CI_TARGET == 'iverilog' }}
|
||||||
|
name: Compile vpi
|
||||||
|
run: |
|
||||||
|
make iverilog_myhdl.vpi
|
||||||
|
- name: Set up Python ${{ matrix.python-version }}
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: ${{ matrix.python-version }}
|
||||||
|
cache: 'pip'
|
||||||
|
- name: Set environment variables
|
||||||
|
run: |
|
||||||
|
echo "${{ env.pythonLocation }}\bin" >> $GITHUB_PATH
|
||||||
|
echo "C:\ProgramData\Chocolatey\bin" >> $GITHUB_PATH
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
python -m pip install --upgrade pip
|
||||||
|
python -m pip install --upgrade -r requirements.txt
|
||||||
|
python -m pip install .
|
||||||
|
- name: Run Tests
|
||||||
|
run: |
|
||||||
|
make ${{ env.CI_TARGET }}
|
||||||
|
|
||||||
pypy_release:
|
pypy_release:
|
||||||
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
|
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [build_code]
|
needs: [build_code_linux, build_code_windows]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: Make PyPi dist release
|
- name: Make PyPi dist release
|
||||||
|
Loading…
x
Reference in New Issue
Block a user