[cmake-developers] Generating information for C++ tools in cmake (patch)

Manuel Klimek klimek at google.com
Fri Jan 14 18:19:38 EST 2011


Attached are 2 patches for caching the defines&flags and introducing
the options.

I'll look into testing next, any hints for what to look out for would
be appreciated ;)

Cheers,
/Manuel

On Fri, Jan 14, 2011 at 2:54 PM, Brad King <brad.king at kitware.com> wrote:
> On 01/14/2011 05:46 PM, Manuel Klimek wrote:
>> I'm currently trying to figure out the best point where to add that
>> option...
>
> In the cmMakefileTargetGenerator you can test for the option with
>
>  this->Makefile->IsOn("...")
>
>> Is there a good example I can base it on? So far I followed
>> CMAKE_BUILD_TYPE through the code base, which suggests that I need to
>> - find a .cmake file in modules in which I can put the option
>> - document it in cmDocumentVariables
>
> Probably like CMAKE_VERBOSE_MAKEFILE which is another option to the
> Makefile generator.  See CMakeGenericSystem.cmake.  Surround it by
>
>  if("${CMAKE_GENERATOR}" MATCHES "Make")
>     ...
>  endif()
>
> so that it only shows up for Makefile generators.
>
> -Brad
>



-- 
Manuel Klimek (http://go/klimek)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cmake-cache-defines.patch
Type: text/x-patch
Size: 5431 bytes
Desc: not available
URL: <http://public.kitware.com/pipermail/cmake-developers/attachments/20110114/b294fe3a/attachment-0004.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cmake-make-compile-command-output-optional.patch
Type: text/x-patch
Size: 1868 bytes
Desc: not available
URL: <http://public.kitware.com/pipermail/cmake-developers/attachments/20110114/b294fe3a/attachment-0005.bin>


More information about the cmake-developers mailing list