feat(cmake): Move to find_package #658
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: ubuntu 20.04 | |
on: | |
push: | |
paths-ignore: | |
- '**.md' | |
pull_request: | |
paths-ignore: | |
- '**.md' | |
jobs: | |
run: | |
name: Run | |
runs-on: ubuntu-20.04 | |
strategy: | |
matrix: | |
python-version: [3.8] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install system dependencies | |
run: | | |
sudo apt update && sudo apt install -y build-essential ninja-build python3-pip python3-dev curl gnupg apt-transport-https clang-format-11 | |
pip3 install termcolor | |
- name: conan installation and configuration | |
run: | | |
pip install conan==1.64.0 pytest==6.2.5 | |
conan user | |
conan profile new default --detect --force | |
conan profile update settings.compiler.libcxx=libstdc++11 default | |
conan config set general.parallel_download=$(nproc) | |
conan config set general.cpu_count=$(nproc) | |
conan remote add duckstax http://conan.duckstax.com | |
- name: download dependencies | |
run: | | |
mkdir build && cd build | |
cp ../conanfile.txt . | |
conan install . --build missing -s build_type=Release | |
- name: Check | |
run: | | |
chmod +x scripts/CI/run-check-formatting.sh | |
scripts/CI/run-check-formatting.sh | |
- name: build | |
env: | |
CC: gcc | |
run: | | |
cd build | |
cmake -G Ninja -DCMAKE_TOOLCHAIN_FILE="conan_toolchain.cmake" -DCMAKE_BUILD_TYPE=Release -DDEV_MODE=ON -DEXAMPLE=ON .. | |
cmake --build . | |
- name: Test | |
run: | | |
cd build | |
ctest -C -V --output-on-failure | |
- name: PyTest | |
run: | | |
cd build/integration/python/ | |
pytest |