A ROS workspace is a directory where we keep the ROS packages. As you saw in the preceding setup, you know that the build technique that's used in ROS-2 is colcon instead of catkin, which was used in ROS-1. The workspace layout is a bit different in ROS-2. Colcon does out of source builds and creates the following folders:
- The build folder is where intermediate files are stored.
- The install folder is where each package will be installed.
- The log folder is where all the logging information is available.
- The src folder is where the source code is placed.
Note that there is no devel folder like there is in ROS-1.
As the build steps were already explained and tried out while building the ROS-2 packages, let's quickly look at the commands that are needed to build any ROS-2 workspace.
Let's consider the ros2_examples_ws package for demonstration...