Fixed building on macos
This commit is contained in:
@@ -17,8 +17,10 @@
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <map>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
namespace clanguml {
|
||||
namespace config {
|
||||
|
||||
@@ -39,6 +39,8 @@ endif(MSVC)
|
||||
|
||||
list(FIND CMAKE_CXX_COMPILE_FEATURES cxx_std_20 SUPPORTS_CXX_STD_20)
|
||||
|
||||
message(STATUS "Enabling C++20 test cases")
|
||||
|
||||
# Remove test cases which require C++20 if they are not supported here
|
||||
if(SUPPORTS_CXX_STD_20 EQUAL -1
|
||||
OR ${LLVM_PACKAGE_VERSION} VERSION_LESS "14.0")
|
||||
@@ -55,6 +57,13 @@ else()
|
||||
set(ENABLE_CXX_STD_20_TEST_CASES 1)
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
# On Apple Clang <coroutine> header is not available
|
||||
list(FILTER TEST_CASE_SOURCES
|
||||
EXCLUDE
|
||||
REGEX ".*t00069.*")
|
||||
endif(APPLE)
|
||||
|
||||
set(TEST_NAMES
|
||||
test_util
|
||||
test_model
|
||||
|
||||
@@ -405,8 +405,10 @@ using namespace clanguml::test::matchers;
|
||||
#include "t00067/test_case.h"
|
||||
#include "t00068/test_case.h"
|
||||
#if defined(ENABLE_CXX_STD_20_TEST_CASES)
|
||||
#if __has_include(<coroutine>)
|
||||
#include "t00069/test_case.h"
|
||||
#endif
|
||||
#endif
|
||||
#if defined(ENABLE_CXX_MODULES_TEST_CASES)
|
||||
#include "t00070/test_case.h"
|
||||
#include "t00071/test_case.h"
|
||||
@@ -523,4 +525,4 @@ int main(int argc, char *argv[])
|
||||
clih.handle_options(argvv.size(), argvv.data());
|
||||
|
||||
return session.run();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user