c++20 support
This commit is contained in:
parent
8da3921507
commit
f77c95e99e
@ -2,10 +2,6 @@ cmake_minimum_required(VERSION 3.25)
|
|||||||
|
|
||||||
project(Rum VERSION 1.0)
|
project(Rum VERSION 1.0)
|
||||||
|
|
||||||
# compiler setup
|
|
||||||
set(CMAKE_C_COMPILER gcc)
|
|
||||||
set(CMAKE_CXX_COMPILER g++)
|
|
||||||
|
|
||||||
set(CMAKE_CXX_STANDARD 20)
|
set(CMAKE_CXX_STANDARD 20)
|
||||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
|
|
||||||
@ -31,6 +27,7 @@ target_include_directories(rum-shared PUBLIC "${CMAKE_SOURCE_DIR}/inc")
|
|||||||
add_executable(example "${CMAKE_SOURCE_DIR}/src/server.cpp")
|
add_executable(example "${CMAKE_SOURCE_DIR}/src/server.cpp")
|
||||||
target_link_libraries(example rum-shared)
|
target_link_libraries(example rum-shared)
|
||||||
if(USE_FLAGS)
|
if(USE_FLAGS)
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DUSE_FLAGS")
|
||||||
target_link_libraries(example flags-cpp)
|
target_link_libraries(example flags-cpp)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
#include <rum/http/method.h>
|
#include <rum/http/method.h>
|
||||||
#include <rum/http/request.h>
|
#include <rum/http/request.h>
|
||||||
|
#if __cplusplus >= 202302L
|
||||||
#include <format>
|
#include <format>
|
||||||
|
#endif
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
|
@ -1,7 +1,9 @@
|
|||||||
#include <rum/http/response.h>
|
#include <rum/http/response.h>
|
||||||
#include <rum/tcp/error.h>
|
#include <rum/tcp/error.h>
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
|
#if __cplusplus >= 202302L
|
||||||
#include <format>
|
#include <format>
|
||||||
|
#endif
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <stdexcept>
|
#include <stdexcept>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
@ -2,7 +2,9 @@
|
|||||||
#include <exception>
|
#include <exception>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <regex>
|
#include <regex>
|
||||||
|
#if __cplusplus >= 202302L
|
||||||
#include <format>
|
#include <format>
|
||||||
|
#endif
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
namespace Rum::HTTP {
|
namespace Rum::HTTP {
|
||||||
|
Loading…
Reference in New Issue
Block a user