-From 12d4c2e941d85a085b98a3e19b68d263ff8a5dd5 Mon Sep 17 00:00:00 2001
+From 4c12c3b2467682067c35815eb36de0f67364c7c0 Mon Sep 17 00:00:00 2001
 From: Martin Jansa <martin.jansa@lge.com>
 Date: Wed, 17 Feb 2021 17:30:59 +0000
 Subject: [PATCH] CmakeLists.txt: set C++ version to C++14

  without it, cartographer build fails with a lot of errors like:
  error: 'integer_sequence' is not a member of 'std'

Upstream-Status: Pending

Signed-off-by: Martin Jansa <martin.jansa@lge.com>
---
 CMakeLists.txt | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index cf040c6..ce09583 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -29,6 +29,7 @@ google_initialize_cartographer_project()
 google_enable_testing()
 
 find_package(Boost REQUIRED COMPONENTS iostreams)
+set(CMAKE_CXX_STANDARD 14)
 find_package(Ceres REQUIRED COMPONENTS SuiteSparse)
 find_package(Eigen3 REQUIRED)
 find_package(LuaGoogle REQUIRED)
@@ -235,7 +236,7 @@ if(${BUILD_PROMETHEUS})
   target_compile_definitions(${PROJECT_NAME} PUBLIC USE_PROMETHEUS=1)
 endif()
 

 set_target_properties(${PROJECT_NAME} PROPERTIES
   COMPILE_FLAGS ${TARGET_COMPILE_FLAGS})
 
diff --git a/cmake/functions.cmake b/cmake/functions.cmake
index c6ec093..f6927ec 100644
--- a/cmake/functions.cmake
+++ b/cmake/functions.cmake
@@ -72,7 +72,7 @@ macro(google_initialize_cartographer_project)
     set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH}
         ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules)
   endif()
-  set(GOOG_CXX_FLAGS "-pthread -std=c++11 -fPIC ${GOOG_CXX_FLAGS}")
+  set(GOOG_CXX_FLAGS "-pthread -fPIC ${GOOG_CXX_FLAGS}")
 
   google_add_flag(GOOG_CXX_FLAGS "-Wall")
   google_add_flag(GOOG_CXX_FLAGS "-Wpedantic")
