RobotecAI / ros2cs

A C# (.Net) implementation of ros2 client library (rcl), enabling communication between ros2 ecosystem and C#/.Net applications such as Unity3D
Apache License 2.0
91 stars 22 forks source link

Building error Ubuntu20.04 and ros foxy #50

Closed dsponer closed 1 year ago

dsponer commented 1 year ago

Hello I have a problem with build my ros2cs The error crashed all process then I build tests

The type or namespace name 'example_interfaces

Deric-W commented 1 year ago

Hello, can you please show us the full error?

dsponer commented 1 year ago

This is full error

ros2cs_performance_listener_dotnetcore -> /home/ubuntu/ros2cs/build/ros2cs_examples/Release/netcoreapp6.0/ros2cs_performance_listener.dll /home/ubuntu/ros2cs/src/ros2cs/ros2cs_examples/ROS2Service.cs(39,77): error CS0246: The type or namespace name 'example_interfaces' could not be found (are you missing a using directive or an assembly reference?) [/home/ubuntu/ros2cs/build/ros2cs_examples/ros2cs_service/ros2cs_service_dotnetcore.csproj] /home/ubuntu/ros2cs/src/ros2cs/ros2cs_examples/ROS2Service.cs(39,19): error CS0246: The type or namespace name 'example_interfaces' could not be found (are you missing a using directive or an assembly reference?) [/home/ubuntu/ros2cs/build/ros2cs_examples/ros2cs_service/ros2cs_service_dotnetcore.csproj] /home/ubuntu/ros2cs/src/ros2cs/ros2cs_examples/ROS2Service.cs(25,28): error CS0246: The type or namespace name 'example_interfaces' could not be found (are you missing a using directive or an assembly reference?) [/home/ubuntu/ros2cs/build/ros2cs_examples/ros2cs_service/ros2cs_service_dotnetcore.csproj] /home/ubuntu/ros2cs/src/ros2cs/ros2cs_examples/ROS2Service.cs(25,71): error CS0246: The type or namespace name 'example_interfaces' could not be found (are you missing a using directive or an assembly reference?) [/home/ubuntu/ros2cs/build/ros2cs_examples/ros2cs_service/ros2cs_service_dotnetcore.csproj]

Build FAILED.

/home/ubuntu/ros2cs/src/ros2cs/ros2cs_examples/ROS2Service.cs(39,77): error CS0246: The type or namespace name 'example_interfaces' could not be found (are you missing a using directive or an assembly reference?) [/home/ubuntu/ros2cs/build/ros2cs_examples/ros2cs_service/ros2cs_service_dotnetcore.csproj] /home/ubuntu/ros2cs/src/ros2cs/ros2cs_examples/ROS2Service.cs(39,19): error CS0246: The type or namespace name 'example_interfaces' could not be found (are you missing a using directive or an assembly reference?) [/home/ubuntu/ros2cs/build/ros2cs_examples/ros2cs_service/ros2cs_service_dotnetcore.csproj] /home/ubuntu/ros2cs/src/ros2cs/ros2cs_examples/ROS2Service.cs(25,28): error CS0246: The type or namespace name 'example_interfaces' could not be found (are you missing a using directive or an assembly reference?) [/home/ubuntu/ros2cs/build/ros2cs_examples/ros2cs_service/ros2cs_service_dotnetcore.csproj] /home/ubuntu/ros2cs/src/ros2cs/ros2cs_examples/ROS2Service.cs(25,71): error CS0246: The type or namespace name 'example_interfaces' could not be found (are you missing a using directive or an assembly reference?) [/home/ubuntu/ros2cs/build/ros2cs_examples/ros2cs_service/ros2cs_service_dotnetcore.csproj] 0 Warning(s) 4 Error(s)

Deric-W commented 1 year ago

Did you execute ./get_repos.sh? Try to clear the CMake cache.

adamdbrw commented 1 year ago

@dsponer was your issue resolved?

dsponer commented 1 year ago

@adamdbrw, Yes, I solved the problem

I did the following 1) Removed my ROS2 2) Installed ros-foxy-base 3) I downloaded the package from the foxy_fixes_for_custom_messages branch These steps allowed me to solve the problem Thank you for your help