diff --git a/nav2_costmap_2d/test/integration/CMakeLists.txt b/nav2_costmap_2d/test/integration/CMakeLists.txt
index 7125a51418..6566784753 100644
--- a/nav2_costmap_2d/test/integration/CMakeLists.txt
+++ b/nav2_costmap_2d/test/integration/CMakeLists.txt
@@ -138,10 +138,10 @@ ament_add_test(test_costmap_subscriber_exec
# ament_add_gtest_executable(costmap_tester
# costmap_tester.cpp
# )
-# ament_target_dependencies(costmap_tester
-# ${dependencies}
-# )
# target_link_libraries(costmap_tester
-# nav2_costmap_2d_core
# layers
+# nav2_costmap_2d::nav2_costmap_2d_core
+# nav2_util::nav2_utils_core
+# rclcpp::rclcpp
+# tf2_ros::tf2_ros
# )
diff --git a/nav2_dwb_controller/nav2_dwb_controller/CMakeLists.txt b/nav2_dwb_controller/nav2_dwb_controller/CMakeLists.txt
index 5099822acb..e900fd292c 100644
--- a/nav2_dwb_controller/nav2_dwb_controller/CMakeLists.txt
+++ b/nav2_dwb_controller/nav2_dwb_controller/CMakeLists.txt
@@ -1,10 +1,9 @@
cmake_minimum_required(VERSION 3.5)
project(nav2_dwb_controller)
-if(NOT CMAKE_CXX_STANDARD)
- set(CMAKE_CXX_STANDARD 14)
-endif()
-
find_package(ament_cmake REQUIRED)
+find_package(nav2_common REQUIRED)
+
+nav2_package()
ament_package()
diff --git a/nav2_dwb_controller/nav2_dwb_controller/package.xml b/nav2_dwb_controller/nav2_dwb_controller/package.xml
index 77d5f4ec9f..f98c8473a8 100644
--- a/nav2_dwb_controller/nav2_dwb_controller/package.xml
+++ b/nav2_dwb_controller/nav2_dwb_controller/package.xml
@@ -11,14 +11,15 @@
Apache-2.0
ament_cmake
+ nav2_common
- costmap_queue
- dwb_core
- dwb_critics
- dwb_msgs
- dwb_plugins
- nav_2d_msgs
- nav_2d_utils
+ costmap_queue
+ dwb_core
+ dwb_critics
+ dwb_msgs
+ dwb_plugins
+ nav_2d_msgs
+ nav_2d_utils
ament_cmake
diff --git a/nav2_mppi_controller/benchmark/CMakeLists.txt b/nav2_mppi_controller/benchmark/CMakeLists.txt
index 97db9f4185..3f92196fcb 100644
--- a/nav2_mppi_controller/benchmark/CMakeLists.txt
+++ b/nav2_mppi_controller/benchmark/CMakeLists.txt
@@ -9,14 +9,17 @@ foreach(name IN LISTS BENCHMARK_NAMES)
add_executable(${name}
${name}.cpp
)
- ament_target_dependencies(${name}
- ${dependencies_pkgs}
- )
target_link_libraries(${name}
- mppi_controller mppi_critics benchmark
+ benchmark
+ ${geometry_msgs_TARGETS}
+ mppi_controller
+ mppi_critics
+ nav2_core::nav2_core
+ nav2_costmap_2d::nav2_costmap_2d_core
+ ${nav_msgs_TARGETS}
)
-target_include_directories(${name} PRIVATE
+ target_include_directories(${name} PRIVATE
${PROJECT_SOURCE_DIR}/test/utils
-)
+ )
endforeach()
diff --git a/nav2_mppi_controller/benchmark/optimizer_benchmark.cpp b/nav2_mppi_controller/benchmark/optimizer_benchmark.cpp
index a7216bc80d..0906385c1a 100644
--- a/nav2_mppi_controller/benchmark/optimizer_benchmark.cpp
+++ b/nav2_mppi_controller/benchmark/optimizer_benchmark.cpp
@@ -13,7 +13,9 @@
// limitations under the License.
#include
+
#include
+#include
#include "gtest/gtest.h"
#include
diff --git a/nav2_smac_planner/CMakeLists.txt b/nav2_smac_planner/CMakeLists.txt
index a8789af62d..4ae1a98ad9 100644
--- a/nav2_smac_planner/CMakeLists.txt
+++ b/nav2_smac_planner/CMakeLists.txt
@@ -1,8 +1,6 @@
cmake_minimum_required(VERSION 3.5)
project(nav2_smac_planner)
-set(CMAKE_BUILD_TYPE Release) #Debug, Release
-
find_package(ament_cmake REQUIRED)
find_package(ament_index_cpp REQUIRED)
find_package(angles REQUIRED)
diff --git a/navigation2/CMakeLists.txt b/navigation2/CMakeLists.txt
index 763c95c1e9..3b82e6c002 100644
--- a/navigation2/CMakeLists.txt
+++ b/navigation2/CMakeLists.txt
@@ -1,10 +1,9 @@
cmake_minimum_required(VERSION 3.5)
project(navigation2)
-if(NOT CMAKE_CXX_STANDARD)
- set(CMAKE_CXX_STANDARD 17)
-endif()
-
find_package(ament_cmake REQUIRED)
+find_package(nav2_common REQUIRED)
+
+nav2_package()
ament_package()
diff --git a/navigation2/package.xml b/navigation2/package.xml
index 4d7fffeb9c..45ad44912b 100644
--- a/navigation2/package.xml
+++ b/navigation2/package.xml
@@ -11,6 +11,7 @@
Apache-2.0
ament_cmake
+ nav2_common
nav2_amcl