Skip to content

Add Windows CI jobs #110

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

Closed
nnmm opened this issue Apr 20, 2022 · 10 comments · Fixed by #485
Closed

Add Windows CI jobs #110

nnmm opened this issue Apr 20, 2022 · 10 comments · Fixed by #485

Comments

@nnmm
Copy link
Contributor

nnmm commented Apr 20, 2022

GitHub offers a free Windows CI – we should add equivalent jobs to the ones we have for Ubuntu.

@coarsedamavand
Copy link

Is this issue, and development for Windows environments in general, within the scope of ongoing work for ros2_rust?

@esteve
Copy link
Collaborator

esteve commented Mar 20, 2025

@knmcguire do you want to give it a go at this? 🙂

@knmcguire
Copy link
Contributor

knmcguire commented Mar 20, 2025

So... what are you trying to say @esteve... that I'm the Windows person now?! 😜

JK absolutely, you can assign me. I actually have windows x pixi GH action for my personal website now 😄

But... there is a build issue on it still on the ros_idl message generation that I haven't debugged further (or made a ticket for). I'll dig in what exactly the problem is, make a ticket on the error and link that to this ticket.

It's probably best not to implement an CI just yet before we even get super hacky local build issue fixed... maybe? Or what do you think?

@knmcguire
Copy link
Contributor

I made an issue here: ros2-rust/rosidl_rust#2. Will debug this further and once it builds then I can move on to this one

@esteve
Copy link
Collaborator

esteve commented Apr 8, 2025

So... what are you trying to say @esteve... that I'm the Windows person now?! 😜

Sorry 😅

I just thought you might be interested in this, it'd be really cool to have support for Windows, but unfortunately I don't know if I can be of much help here.

@esteve
Copy link
Collaborator

esteve commented Apr 8, 2025

I made an issue here: ros2-rust/rosidl_rust#2. Will debug this further and once it builds then I can move on to this one

Excellent, thank you!

@knmcguire
Copy link
Contributor

There is a fix here! ros2-rust/rosidl_rust#2.

So the build continued until the next error in rclrs build.

  --- stderr
  thread 'main' panicked at C:\Users\kimbe\.cargo\registry\src\index.crates.io-6f17d22bba15001f\bindgen-0.70.1\lib.rs:622:27:
  Unable to find libclang: "couldn't find any valid shared libraries matching: ['clang.dll', 'libclang.dll'], set the `LIBCLANG_PATH` environment variable to a path where one of these files can be found (invalid: [])"
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Weirdly I have added libclang to the ROS 2 pixi environment, so the search continues!

@knmcguire
Copy link
Contributor

knmcguire commented Apr 8, 2025

Tada there is actually documentation on this! So I added libclang to pixi through condo, but I still had to set a LIBCLANG_PATH and change libclang-13.dll to libclang.dll.

All the other dependencies were already included in the pixi environment of the windows installation instructions of ROS2 and for building this package I still had to have MSVC 2019 installed anyway... but if we want to build the full ROS2 that will take a long time though... and is very big as well.

But... then you do get this!

(pixi_ros2_rolling) C:\dev\ws\rust_ros>ros2 run examples_rclrs_minimal_pub_sub minimal_publisher
Publishing: [Hello, world! 1]
Publishing: [Hello, world! 2]
Publishing: [Hello, world! 3]
Publishing: [Hello, world! 4]
Publishing: [Hello, world! 5]
Publishing: [Hello, world! 6]
Publishing: [Hello, world! 7]
Publishing: [Hello, world! 8]
Publishing: [Hello, world! 9]
(pixi_ros2_rolling) C:\dev\ws\rust_ros>ros2 run examples_rclrs_minimal_pub_sub minimal_subscriber

I heard: 'Hello, world! 6'
(Got 1 messages so far)
I heard: 'Hello, world! 7'
(Got 2 messages so far)
I heard: 'Hello, world! 8'
(Got 3 messages so far)
I heard: 'Hello, world! 9'
(Got 4 messages so far)

Once ros2-rust/rosidl_rust#3 is merged then I can work on a github action for the windows CI

@esteve
Copy link
Collaborator

esteve commented Apr 26, 2025

@knmcguire that is really cool! Thank you so much for looking into it

@knmcguire
Copy link
Contributor

No problem! There are currently a couple issues in windows that I think that needs to be solved before we add it to CI. This is one of them: ros2/ros2_documentation#5384

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants