-
Notifications
You must be signed in to change notification settings - Fork 582
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Windows Port (WIP) #238
Windows Port (WIP) #238
Conversation
@@ -2,6 +2,7 @@ set(MOVEIT_LIB_NAME moveit_background_processing) | |||
|
|||
add_library(${MOVEIT_LIB_NAME} SHARED src/background_processing.cpp) | |||
set_target_properties(${MOVEIT_LIB_NAME} PROPERTIES VERSION "${${PROJECT_NAME}_VERSION}") | |||
set_target_properties(${MOVEIT_LIB_NAME} PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS TRUE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't we set this as a global property? (like https://github.com/ros-planning/navigation2/pull/1704/files#diff-3f9675091693ca07439ad55ceba95229R48)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@henningkayser PR #285 set's this as a global property
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great progress! It's also nice that there are not too many source file changes required. Did you successfully run the demo on this yet?
@@ -70,6 +72,12 @@ if(BUILD_TESTING) | |||
) | |||
endif() | |||
|
|||
# Causes the visibility macros to use dllexport rather than dllimport, | |||
# which is appropriate when building the dll but not consuming it. | |||
target_compile_definitions(${MOVEIT_LIB_NAME} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit, instructions like this would fit well in a single line
@@ -0,0 +1,70 @@ | |||
// Copyright (c) 2019, Open Source Robotics Foundation, Inc. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// Copyright (c) 2019, Open Source Robotics Foundation, Inc. | |
// Copyright (c) 2020, Open Source Robotics Foundation, Inc. |
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
#ifndef COLLISION_DETECTION__VISIBILITY_CONTROL_HPP_ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a way to simplify the visibility logic even more? It looks like these constants don't have to be defined for each class, so maybe we could use a single header for this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we also maybe leverage rcpputils? https://github.com/ros2/rcpputils/blob/master/include/rcpputils/visibility_control.hpp
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@henningkayser We need one macro per shared lib. However, we could put them all in one header if that's preferable. It could be one large file in moveit_common which would be include logic for every shared lib.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we also maybe leverage rcpputils? https://github.com/ros2/rcpputils/blob/master/include/rcpputils/visibility_control.hpp
@mikeferguson I'm not sure what you mean by leveraging rcpputils. It uses the same logic for symbol visibility but the RCPPUTILS_PUBLIC macro will switch between import and export based on whether rcpputils is the library currently being built.
I did run the demo successfully! It appears to plan successfully and I see the visualization of the arm moving in Rviz. The only issue I've noticed is an error loading the dll for the rviz planning plugin. I'll be debugging that next. Failed to load library C:\moveit_ws\install\moveit_ros_visualization\bin\moveit_planning_scene_rviz_plugin.dll |
@lilustga I'm excited to try this out, as I'm working more and more on a Windows machine now. Do you have any recent updates? I'd love to test this once the merge conflicts are resolved. p.s. I made your title more concise and standard ;-) |
I tried using this and am failing in the rosdep step and then I get an error when trying to run catkin. I admit I don't know what I'm doing in windows. Here are the outputs I'm seeing in case someone else knows a way around these: rosdep errors:
cmake errors:
|
Hi @tylerjw, Which version of ROS are you using? |
melodic, as that is what was recommended on moveit.ros.org, should I be using noetic? 🤦 that's ROS1, feel free to laugh at me. |
I need to figure out how to test this... which means I need to install foxy on windows first... |
@tylerjw you can use chocolatey to install a foxy prerelease: I'm testing now as well, previously I ported moveit2 to Windows on eloquent where I did my original testing. |
I get errors when I try that:
|
Try running this first:
|
I got that to work and then I did this:
Now I'm struggling with how to use vcstool in windows (I'm assuming that's the next step as wstool isn't in ros2). |
@lilustga would you mind resolving the conflicting files to make testing this PR easier? |
Hi Dave, I'm currently working on a rebased version of this PR to resolve the conflicts. I'm also fixing some new build breaks which occurred in the move from eloquent on Windows to foxy on Windows. 18/21 packages building so far. |
moveit2.repos
Outdated
@@ -1,7 +1,7 @@ | |||
repositories: | |||
moveit2: | |||
type: git | |||
url: https://github.com/ros-planning/moveit2 | |||
url: https://github.com/ms-iot/moveit2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
need to revert these
If you want to try out the latest binary you can do it easily now because we've added moveit2 to our foxy desktop build. To try the demo on Windows you simply need to:
|
@lilustga we'd really like to see this PR merged (conflicts resolved, feedback addressed) so we can use the latest version of MoveIt 2 from source on Windows. |
PR #285 moves the symbol visibility cmake code into a common package (as discussed last week at the moveit2 meeting) Note that it doesn't replace the need for explicit symbol visibility macros (i.e. visibility_control.hpp) in exceptional cases like static global variables. I will make another PR with the rest of the fixes which are staged in ms-iot/moveit2. |
… to .cpp to prevent symbol related build breaks. rclcpp added to ament target dependencies. Compile options updated for MSVC. Assimp find_package updated.
…ne before team hack day.
Are there any updates regarding this PR? I'd love to use MoveIt2 on Windows. Is there anything I can do to help? |
…t32_t, added boost::placeholders
This should be closed because #530 was merged, correct? |
All of moveit2 now builds on windows. This is a work in progress PR intended for feedback.
Please explain the changes you made, including a reference to the related issue if applicable
Checklist