From 6c6c4d2982b87afe79fe636a02b439fb08500a13 Mon Sep 17 00:00:00 2001 From: Tonu Samuel Date: Sat, 19 Oct 2019 14:52:29 +0300 Subject: [PATCH] Fix compilation problems on Ubuntu 18.x --- Examples/Monocular/mono_euroc.cc | 13 +++++++------ Examples/Monocular/mono_kitti.cc | 15 ++++++++------- Examples/Monocular/mono_tum.cc | 13 +++++++------ Examples/RGB-D/rgbd_tum.cc | 13 +++++++------ Examples/ROS/ORB_SLAM2/CMakeLists.txt | 2 ++ Examples/ROS/ORB_SLAM2/src/AR/ViewerAR.cc | 1 + Examples/Stereo/stereo_euroc.cc | 15 ++++++++------- Examples/Stereo/stereo_kitti.cc | 15 ++++++++------- src/LocalMapping.cc | 1 + src/LoopClosing.cc | 6 +++--- src/System.cc | 1 + src/Tracking.cc | 23 ++++++++++++----------- src/Viewer.cc | 1 + 13 files changed, 66 insertions(+), 53 deletions(-) diff --git a/Examples/Monocular/mono_euroc.cc b/Examples/Monocular/mono_euroc.cc index 4bcb90f170..bc5dae5636 100644 --- a/Examples/Monocular/mono_euroc.cc +++ b/Examples/Monocular/mono_euroc.cc @@ -19,14 +19,15 @@ */ -#include -#include -#include -#include +#include +#include +#include +#include -#include +#include -#include +#include +#include using namespace std; diff --git a/Examples/Monocular/mono_kitti.cc b/Examples/Monocular/mono_kitti.cc index f2f7b3ebfd..88e7e1062d 100644 --- a/Examples/Monocular/mono_kitti.cc +++ b/Examples/Monocular/mono_kitti.cc @@ -19,15 +19,16 @@ */ -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include -#include +#include -#include"System.h" +#include +#include "System.h" using namespace std; diff --git a/Examples/Monocular/mono_tum.cc b/Examples/Monocular/mono_tum.cc index 09a2afc4b7..1098f699db 100644 --- a/Examples/Monocular/mono_tum.cc +++ b/Examples/Monocular/mono_tum.cc @@ -19,14 +19,15 @@ */ -#include -#include -#include -#include +#include +#include +#include +#include -#include +#include -#include +#include +#include using namespace std; diff --git a/Examples/RGB-D/rgbd_tum.cc b/Examples/RGB-D/rgbd_tum.cc index 001199d1aa..a24d368564 100644 --- a/Examples/RGB-D/rgbd_tum.cc +++ b/Examples/RGB-D/rgbd_tum.cc @@ -19,14 +19,15 @@ */ -#include -#include -#include -#include +#include +#include +#include +#include -#include +#include -#include +#include +#include using namespace std; diff --git a/Examples/ROS/ORB_SLAM2/CMakeLists.txt b/Examples/ROS/ORB_SLAM2/CMakeLists.txt index 7cbf71c199..cb59c535d8 100644 --- a/Examples/ROS/ORB_SLAM2/CMakeLists.txt +++ b/Examples/ROS/ORB_SLAM2/CMakeLists.txt @@ -40,6 +40,7 @@ endif() find_package(Eigen3 3.1.0 REQUIRED) find_package(Pangolin REQUIRED) +find_package(Boost COMPONENTS system REQUIRED ) include_directories( ${PROJECT_SOURCE_DIR} @@ -52,6 +53,7 @@ set(LIBS ${OpenCV_LIBS} ${EIGEN3_LIBS} ${Pangolin_LIBRARIES} +${Boost_LIBRARIES} ${PROJECT_SOURCE_DIR}/../../../Thirdparty/DBoW2/lib/libDBoW2.so ${PROJECT_SOURCE_DIR}/../../../Thirdparty/g2o/lib/libg2o.so ${PROJECT_SOURCE_DIR}/../../../lib/libORB_SLAM2.so diff --git a/Examples/ROS/ORB_SLAM2/src/AR/ViewerAR.cc b/Examples/ROS/ORB_SLAM2/src/AR/ViewerAR.cc index 9c548e87d1..b1f444396e 100644 --- a/Examples/ROS/ORB_SLAM2/src/AR/ViewerAR.cc +++ b/Examples/ROS/ORB_SLAM2/src/AR/ViewerAR.cc @@ -25,6 +25,7 @@ #include #include #include +#include using namespace std; diff --git a/Examples/Stereo/stereo_euroc.cc b/Examples/Stereo/stereo_euroc.cc index 6bc09c50be..6814693493 100644 --- a/Examples/Stereo/stereo_euroc.cc +++ b/Examples/Stereo/stereo_euroc.cc @@ -19,15 +19,16 @@ */ -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include -#include +#include -#include +#include +#include using namespace std; diff --git a/Examples/Stereo/stereo_kitti.cc b/Examples/Stereo/stereo_kitti.cc index cb8bc4096e..b19dc2ebb6 100644 --- a/Examples/Stereo/stereo_kitti.cc +++ b/Examples/Stereo/stereo_kitti.cc @@ -19,15 +19,16 @@ */ -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include -#include +#include -#include +#include +#include using namespace std; diff --git a/src/LocalMapping.cc b/src/LocalMapping.cc index 6c87a6e55a..8c300f204b 100644 --- a/src/LocalMapping.cc +++ b/src/LocalMapping.cc @@ -22,6 +22,7 @@ #include "LoopClosing.h" #include "ORBmatcher.h" #include "Optimizer.h" +#include #include diff --git a/src/LoopClosing.cc b/src/LoopClosing.cc index 5e317dd420..730c5407a8 100644 --- a/src/LoopClosing.cc +++ b/src/LoopClosing.cc @@ -28,9 +28,9 @@ #include "ORBmatcher.h" -#include -#include - +#include +#include +#include namespace ORB_SLAM2 { diff --git a/src/System.cc b/src/System.cc index 8df4157095..29c93494df 100644 --- a/src/System.cc +++ b/src/System.cc @@ -25,6 +25,7 @@ #include #include #include +#include namespace ORB_SLAM2 { diff --git a/src/Tracking.cc b/src/Tracking.cc index 2273b2ce48..e7e88052d5 100644 --- a/src/Tracking.cc +++ b/src/Tracking.cc @@ -21,21 +21,22 @@ #include "Tracking.h" -#include -#include +#include +#include -#include"ORBmatcher.h" -#include"FrameDrawer.h" -#include"Converter.h" -#include"Map.h" -#include"Initializer.h" +#include "ORBmatcher.h" +#include "FrameDrawer.h" +#include "Converter.h" +#include "Map.h" +#include "Initializer.h" -#include"Optimizer.h" -#include"PnPsolver.h" +#include "Optimizer.h" +#include "PnPsolver.h" -#include +#include -#include +#include +#include using namespace std; diff --git a/src/Viewer.cc b/src/Viewer.cc index dec3204f53..6f5e83f375 100644 --- a/src/Viewer.cc +++ b/src/Viewer.cc @@ -22,6 +22,7 @@ #include #include +#include namespace ORB_SLAM2 {