macro(standard_setup version)
  set(CMAKE_CXX_STANDARD ${version})
  set(CMAKE_CXX_STANDARD_REQUIRED ON)
  set(CMAKE_CXX_EXTENSIONS OFF)
  
  # Generate compile_commands.json to make it easier to work with clang based
  # tools
  set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
  
  #include(CheckIPOSupported)
  #check_ipo_supported(RESULT result OUTPUT output)
  #if(result)
  #  set(CMAKE_INTERPROCEDURAL_OPTIMIZATION TRUE)
  #else()
  #  message(SEND_ERROR "IPO is not supported: ${output}")
  #endif()
endmacro()