You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In building the tests for xtensor I saw the following:
xtensor/test > cmake .
CMake Error at /usr/share/cmake-3.20/Modules/FindThreads.cmake:66 (message):
FindThreads only works if either C or CXX language is enabled
Call Stack (most recent call first):
CMakeLists.txt:13 (find_package)
The following "hack" fixed the issue
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 6e5cc7b9..2b64ed5a 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -9,9 +9,6 @@
I'm also seeing issues when building wrt TEST_CASE_TEMPLATE (although I expect this is just having the wrong version of the test library; it would be nice if the CMakeLists.txt error'ed out unless the correct version is found).
The text was updated successfully, but these errors were encountered:
In building the tests for xtensor I saw the following:
xtensor/test > cmake .
CMake Error at /usr/share/cmake-3.20/Modules/FindThreads.cmake:66 (message):
FindThreads only works if either C or CXX language is enabled
Call Stack (most recent call first):
CMakeLists.txt:13 (find_package)
The following "hack" fixed the issue
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 6e5cc7b9..2b64ed5a 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -9,9 +9,6 @@
cmake_minimum_required(VERSION 3.1)
-find_package(doctest REQUIRED)
-find_package(Threads)
if (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
project(xtensor-test)
@@ -28,6 +25,9 @@ else()
message(STATUS "Tests build type is ${CMAKE_BUILD_TYPE}")
endif()
+find_package(doctest REQUIRED)
+find_package(Threads)
+
include(CheckCXXCompilerFlag)
string(TOUPPER "${CMAKE_BUILD_TYPE}" U_CMAKE_BUILD_TYPE)
I'm also seeing issues when building wrt TEST_CASE_TEMPLATE (although I expect this is just having the wrong version of the test library; it would be nice if the CMakeLists.txt error'ed out unless the correct version is found).
The text was updated successfully, but these errors were encountered: