[CMake] How to find out the compiler directory?

Steven Van Ingelgem steven at vaningelgem.be
Sun Dec 30 13:26:10 EST 2007


Hey Andreas,


Thanks for your lengthy explanation! It got me searching through the
cmake files and finally I found the variable I need :-)

"CMAKE_MAKE_PROGRAM"... This always contains the path to the
make-tool, from which it's a small step to know the final directory.


Thanks a lot again!

On 12/30/07, Andreas Pakulat <apaku at gmx.de> wrote:
> On 30.12.07 18:09:49, Steven Van Ingelgem wrote:
> > It's because CMake get the values from the registry ;-). So it's not
> > known in the command line, but it's known to CMake... As opposed to
> > *NIX, Windows is not 100% (insert a lot of healthy sarcasm) command
> > line oriented.
>
> Oh, how do you know it does that? Have you looked at CMake's sources?
> I'd find that strange because cmake finds the compiler with a simple
> "find_program" call in CMakeDetermineCXXCompiler.cmake and according to
> its manual page that one doesn't search any registry keys.
>
> Neither does any file in cmake/Modules/ add a registry path that would
> allow to find the entry for cl.exe. And last but not least: cl.exe is
> not mentioned anywhere in the registry under Software/Microsoft/Visual
> Studio/. Though of course there are paths there which can be used to
> guess the bin dir for the compiler.
>
> I may be just overlooking something, so if you've found the place then
> please let me know.
>
> But I can confirm that CMake does find cl in a pretty "empty"
> environment. (one that only has standard paths and the cmake binary dir
> in it)
>
> Andreas
>
> --
> You may be gone tomorrow, but that doesn't mean that you weren't here today.
> _______________________________________________
> CMake mailing list
> CMake at cmake.org
> http://www.cmake.org/mailman/listinfo/cmake
>


More information about the CMake mailing list