Skip to content

Commit 790230c

Browse files
authored
Add missing implementations (#296)
* Add missing implementations Signed-off-by: acuadros95 <acuadros1995@gmail.com> * Add depend to colcon Signed-off-by: acuadros95 <acuadros1995@gmail.com> * Test with repo clone Signed-off-by: acuadros95 <acuadros1995@gmail.com> * Only clone rosidl_runtime_c Signed-off-by: acuadros95 <acuadros1995@gmail.com> * Ignore tests Signed-off-by: acuadros95 <acuadros1995@gmail.com> * Move apt install Signed-off-by: acuadros95 <acuadros1995@gmail.com> * Fix build Signed-off-by: acuadros95 <acuadros1995@gmail.com> * Add missing header Signed-off-by: acuadros95 <acuadros1995@gmail.com> --------- Signed-off-by: acuadros95 <acuadros1995@gmail.com>
1 parent a374e1d commit 790230c

4 files changed

Lines changed: 77 additions & 3 deletions

File tree

.github/workflows/ci.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,18 +21,24 @@ jobs:
2121

2222
- name: Download dependencies
2323
run: |
24-
apt update && apt install -y python3-pip git python3-rosdep python3-colcon-common-extensions curl
24+
apt update && apt install -y python3-pip git python3-rosdep python3-colcon-common-extensions curl ros-$ROS_DISTRO-performance-test-fixture
2525
git clone -b ros2 https://github.com/eProsima/Micro-CDR src/Micro-CDR
2626
git clone -b ros2 https://github.com/eProsima/Micro-XRCE-DDS-Client src/Micro-XRCE-DDS-Client
2727
git clone -b main https://github.com/micro-ROS/rosidl_typesupport_microxrcedds src/rosidl_typesupport_microxrcedds
28-
git clone -b master https://github.com/ros2/rmw src/rmw
28+
git clone -b rolling https://github.com/ros2/rmw src/rmw
2929
touch src/rosidl_typesupport_microxrcedds/test/COLCON_IGNORE
30+
31+
# Workarround until rolling docker is updated
32+
git clone -b rolling https://github.com/ros2/rosidl src/rosidl
33+
cp -r src/rosidl/rosidl_runtime_c src/rosidl_runtime_c
34+
rm -rf src/rosidl
35+
touch src/rosidl_runtime_c/test/COLCON_IGNORE
36+
3037
# Install coverage tools
3138
pip3 install gcovr
3239
. /opt/ros/$ROS_DISTRO/setup.sh
3340
rosdep init && rosdep update
3441
rosdep install --from-paths src -r
35-
apt -y install ros-$ROS_DISTRO-performance-test-fixture
3642
3743
- name: Build
3844
run: . /opt/ros/$ROS_DISTRO/setup.sh && colcon build --symlink-install --cmake-args -DBUILD_SHARED_LIBS=ON -DCMAKE_CXX_FLAGS="-ftest-coverage --coverage -fno-inline -fno-inline-small-functions -fno-default-inline" -DCMAKE_CXX_OUTPUT_EXTENSION_REPLACE=ON -DCMAKE_C_FLAGS="-ftest-coverage --coverage -fno-inline -fno-inline-small-functions -fno-default-inline" -DCMAKE_C_OUTPUT_EXTENSION_REPLACE=ON

rmw_microxrcedds_c/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,7 @@ set(SRCS
196196
src/rmw_get_topic_endpoint_info.c
197197
src/rmw_get_endpoint_network_flow.c
198198
src/rmw_qos_profile_check_compatible.c
199+
src/rmw_dynamic_message_type_support.c
199200
src/rmw_guard_condition.c
200201
src/rmw_init.c
201202
src/rmw_logging.c

rmw_microxrcedds_c/package.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
<buildtool_export_depend>rosidl_cmake</buildtool_export_depend>
1515

1616
<depend>microcdr</depend>
17+
<depend>rosidl_runtime_c</depend>
1718
<depend>microxrcedds_client</depend>
1819
<depend>rcutils</depend>
1920
<depend>rmw</depend>
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
// Copyright 2023 Proyectos y Sistemas de Mantenimiento SL (eProsima).
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#include <rmw/dynamic_message_type_support.h>
16+
17+
#include "./rmw_microros_internal/error_handling_internal.h"
18+
19+
rmw_ret_t
20+
rmw_take_dynamic_message(
21+
const rmw_subscription_t * subscription,
22+
rosidl_dynamic_typesupport_dynamic_data_t * dynamic_message,
23+
bool * taken,
24+
rmw_subscription_allocation_t * allocation)
25+
{
26+
(void)subscription;
27+
(void)dynamic_message;
28+
(void)taken;
29+
(void)allocation;
30+
RMW_UROS_TRACE_MESSAGE("function not implemented");
31+
return RMW_RET_UNSUPPORTED;
32+
}
33+
34+
RMW_PUBLIC
35+
RMW_WARN_UNUSED
36+
rmw_ret_t
37+
rmw_take_dynamic_message_with_info(
38+
const rmw_subscription_t * subscription,
39+
rosidl_dynamic_typesupport_dynamic_data_t * dynamic_message,
40+
bool * taken,
41+
rmw_message_info_t * message_info,
42+
rmw_subscription_allocation_t * allocation)
43+
{
44+
(void)subscription;
45+
(void)dynamic_message;
46+
(void)taken;
47+
(void)message_info;
48+
(void)allocation;
49+
RMW_UROS_TRACE_MESSAGE("function not implemented");
50+
return RMW_RET_UNSUPPORTED;
51+
}
52+
53+
RMW_PUBLIC
54+
RMW_WARN_UNUSED
55+
rmw_ret_t
56+
rmw_serialization_support_init(
57+
const char * serialization_lib_name,
58+
rcutils_allocator_t * allocator,
59+
rosidl_dynamic_typesupport_serialization_support_t * serialization_support)
60+
{
61+
(void)serialization_lib_name;
62+
(void)allocator;
63+
(void)serialization_support;
64+
RMW_UROS_TRACE_MESSAGE("function not implemented");
65+
return RMW_RET_UNSUPPORTED;
66+
}

0 commit comments

Comments
 (0)