Skip to content

Commit

Permalink
Add CMakePresets.json and robot preset (#1001)
Browse files Browse the repository at this point in the history
Co-authored-by: Ugo Pattacini <[email protected]>
  • Loading branch information
traversaro and pattacini authored Dec 14, 2024
1 parent 22c06ce commit 899b9fa
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 39 deletions.
42 changes: 3 additions & 39 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -161,28 +161,9 @@ jobs:
run: |
mkdir -p build
cd build
cmake -A x64 -DCMAKE_TOOLCHAIN_FILE=${VCPKG_INSTALLATION_ROOT}/scripts/buildsystems/vcpkg.cmake \
cmake --preset robot -A x64 -DCMAKE_TOOLCHAIN_FILE=${VCPKG_INSTALLATION_ROOT}/scripts/buildsystems/vcpkg.cmake \
-DCMAKE_PREFIX_PATH=${GITHUB_WORKSPACE}/install \
-DBUILD_SHARED_LIBS:BOOL=${{ matrix.build_shared_libs }} \
-DICUB_USE_icub_firmware_shared:BOOL=ON \
-DENABLE_icubmod_skinWrapper:BOOL=ON \
-DENABLE_icubmod_sharedcan:BOOL=ON \
-DENABLE_icubmod_bcbBattery:BOOL=ON \
-DENABLE_icubmod_canmotioncontrol:BOOL=ON \
-DENABLE_icubmod_canBusAnalogSensor:BOOL=ON \
-DENABLE_icubmod_canBusInertialMTB:BOOL=ON \
-DENABLE_icubmod_canBusSkin:BOOL=ON \
-DENABLE_icubmod_canBusVirtualAnalogSensor:BOOL=ON \
-DENABLE_icubmod_embObjFTsensor:BOOL=ON \
-DENABLE_icubmod_embObjIMU:BOOL=ON \
-DENABLE_icubmod_embObjInertials:BOOL=ON \
-DENABLE_icubmod_embObjMais:BOOL=ON \
-DENABLE_icubmod_embObjMotionControl:BOOL=ON \
-DENABLE_icubmod_embObjBattery:BOOL=ON \
-DENABLE_icubmod_embObjSkin:BOOL=ON \
-DENABLE_icubmod_embObjMultipleFTsensors:BOOL=ON \
-DENABLE_icubmod_parametricCalibrator:BOOL=ON \
-DENABLE_icubmod_parametricCalibratorEth:BOOL=ON \
-DBUILD_TESTING:BOOL=ON \
-DICUB_SHARED_LIBRARY=OFF \
-DCMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/install ..
Expand All @@ -193,26 +174,9 @@ jobs:
run: |
mkdir -p build
cd build
cmake -DCMAKE_PREFIX_PATH=${GITHUB_WORKSPACE}/install \
cmake --preset robot \
-DCMAKE_PREFIX_PATH=${GITHUB_WORKSPACE}/install \
-DBUILD_SHARED_LIBS:BOOL=${{ matrix.build_shared_libs }} \
-DICUB_USE_icub_firmware_shared:BOOL=ON \
-DENABLE_icubmod_skinWrapper:BOOL=ON \
-DENABLE_icubmod_sharedcan:BOOL=ON \
-DENABLE_icubmod_canmotioncontrol:BOOL=ON \
-DENABLE_icubmod_canBusAnalogSensor:BOOL=ON \
-DENABLE_icubmod_canBusInertialMTB:BOOL=ON \
-DENABLE_icubmod_canBusSkin:BOOL=ON \
-DENABLE_icubmod_canBusVirtualAnalogSensor:BOOL=ON \
-DENABLE_icubmod_embObjFTsensor:BOOL=ON \
-DENABLE_icubmod_embObjIMU:BOOL=ON \
-DENABLE_icubmod_embObjInertials:BOOL=ON \
-DENABLE_icubmod_embObjMais:BOOL=ON \
-DENABLE_icubmod_embObjMotionControl:BOOL=ON \
-DENABLE_icubmod_embObjBattery:BOOL=ON \
-DENABLE_icubmod_embObjSkin:BOOL=ON \
-DENABLE_icubmod_embObjMultipleFTsensors:BOOL=ON \
-DENABLE_icubmod_parametricCalibrator:BOOL=ON \
-DENABLE_icubmod_parametricCalibratorEth:BOOL=ON \
-DBUILD_TESTING:BOOL=ON \
-DCMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/install ..
Expand Down
58 changes: 58 additions & 0 deletions CMakePresets.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{
"version": 3,
"cmakeMinimumRequired": {
"major": 3,
"minor": 22,
"patch": 1
},
"configurePresets": [
{
"name": "default",
"displayName": "Default Configuration",
"binaryDir": "${sourceDir}/build",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Release",
"ENABLE_icubmod_cartesiancontrollerclient": "ON",
"ENABLE_icubmod_cartesiancontrollerserver": "ON",
"ENABLE_icubmod_gazecontrollerclient": "ON"
}
},
{
"name": "robot",
"inherits": "default",
"displayName": "Robot Configuration",
"cacheVariables": {
"ICUB_USE_icub_firmware_shared": "ON",
"ENABLE_icubmod_skinWrapper": "ON",
"ENABLE_icubmod_sharedcan": "ON",
"ENABLE_icubmod_bcbBattery": "ON",
"ENABLE_icubmod_canmotioncontrol": "ON",
"ENABLE_icubmod_canBusAnalogSensor": "ON",
"ENABLE_icubmod_canBusInertialMTB": "ON",
"ENABLE_icubmod_canBusSkin": "ON",
"ENABLE_icubmod_canBusFtSensor": "ON",
"ENABLE_icubmod_canBusVirtualAnalogSensor": "ON",
"ENABLE_icubmod_embObjBattery": "ON",
"ENABLE_icubmod_embObjFTsensor": "ON",
"ENABLE_icubmod_embObjMultipleFTsensors": "ON",
"ENABLE_icubmod_embObjIMU": "ON",
"ENABLE_icubmod_embObjMais": "ON",
"ENABLE_icubmod_embObjMotionControl": "ON",
"ENABLE_icubmod_embObjSkin": "ON",
"ENABLE_icubmod_embObjPOS": "ON",
"ENABLE_icubmod_parametricCalibrator": "ON",
"ENABLE_icubmod_parametricCalibratorEth": "ON"
}
}
],
"buildPresets": [
{
"name": "default",
"configurePreset": "default"
},
{
"name": "robot",
"configurePreset": "robot"
}
]
}

0 comments on commit 899b9fa

Please sign in to comment.