File tree Expand file tree Collapse file tree 2 files changed +20
-0
lines changed
Expand file tree Collapse file tree 2 files changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -36,6 +36,18 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
3636 set (CMAKE_CXX_STANDARD_REQUIRED YES )
3737endif ()
3838
39+ # Failing inline try_compile example
40+ try_compile (HAS_BOGUS
41+ "${CMAKE_BINARY_DIR} /try_bogus" # binary dir for the test
42+ SOURCE "int main() { return bogus(); }"
43+ )
44+
45+ if (HAS_BOGUS)
46+ message (STATUS "bogus() exists" )
47+ else ()
48+ message (STATUS "bogus() not found (expected failure)" )
49+ endif ()
50+
3951include ("cmake/compat_find.cmake" )
4052
4153find_package (Threads REQUIRED)
Original file line number Diff line number Diff line change @@ -47,6 +47,14 @@ if ! cmake "$src_dir" "${cmake_args[@]}"; then
4747 # Could add --trace / --trace-expand here too but they are very verbose.
4848 cmake_args+=(--debug-find --debug-trycompile --log-level=DEBUG -DCMAKE_TRY_COMPILE_NO_CLEAN=ON)
4949 cmake " $src_dir " " ${cmake_args[@]} " || echo " cmake exited with $? "
50+ echo " === CMakeConfigureLog.yaml ==="
51+ if [ -f CMakeFiles/CMakeConfigureLog.yaml ]; then
52+ cat CMakeFiles/CMakeConfigureLog.yaml
53+ else
54+ echo " (no configure log found)"
55+ fi
56+
57+
5058 find . -ls
5159 find . -type f -name CMakeOutput.log -exec sh -c ' echo "--- {} ---"; cat "{}"' \;
5260 find . -type f -name CMakeError.log -exec sh -c ' echo "--- {} ---"; cat "{}"' \;
You can’t perform that action at this time.
0 commit comments