Skip to content

Commit

Permalink
Merge branch 'kucheria/cmake_composition' of https://github.com/ros2/…
Browse files Browse the repository at this point in the history
…rclcpp into kucheria/cmake_composition
  • Loading branch information
skucheria committed Jul 23, 2019
2 parents 7f05d46 + 4074c75 commit 49a14ef
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,11 @@
macro(rclcpp_components_register_node target)
cmake_parse_arguments(
ARGS
""
"FLUSH_BUFFER"
"PLUGIN;EXECUTABLE"
""
${ARGN})
set(flush_buffer ${ARGS_FLUSH_BUFFER})
set(component ${ARGS_PLUGIN})
set(node ${ARGS_EXECUTABLE})
_rclcpp_components_register_package_hook()
Expand Down
4 changes: 4 additions & 0 deletions rclcpp_components/src/node_main.cpp.in
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@

int main(int argc, char * argv[])
{
std::string flush_buffer = "@flush_buffer@";
if (!(flush_buffer.compare("TRUE"))) {
setvbuf(stdout, NULL, _IONBF, BUFSIZ);
}
auto args = rclcpp::init_and_remove_ros_arguments(argc, argv);
rclcpp::Logger logger = rclcpp::get_logger(NODE_MAIN_LOGGER_NAME);
rclcpp::executors::SingleThreadedExecutor exec;
Expand Down

0 comments on commit 49a14ef

Please sign in to comment.