19

How to force it to keep temporaries like CMakeFiles/cmTC_66ca1.dir/link.txt or CMakeFiles/cmTC_66ca1.dir/testCCompiler.c.obj?

There is an error with the

The C compiler is not able to compile a simple test program

but all necessary files to launch commands separately are gone. It's very hard to analyze that.

Micha Wiedenmann
  • 19,979
  • 21
  • 92
  • 137
Velkan
  • 7,067
  • 6
  • 43
  • 87

1 Answers1

28

Call CMake with --debug-trycompile

cmake --debug-trycompile ...

Do not delete the try_compile build tree. Only useful on one try_compile at a time.

Florian
  • 39,996
  • 9
  • 133
  • 149