18

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
  • 18,825
  • 20
  • 87
  • 132
Velkan
  • 6,482
  • 5
  • 39
  • 76

1 Answers1

24

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
  • 36,020
  • 7
  • 116
  • 141