From 78c16564ac253f3348b86ff0c9ad0b0fd3f648dd Mon Sep 17 00:00:00 2001 From: Vaxry Date: Mon, 12 Feb 2024 17:23:15 +0000 Subject: [PATCH] build: unbreak clang --- CMakeLists.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 5f32ef5..1095e7c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -30,6 +30,12 @@ set_target_properties(hyprlang PROPERTIES SOVERSION 0 PUBLIC_HEADER include/hyprlang.hpp) +if (CMAKE_CXX_COMPILER_ID MATCHES "Clang") + # for std::expected. + # probably evil. Arch's clang is very outdated tho... + target_compile_options(hyprlang PUBLIC -std=gnu++2b -D__cpp_concepts=202002L -Wno-macro-redefined) +endif() + install(TARGETS hyprlang) # tests