Enable Ubuntu 22.04 builds #77
Workflow file for this run
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: Build and Publish wheels for AD-Map Library | |
on: | |
release: | |
types: [published] | |
push: | |
branches: master | |
pull_request: | |
branches: master | |
jobs: | |
wheels: | |
runs-on: ubuntu-20.04 | |
strategy: | |
matrix: | |
python_binding_version: [2.7, 3.6, 3.7, 3.8] | |
container: | |
image: joelmb/map:${{ matrix.python_binding_version }} | |
env: | |
WHEEL_PLATFORM: manylinux_2_27_x86_64 | |
PYTHON_BINDING_VERSION: ${{ matrix.python_binding_version }} | |
steps: | |
# We currently cannot use checkout@v2 because git version on the docker images is below 2.18 | |
- uses: actions/checkout@v1 | |
with: | |
fetch-depth: 1 | |
submodules: true | |
- name: Build wheels | |
shell: bash | |
run: | | |
apt update && apt install sqlite3 -y | |
colcon build --packages-select PROJ4 --event-handlers console_direct+ --cmake-args -DCMAKE_POSITION_INDEPENDENT_CODE=ON | |
source install/setup.bash | |
colcon build --packages-up-to ad_map_access --meta colcon_python.meta --event-handlers console_direct+ --cmake-args -DPYTHON_BINDING_VERSION=${PYTHON_BINDING_VERSION} | |
- name: Repair wheels | |
shell: bash | |
run: | | |
source install/setup.bash | |
for whl in install/ad_physics/dist/*.whl; do | |
auditwheel repair $whl --plat ${WHEEL_PLATFORM} --wheel-dir wheelhouse | |
done | |
for whl in install/ad_map_access/dist/*.whl; do | |
auditwheel repair $whl --plat ${WHEEL_PLATFORM} --wheel-dir wheelhouse | |
done | |
- name: Publish wheels to PyPI | |
uses: pypa/gh-action-pypi-publish@release/v1 | |
if: ${{ github.event_name == 'release'}} | |
with: | |
user: __token__ | |
password: ${{ secrets.PYPI_API_TOKEN }} | |
packages_dir: wheelhouse/ |