Skip to content

Latest commit

 

History

History
46 lines (35 loc) · 1.54 KB

Makefiles.md

File metadata and controls

46 lines (35 loc) · 1.54 KB

Make Commands Explanation

Targets

In this project, we use make commands to automate shell scripts: make deps, make, make run, etc. It's done to reduce amount of typing and utilize makefile rule prerequisites feature.

Information about some targets:

make help

The list of all targets can be shown with:

make <Tab>

To know the content of each make target, either execute the command and check its output or open GNUmakefile in root / node folder with text editor. (Makefile for Windows)

Alternative

Of course, you can use ros commands directly. For example, make run command is described in run: paragraph of GNUmakefile similar to:

source install/setup.bash
ros2 launch rc110_system robot.launch

Then you can check the meaning of those commands in public documentation.

Specifics of RC110 Makefiles

Arguments

It's possible to pass variables to make as following:

make my_target var1=a var2=b

Internally some targets use ros_args macros which provides roslaunch arguments out of those variables, so ros2 launch <...> $(ros_args) becomes:

ros2 launch <...> var1:=a var2:=b

Roslaunch discards unused arguments, so it's probably ok to mix makefile and roslaunch names.

Required Knowledge