Skip to content

Commit

Permalink
Merge branch 'master' into Deserialization
Browse files Browse the repository at this point in the history
  • Loading branch information
rotu committed Apr 14, 2020
2 parents 9e54e77 + a9e8784 commit ee568ca
Show file tree
Hide file tree
Showing 18 changed files with 295 additions and 254 deletions.
9 changes: 1 addition & 8 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,8 @@ jobs:
strategy:
fail-fast: false
matrix:
rosdistro: [dashing, eloquent, master]
rosdistro: [master]
os: [ubuntu-18.04, macOS-latest, windows-latest]
exclude:
# pending https://github.com/ament/ament_cmake/pull/233
- rosdistro: eloquent
os: windows-latest
# pending https://github.com/ament/ament_cmake/pull/234
- rosdistro: dashing
os: windows-latest
runs-on: ${{ matrix.os }}
steps:
- if: runner.os == 'Linux'
Expand Down
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,10 @@ Cyclone DDS is ready to use. It seeks to give the fastest, easiest, and most rob

## Building from source and contributing

Note the `master` branch maintains compatibility with ROS releases Dashing and later, including the not-yet-released [*Foxy*](https://index.ros.org/doc/ros2/Releases/Release-Foxy-Fitzroy/).
The following branches are actively maintained:

* `master`, which targets the upcoming ROS version, [*Foxy*](https://index.ros.org/doc/ros2/Releases/Release-Foxy-Fitzroy/).
* `dashing-eloquent`, which maintains compatibility with ROS releases [*Dashing*](https://index.ros.org/doc/ros2/Releases/Release-Dashing-Diademata/) and [*Eloquent*](https://index.ros.org/doc/ros2/Releases/Release-Eloquent-Elusor/)

If building ROS2 from source ([ros2.repos](https://github.com/ros2/ros2/blob/master/ros2.repos)), you already have this package and Cyclone DDS:

Expand Down
27 changes: 0 additions & 27 deletions cyclonedds_cmake_module/CHANGELOG.rst

This file was deleted.

31 changes: 0 additions & 31 deletions cyclonedds_cmake_module/CMakeLists.txt

This file was deleted.

70 changes: 0 additions & 70 deletions cyclonedds_cmake_module/cmake/Modules/FindCycloneDDS.cmake

This file was deleted.

15 changes: 0 additions & 15 deletions cyclonedds_cmake_module/cyclonedds_cmake_module-extras.cmake

This file was deleted.

18 changes: 0 additions & 18 deletions cyclonedds_cmake_module/package.xml

This file was deleted.

10 changes: 5 additions & 5 deletions rmw_cyclonedds_cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@ if(NOT CMAKE_CXX_STANDARD)
endif()

if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
add_compile_options(-Wall -Wextra -Wpedantic)
add_compile_options(-Wall -Wextra -Wpedantic -Wimplicit-fallthrough)
endif()

find_package(ament_cmake_ros REQUIRED)

find_package(rcutils REQUIRED)

find_package(cyclonedds_cmake_module REQUIRED)
#find_package(cyclonedds_cmake_module REQUIRED)
find_package(CycloneDDS QUIET CONFIG)
if(NOT CycloneDDS_FOUND)
message(WARNING "Could not find Eclipse Cyclone DDS - skipping '${PROJECT_NAME}'")
Expand All @@ -38,13 +38,13 @@ if(NOT CycloneDDS_FOUND)
endif()

find_package(rmw REQUIRED)
find_package(rosidl_generator_c REQUIRED)
find_package(rosidl_runtime_c REQUIRED)
find_package(rosidl_typesupport_introspection_c REQUIRED)
find_package(rosidl_typesupport_introspection_cpp REQUIRED)

ament_export_dependencies(rcutils)
ament_export_dependencies(rmw)
ament_export_dependencies(rosidl_generator_c)
ament_export_dependencies(rosidl_runtime_c)
ament_export_dependencies(rosidl_typesupport_introspection_c)
ament_export_dependencies(rosidl_typesupport_introspection_cpp)

Expand All @@ -71,7 +71,7 @@ ament_target_dependencies(rmw_cyclonedds_cpp
"rosidl_typesupport_introspection_c"
"rosidl_typesupport_introspection_cpp"
"rmw"
"rosidl_generator_c"
"rosidl_runtime_c"
)

configure_rmw_library(rmw_cyclonedds_cpp)
Expand Down
18 changes: 9 additions & 9 deletions rmw_cyclonedds_cpp/include/rmw_cyclonedds_cpp/TypeSupport.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
#ifndef RMW_CYCLONEDDS_CPP__TYPESUPPORT_HPP_
#define RMW_CYCLONEDDS_CPP__TYPESUPPORT_HPP_

#include <rosidl_generator_c/string.h>
#include <rosidl_generator_c/string_functions.h>
#include <rosidl_generator_c/u16string_functions.h>
#include <rosidl_runtime_c/string.h>
#include <rosidl_runtime_c/string_functions.h>
#include <rosidl_runtime_c/u16string_functions.h>

#include <cassert>
#include <string>
Expand Down Expand Up @@ -53,15 +53,15 @@ struct StringHelper;
template<>
struct StringHelper<rosidl_typesupport_introspection_c__MessageMembers>
{
using type = rosidl_generator_c__String;
using type = rosidl_runtime_c__String;

static std::string convert_to_std_string(void * data)
{
auto c_string = static_cast<rosidl_generator_c__String *>(data);
auto c_string = static_cast<rosidl_runtime_c__String *>(data);
if (!c_string) {
RCUTILS_LOG_ERROR_NAMED(
"rmw_cyclonedds_cpp",
"Failed to cast data as rosidl_generator_c__String");
"Failed to cast data as rosidl_runtime_c__String");
return "";
}
if (!c_string->data) {
Expand All @@ -73,7 +73,7 @@ struct StringHelper<rosidl_typesupport_introspection_c__MessageMembers>
return std::string(c_string->data);
}

static std::string convert_to_std_string(rosidl_generator_c__String & data)
static std::string convert_to_std_string(rosidl_runtime_c__String & data)
{
return std::string(data.data);
}
Expand All @@ -82,8 +82,8 @@ struct StringHelper<rosidl_typesupport_introspection_c__MessageMembers>
{
std::string str;
deser >> str;
rosidl_generator_c__String * c_str = static_cast<rosidl_generator_c__String *>(field);
rosidl_generator_c__String__assign(c_str, str.c_str());
rosidl_runtime_c__String * c_str = static_cast<rosidl_runtime_c__String *>(field);
rosidl_runtime_c__String__assign(c_str, str.c_str());
}
};

Expand Down

0 comments on commit ee568ca

Please sign in to comment.