Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
maxime-desroches committed Jul 20, 2024
1 parent b5f49d1 commit c62a75a
Show file tree
Hide file tree
Showing 6 changed files with 40 additions and 35 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@ jobs:
- name: Installing ubuntu requirements
if: ${{startsWith(matrix.os, 'ubuntu')}}
run:
sudo apt-get install -y --no-install-recommends clang libeigen3-dev
scripts/ubuntu_dependencies.sh
- name: Installing macos requirements
if: ${{startsWith(matrix.os, 'macos')}}
run:
brew install eigen && brew install --cask gcc-arm-embedded && brew install gcc@13
scripts/macos_dependencies.sh
- name: Building
run: scons -j$(nproc || sysctl -n hw.logicalcpu)

Expand All @@ -55,11 +55,11 @@ jobs:
- name: Installing ubuntu requirements
if: ${{startsWith(matrix.os, 'ubuntu')}}
run:
sudo apt-get install -y --no-install-recommends clang libeigen3-dev
scripts/ubuntu_dependencies.sh
- name: Installing macos requirements
if: ${{startsWith(matrix.os, 'macos')}}
run:
brew install eigen && brew install --cask gcc-arm-embedded && brew install gcc@13
scripts/macos_dependencies.sh
- name: Installing rednose
run: pip install -e .[dev]
- name: Running all tests
Expand Down
19 changes: 18 additions & 1 deletion .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,24 @@ jobs:
CIBW_BUILD: "${{ matrix.python.cp }}-${{ matrix.platform.target }}"
CIBW_ARCHS: "${{ matrix.platform.arch }}"
CIBW_BEFORE_ALL_LINUX: "dnf install -y clang libffi-devel eigen3-devel python${{ matrix.python.py }}-devel"
CIBW_BEFORE_BUILD_MACOS: "brew install eigen && brew install --cask gcc-arm-embedded && brew install gcc@13"
CIBW_BEFORE_BUILD_MACOS: {project}/scripts/macos_dependencies.sh
CIBW_MANYLINUX_X86_64_IMAGE: "manylinux_2_28"
CIBW_MANYLINUX_AARCH64_IMAGE: "manylinux_2_28"
CIBW_TEST_COMMAND: pip install -r {project}/requirements.txt && pytest {package}


- uses: actions/setup-python@v5
if: ${{ matrix.platform.arch }} != 'aarch64'
with:
python-version: ${{ matrix.python.py }}

- name: Installing the wheel
if: ${{ matrix.platform.arch }} != 'aarch64'
run: |
pip install --break-system-packages ./wheelhouse/*.whl
- name: Saving wheel
uses: actions/upload-artifact@v4
with:
name: cibw-wheels-${{ matrix.platform.target }}-${{ matrix.python.cp }}
path: ./wheelhouse/*.whl
11 changes: 0 additions & 11 deletions scripts/build_wheel.sh

This file was deleted.

19 changes: 0 additions & 19 deletions scripts/install_dependencies.sh

This file was deleted.

6 changes: 6 additions & 0 deletions scripts/macos_dependencies.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash
brew bundle --file=- <<-EOS
brew "eigen"
cask "gcc-arm-embedded"
brew "gcc@13"
EOS
12 changes: 12 additions & 0 deletions scripts/ubuntu_dependencies.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash

if [[ ! $(id -u) -eq 0 ]]; then
if [[ -z $(which sudo) ]]; then
echo "Please install sudo or run as root"
exit 1
fi
SUDO="sudo"
fi

$SUDO apt-get update
$SUDO apt-get install -y --no-install-recommends clang libeigen3-dev

0 comments on commit c62a75a

Please sign in to comment.