Use RF to find kinematics config file #12
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: Continuous Integration | |
on: | |
push: | |
paths-ignore: | |
- 'doc/**' | |
- '**.md' | |
pull_request: | |
workflow_dispatch: | |
env: | |
CMAKE_CCACHE_LAUNCHER: -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache | |
jobs: | |
maybe_skip: | |
runs-on: ubuntu-latest | |
outputs: | |
should_skip: ${{steps.skip_check.outputs.should_skip}} | |
steps: | |
- uses: fkirc/skip-duplicate-actions@v5 | |
id: skip_check | |
with: | |
cancel_others: 'true' | |
build: | |
name: build (${{matrix.os}}, ${{matrix.robotology.yarp}}, ${{matrix.compiler.cc}}) | |
runs-on: ${{matrix.os}} | |
needs: maybe_skip | |
if: ${{needs.maybe_skip.outputs.should_skip != 'true'}} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-22.04, ubuntu-24.04] | |
robotology: | |
- { yarp: yarp-3.8, cmake: 3.16.x } | |
- { yarp: yarp-3.9, cmake: 3.16.x } | |
- { yarp: master, cmake: 3.19.x } | |
compiler: | |
- { cc: gcc, cxx: g++ } | |
- { cc: clang, cxx: clang++ } | |
experimental: | |
- ${{github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'}} | |
exclude: | |
- { experimental: false, robotology: { yarp: master } } | |
steps: | |
- name: Check out amor-yarp-devices | |
uses: actions/checkout@v4 | |
- name: Check out YCM | |
uses: actions/checkout@v4 | |
with: | |
repository: robotology/ycm | |
path: .deps/ycm | |
- name: Check out YARP | |
uses: actions/checkout@v4 | |
with: | |
repository: robotology/yarp | |
ref: ${{matrix.robotology.yarp}} | |
path: .deps/yarp | |
- name: Check out Orocos KDL | |
uses: actions/checkout@v4 | |
with: | |
repository: orocos/orocos_kinematics_dynamics | |
path: .deps/kdl | |
- name: Check out kinematics-dynamics | |
uses: actions/checkout@v4 | |
with: | |
repository: roboticslab-uc3m/kinematics-dynamics | |
path: .deps/kinematics-dynamics | |
- name: Check out amor-api | |
uses: actions/checkout@v4 | |
with: | |
repository: roboticslab-uc3m/amor-api | |
token: ${{secrets.AMOR_API}} | |
path: .deps/amor-api | |
- name: Install dependencies via apt | |
run: sudo apt-get install -qq ccache libboost-thread-dev libeigen3-dev | |
- name: Set up CMake | |
uses: jwlawson/actions-setup-cmake@v2 | |
with: | |
cmake-version: ${{matrix.robotology.cmake}} | |
- name: Set up Ccache | |
uses: hendrikmuhs/ccache-action@v1 | |
with: | |
key: ${{matrix.os}}-${{matrix.robotology.yarp}}-${{matrix.compiler.cc}} | |
- name: Set environment variables | |
run: | | |
echo "CC=${{matrix.compiler.cc}}" >> $GITHUB_ENV | |
echo "CXX=${{matrix.compiler.cxx}}" >> $GITHUB_ENV | |
- name: Build YCM | |
run: | | |
cmake -S .deps/ycm -B .deps/ycm/build | |
cmake --build .deps/ycm/build | |
sudo cmake --install .deps/ycm/build | |
- name: Build YARP | |
run: | | |
cmake -S .deps/yarp -B .deps/yarp/build $CMAKE_CCACHE_LAUNCHER -DSKIP_ACE=ON -DYARP_DISABLE_VERSION_SOURCE=ON | |
cmake --build .deps/yarp/build | |
sudo cmake --install .deps/yarp/build | |
- name: Build Orocos KDL | |
run: | | |
cmake -S .deps/kdl/orocos_kdl -B .deps/kdl/orocos_kdl/build $CMAKE_CCACHE_LAUNCHER | |
cmake --build .deps/kdl/orocos_kdl/build | |
sudo cmake --install .deps/kdl/orocos_kdl/build | |
- name: Build kinematics-dynamics | |
run: | | |
cmake -S .deps/kinematics-dynamics -B .deps/kinematics-dynamics/build $CMAKE_CCACHE_LAUNCHER | |
cmake --build .deps/kinematics-dynamics/build | |
sudo cmake --install .deps/kinematics-dynamics/build | |
- name: Build amor-api | |
run: | | |
cmake -S .deps/amor-api -B .deps/amor-api/build $CMAKE_CCACHE_LAUNCHER -DENABLE_udev_rules=OFF | |
cmake --build .deps/amor-api/build | |
sudo cmake --install .deps/amor-api/build | |
- name: Configure amor-yarp-devices | |
run: cmake -S . -B ./build $CMAKE_CCACHE_LAUNCHER | |
- name: Compile amor-yarp-devices | |
run: cmake --build ./build | |
- name: Install amor-yarp-devices | |
run: sudo cmake --install ./build && sudo ldconfig | |
- name: Uninstall amor-yarp-devices | |
run: sudo cmake --build ./build --target uninstall |