diff --git a/CMakeLists.txt b/CMakeLists.txt index 9eea334..43eca2b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,10 +2,6 @@ cmake_minimum_required(VERSION 3.25) 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_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") target_link_libraries(example rum-shared) if(USE_FLAGS) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DUSE_FLAGS") target_link_libraries(example flags-cpp) endif() diff --git a/src/rum/http/request.cpp b/src/rum/http/request.cpp index 5a5b861..7d9f11e 100644 --- a/src/rum/http/request.cpp +++ b/src/rum/http/request.cpp @@ -1,6 +1,8 @@ #include #include +#if __cplusplus >= 202302L #include +#endif #include #include diff --git a/src/rum/http/response.cpp b/src/rum/http/response.cpp index cb72b99..f8326f1 100644 --- a/src/rum/http/response.cpp +++ b/src/rum/http/response.cpp @@ -1,7 +1,9 @@ #include #include #include +#if __cplusplus >= 202302L #include +#endif #include #include #include diff --git a/src/rum/http/uri.cpp b/src/rum/http/uri.cpp index 022d811..03d2ced 100644 --- a/src/rum/http/uri.cpp +++ b/src/rum/http/uri.cpp @@ -2,7 +2,9 @@ #include #include #include +#if __cplusplus >= 202302L #include +#endif #include namespace Rum::HTTP {