File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -68,10 +68,14 @@ string(REGEX REPLACE "[ ]*\n" "; " CXX_VERSION_RESULT "${CXX_VERSION_RESULT}")
68
68
message (STATUS "Compiler: ${CXX_VERSION_RESULT} " )
69
69
70
70
# determine used C++ standard library (for debug and support purposes)
71
+ if (CMAKE_CROSSCOMPILING )
72
+ set (LIBCPP_VERSION_OUTPUT_CACHED "could not be detected due to cross-compiling" CACHE STRING "Detected C++ standard library version" )
73
+ endif ()
71
74
if (NOT DEFINED LIBCPP_VERSION_OUTPUT_CACHED )
72
75
try_run (RUN_RESULT_VAR COMPILE_RESULT_VAR
73
76
"${CMAKE_BINARY_DIR} " SOURCES "${CMAKE_SOURCE_DIR} /cmake/detect_libcpp_version.cpp"
74
- RUN_OUTPUT_VARIABLE LIBCPP_VERSION_OUTPUT COMPILE_OUTPUT_VARIABLE LIBCPP_VERSION_COMPILE_OUTPUT
77
+ RUN_OUTPUT_VARIABLE LIBCPP_VERSION_OUTPUT
78
+ COMPILE_OUTPUT_VARIABLE LIBCPP_VERSION_COMPILE_OUTPUT
75
79
)
76
80
if (NOT LIBCPP_VERSION_OUTPUT )
77
81
set (LIBCPP_VERSION_OUTPUT "Unknown" )
You can’t perform that action at this time.
0 commit comments