Confusion with creating own Ros2 package

Within 2 -ROS 2 basics im getting a warning when creating package

This warning is just to let you know that by default no license has been declared. In the context of the course and files that reside on a VM changing it in the package.xml manually is up to you. Outside of the course, you would choose license based on circumstance. The license informs others of the terms and conditions to use the package/code should it be publicly available.

1 Like

Okay, I was having trouble with the later on, and I thought this was the cause, thanks.

Hi @costell ,

Welcome to this Community!

One way to get rid if that “license” warning is to uncomment a single line in the CMakeLists.txt file.

  set(ament_cmake_copyright_FOUND TRUE)   # <--- uncomment this line
  # see below code snippet to find the location of this line
  find_package(ament_lint_auto REQUIRED)

  # the following line skips the linter which checks for copyrights
  # uncomment the line when a copyright and license is not present in all source files
  set(ament_cmake_copyright_FOUND TRUE) # <<<--- uncomment this line <<<-<<<---

  # the following line skips cpplint (only works in a git repo)
  # uncomment the line when this package is not in a git repo
  set(ament_cmake_cpplint_FOUND TRUE)


I think this should solve your warning indication.


This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.