Skip to content

Commit

Permalink
DNM: Use the includes from mithro/actions.
Browse files Browse the repository at this point in the history
Signed-off-by: Tim 'mithro' Ansell <[email protected]>
  • Loading branch information
mithro committed Mar 8, 2021
1 parent ce32b75 commit 6104e2a
Show file tree
Hide file tree
Showing 3 changed files with 122 additions and 147 deletions.
92 changes: 21 additions & 71 deletions .github/workflows-src/publish-to-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,103 +13,53 @@ on:
pull_request:
workflow_dispatch:


jobs:

Source:
name: Source
runs-on: ubuntu-20.04

steps:
- includes: /system-setup
with:
packaging-tools: true

- name: Install package
run: |
pip install -e .
- name: 🚧 Build distribution 📦
run: |
python -m build --sdist .
- includes: /upload-to-pypi
- includes: mithro/actions/includes/python/publish-to-pypi-src@main
with:
root_repo: SymbiFlow/fasm
type: source
root_user: SymbiFlow

Linux:
Wheels-Linux:
strategy:
matrix:
include:
- { python-version: '3.6', manylinux-python: 'cp36-cp36m' }
- { python-version: '3.7', manylinux-python: 'cp37-cp37m' }
- { python-version: '3.8', manylinux-python: 'cp38-cp38' }
- { python-version: '3.9', manylinux-python: 'cp39-cp39' }
python-version: [ '3.6', '3.7', '3.8', '3.9' ]
fail-fast: false

name: '${{ matrix.python-version }} • manylinux'
runs-on: ubuntu-latest
runs-on: ubuntu-20.04

steps:
- includes: /system-setup
with:
python-version: ${{ matrix.python-version }}
system-dependencies: false
packaging-tools: true
- includes: /checkout

- name: 🚧 Build distribution 📦
uses: RalfG/[email protected]_x86_64
- includes: mithro/actions/includes/python/publish-to-pypi-wheels-bin-linux@main
with:
build-requirements: 'cython'
pre-build-command: 'bash .github/workflows/manylinux-install-cmake.sh'
python-versions: ${{ matrix.manylinux-python }}
#pip-wheel-args: '-w ./dist --no-deps --verbose'

- name: List distribution 📦
run: |
# Fix permissions
echo "::group::Fixing permission"
ls -l dist/*
echo $USER
whoami
sudo chown -R $USER dist
ls -l dist/*
echo "::endgroup::"
# Remove the non-manylinux versions
rm -v dist/*linux_x86_64*.whl
ls -l dist/*
- includes: /upload-to-pypi
with:
root_repo: SymbiFlow/fasm
type: wheels
pre-build-command: bash .github/workflows/manylinux-install-cmake.sh
build-requirements: cython
system-packages: java-1.8.0-openjdk uuid uuid-devel libuuid libuuid-devel git
python-version: ${{ matrix.python-version }}
package-path: ''
root_user: SymbiFlow

MacAndWindows:
Wheels-Other:
strategy:
matrix:
os: [windows-latest, macos-latest]
python-version: [ '3.6', '3.7', '3.8', '3.9', 'pypy-3.6', 'pypy-3.7' ]
python-version: [ '3.6', '3.7', '3.8', '3.9' ]
fail-fast: false

name: ${{ matrix.python-version }} • ${{ matrix.os }}
name: '${{ matrix.python-version }} • ${{ matrix.os }}'
runs-on: ${{ matrix.os }}

steps:
- includes: /system-setup
with:
os: ${{ matrix.os }}
python-version: ${{ matrix.python-version }}
packaging-tools: true

- name: Install package
run: |
pip install -e .
- includes: /checkout

- name: 🚧 Build distribution 📦
run: |
python setup.py bdist_wheel
- includes: /upload-to-pypi
- includes: mithro/actions/includes/python/publish-to-pypi-wheels-bin-other@main
with:
root_repo: SymbiFlow/fasm
type: wheels
python-version: ${{ matrix.python-version }}
root_user: SymbiFlow
2 changes: 0 additions & 2 deletions .github/workflows/manylinux-install-cmake.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ yum remove cmake -y
# Add in curl
yum install wget -y

yum install java-1.8.0-openjdk uuid uuid-devel libuuid libuuid-devel -y

# Download new cmake
wget https://github.com/Kitware/CMake/releases/download/v3.19.4/cmake-3.19.4-Linux-x86_64.sh -O /tmp/cmake.sh
chmod a+x /tmp/cmake.sh
Expand Down
Loading

0 comments on commit 6104e2a

Please sign in to comment.