From d34b51929ae8b34e8ac7b622d9f64dd039f3db8b Mon Sep 17 00:00:00 2001 From: Giulio Romualdi Date: Sun, 13 Jun 2021 18:40:25 +0200 Subject: [PATCH 1/3] Fix AddBipedalLocomotionYARPDevice cmake file --- cmake/AddBipedalLocomotionYARPDevice.cmake | 35 ++++++++++++---------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/cmake/AddBipedalLocomotionYARPDevice.cmake b/cmake/AddBipedalLocomotionYARPDevice.cmake index aa5e2021bb..e5e1604f7d 100644 --- a/cmake/AddBipedalLocomotionYARPDevice.cmake +++ b/cmake/AddBipedalLocomotionYARPDevice.cmake @@ -42,27 +42,30 @@ function(add_bipedal_yarp_device) TYPE ${type} INCLUDE ${public_headers}) - yarp_add_plugin(${name} ${sources} ${public_headers}) + if(NOT SKIP_${name}) - target_link_libraries(${name} PUBLIC ${public_link_libraries}) - target_compile_features(${name} PUBLIC cxx_std_17) + yarp_add_plugin(${name} ${sources} ${public_headers}) - # Specify include directories for both compilation and installation process. - # The $ generator expression is useful to ensure to create - # relocatable configuration files, see https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#creating-relocatable-packages - target_include_directories(${name} PUBLIC "$" - "/${CMAKE_INSTALL_INCLUDEDIR}>") + target_link_libraries(${name} PUBLIC ${public_link_libraries}) + target_compile_features(${name} PUBLIC cxx_std_17) - # Specify installation targets, typology and destination folders. - yarp_install(TARGETS ${name} - COMPONENT runtime - LIBRARY DESTINATION ${YARP_DYNAMIC_PLUGINS_INSTALL_DIR} - ARCHIVE DESTINATION ${YARP_STATIC_PLUGINS_INSTALL_DIR} - YARP_INI DESTINATION ${YARP_PLUGIN_MANIFESTS_INSTALL_DIR}) + # Specify include directories for both compilation and installation process. + # The $ generator expression is useful to ensure to create + # relocatable configuration files, see https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#creating-relocatable-packages + target_include_directories(${name} PUBLIC "$" + "/${CMAKE_INSTALL_INCLUDEDIR}>") - add_subdirectory(app) + # Specify installation targets, typology and destination folders. + yarp_install(TARGETS ${name} + COMPONENT runtime + LIBRARY DESTINATION ${YARP_DYNAMIC_PLUGINS_INSTALL_DIR} + ARCHIVE DESTINATION ${YARP_STATIC_PLUGINS_INSTALL_DIR} + YARP_INI DESTINATION ${YARP_PLUGIN_MANIFESTS_INSTALL_DIR}) + add_subdirectory(app) - message(STATUS "Created device ${name}.") + message(STATUS "Created device ${name} for export ${PROJECT_NAME}.") + + endif() endfunction() From 2d3e25471ea137d207bb49aeb87d37e3ac518ac5 Mon Sep 17 00:00:00 2001 From: Giulio Romualdi Date: Sun, 13 Jun 2021 18:41:12 +0200 Subject: [PATCH 2/3] Fix constructor for yarp devices --- .../include/BipedalLocomotion/FloatingBaseEstimatorDevice.h | 4 +++- .../include/BipedalLocomotion/FTIMULoggerDevice.h | 4 +++- .../include/BipedalLocomotion/ROSPublisherTestDevice.h | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/devices/FloatingBaseEstimatorDevice/include/BipedalLocomotion/FloatingBaseEstimatorDevice.h b/devices/FloatingBaseEstimatorDevice/include/BipedalLocomotion/FloatingBaseEstimatorDevice.h index 080535121e..d9e9e128b0 100644 --- a/devices/FloatingBaseEstimatorDevice/include/BipedalLocomotion/FloatingBaseEstimatorDevice.h +++ b/devices/FloatingBaseEstimatorDevice/include/BipedalLocomotion/FloatingBaseEstimatorDevice.h @@ -34,7 +34,9 @@ class BipedalLocomotion::FloatingBaseEstimatorDevice : public yarp::dev::DeviceD public yarp::os::PeriodicThread { public: - explicit FloatingBaseEstimatorDevice(double period, yarp::os::ShouldUseSystemClock useSystemClock = yarp::os::ShouldUseSystemClock::No); + FloatingBaseEstimatorDevice(double period, + yarp::os::ShouldUseSystemClock useSystemClock + = yarp::os::ShouldUseSystemClock::No); FloatingBaseEstimatorDevice(); ~FloatingBaseEstimatorDevice(); diff --git a/devices/examples/FTIMULoggerDevice/include/BipedalLocomotion/FTIMULoggerDevice.h b/devices/examples/FTIMULoggerDevice/include/BipedalLocomotion/FTIMULoggerDevice.h index 2deea7413d..5e07bd8cc9 100644 --- a/devices/examples/FTIMULoggerDevice/include/BipedalLocomotion/FTIMULoggerDevice.h +++ b/devices/examples/FTIMULoggerDevice/include/BipedalLocomotion/FTIMULoggerDevice.h @@ -25,7 +25,9 @@ class BipedalLocomotion::FTIMULoggerDevice : public yarp::dev::DeviceDriver, public yarp::os::PeriodicThread { public: - explicit FTIMULoggerDevice(double period, yarp::os::ShouldUseSystemClock useSystemClock = yarp::os::ShouldUseSystemClock::No); + FTIMULoggerDevice(double period, + yarp::os::ShouldUseSystemClock useSystemClock + = yarp::os::ShouldUseSystemClock::No); FTIMULoggerDevice(); ~FTIMULoggerDevice(); diff --git a/devices/examples/ROSPublisherTestDevice/include/BipedalLocomotion/ROSPublisherTestDevice.h b/devices/examples/ROSPublisherTestDevice/include/BipedalLocomotion/ROSPublisherTestDevice.h index 41eb590432..769ca135e3 100644 --- a/devices/examples/ROSPublisherTestDevice/include/BipedalLocomotion/ROSPublisherTestDevice.h +++ b/devices/examples/ROSPublisherTestDevice/include/BipedalLocomotion/ROSPublisherTestDevice.h @@ -24,7 +24,9 @@ class BipedalLocomotion::ROSPublisherTestDevice : public yarp::dev::DeviceDriver public yarp::os::PeriodicThread { public: - explicit ROSPublisherTestDevice(double period, yarp::os::ShouldUseSystemClock useSystemClock = yarp::os::ShouldUseSystemClock::No); + ROSPublisherTestDevice(double period, + yarp::os::ShouldUseSystemClock useSystemClock + = yarp::os::ShouldUseSystemClock::No); ROSPublisherTestDevice(); ~ROSPublisherTestDevice(); From 5f3356467b9692242b797fc9a018c14ea3cb37d5 Mon Sep 17 00:00:00 2001 From: Giulio Romualdi Date: Sun, 13 Jun 2021 18:43:32 +0200 Subject: [PATCH 3/3] Update the CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7d0062542e..cc825808f0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -75,6 +75,7 @@ All notable changes to this project are documented in this file. - Avoid to use the default copy-constructor and copy-assignment operator in `ContactPhaseList` class (https://github.com/dic-iit/bipedal-locomotion-framework/pull/295) - Fix `toString()` method of `VariablesHandler` class (https://github.com/dic-iit/bipedal-locomotion-framework/pull/302) - Fix in `YarpUtilities::getVectorFromSearchable` when a vector of boolean is passed as input (https://github.com/dic-iit/bipedal-locomotion-framework/pull/313) +- Various fixes for the yarp devices (https://github.com/dic-iit/bipedal-locomotion-framework/pull/337) ## [0.1.1] - 2021-05-08 ### Fix