Am Samstag, 3. März 2012, 17:05:11 schrieb Yury G.  Kudryashov:
> Rolf Eike Beer wrote:
> > I have a small patch to CMake that looks like this:
> > +      if (!this->Makefile->IsOn("CMAKE_DEBUG_MESSAGES"))
>
> I propose to print message if one of the following holds:
> * CMAKE_DEBUG_MESSAGES is true;
> * CMAKE_DEBUG_MESSAGES_FileName is true, where FileName is
> CMAKE_CURRENT_LIST_FILE's name without extension;
> * Current list file is CMakeLists.txt and
> CMAKE_DEBUG_MESSAGES_CurrentDirectory is true.
>
> This will allow
>
> # Turn all debug messages
> -DCMAKE_DEBUG_MESSAGES=ON
> # Turn all debug messages in FindBoost.cmake
> -DCMAKE_DEBUG_MESSAGES_FindBoost=ON
> # Turn all debug messages in mysubdir/CMakeLists.txt
> -DCMAKE_DEBUG_MESSAGES_mysubdir=ON
> # Turn all debug messages in **/CMakeLists.txt
> -DCMAKE_DEBUG_MESSAGES_CMakeLists=ON

I'm not absolutely sure if this is worth the effort. Not that it is generally a
bad idea, but it will likely require some code. The way you simply could do
this stuff is to just put "set(CMAKE_DEBUG_MESSAGES On)" at the beginning of
the subdir/module you want to debug and reset it at the end.

Eike

Attachment: signature.asc
Description: This is a digitally signed message part.

--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to