12 releases (breaking)

new 0.12.0 Jan 7, 2025
0.11.1 Oct 17, 2024
0.11.0 Sep 24, 2024
0.10.0 Jul 5, 2024
0.5.2 Oct 31, 2022

#2011 in Procedural macros

Download history 206/week @ 2024-09-23 87/week @ 2024-09-30 41/week @ 2024-10-07 176/week @ 2024-10-14 54/week @ 2024-10-21 78/week @ 2024-10-28 57/week @ 2024-11-04 64/week @ 2024-11-11 44/week @ 2024-11-18 9/week @ 2024-11-25 20/week @ 2024-12-02 43/week @ 2024-12-09 28/week @ 2024-12-16 146/week @ 2025-01-06

182 downloads per month
Used in 2 crates

MIT license

100KB
2K SLoC

roslibrust_codegen_macro

This crate defines the proc-macro for generating ROS message types. It invokes APIs from the roslibrust_codegen crate.

Warning

This macro cannot detect if the message files it generates from have changed. If you are creating a crate which just contains your message definitions and won't be recompiled otherwise, you'll likely want to use roslibrust_codegen with a build.rs script.

Usage

If you're generating messages in an environment with ROS installed, no arguments need to be passed.

use roslibrust_codegen_macro::find_and_generate_ros_messages;

find_and_generate_ros_messages!();

If you're generating without ROS installed or your environment can't depend on the ROS_PACKAGE_PATH variable, you can specify additional paths to search:

use roslibrust_codegen_macro::find_and_generate_ros_messages;

find_and_generate_ros_messages!("/path/to/my/msg/package", "/opt/ros/noetic");

Dependencies

~5–14MB
~174K SLoC