Hi Bill,
> Von: "William A. Hoffman" <[EMAIL PROTECTED]>
>
> At 10:44 PM 4/7/2006, Tanner Lovelace wrote:
> >On 4/7/06, Alexander Neundorf <[EMAIL PROTECTED]> wrote:
> >> Hi,
> >>
> >> I think in the kdevelop project generator the cmake options
> >> CMAKE_COLOR_MAKEFILE should always be disabled and
> CMAKE_VERBOSE_MAKEFILE
> >> should always be enabled.
> >> How/where do I do this ?
> >> The reason: the log window of kdevelop doesn't interpret the color
> codes,
> >> so you only see the control characters, and kdevelop itself shortens
> the
> >> ouput, so that there is no problem with the full output.
> >>
> >> So, where to do it ?
> >
> >How about putting something like this in the main CMakeLists.txt file?
> >
> >IF(CMAKE_GENERATOR MATCHES "KDevelop3")
> > SET(CMAKE_COLOR_MAKEFILE OFF)
> > SET(CMAKE_VERBOSE_MAKEFILE ON)
> >ENDIF(CMAKE_GENERATOR MATCHES "KDevelop3)
>
> I think this has to be done in the generator so that projects can not
set
> values
> that cause kdevelop not to work.
>
> For the color stuff, you can just set this in the constructor
> cmGlobalKdevelopGenerator()
> {
> this->ToolSupportsColorVT100 = false
> }
>
> For the VERBOSE stuff, you can do this:
> Add an ivar to cmLocalUnixMakefileGenerator3
> bool ForceVerbose;
> initialize it to false in cmLocalUnixMakefileGenerator3.
> But in cmLocalKdevelopGenerator() set it to true.
>
> Then in cmLocalUnixMakefileGenerator3
> ::WriteSpecialTargetsTop()
>
> if(this->Makefile->IsOn("CMAKE_VERBOSE_MAKEFILE") ||
this->ForceVerbose)
>
> Alternatively, you could make sure that when kdevelop runs make
> it always does make VERBOSE=1.
>
> Figure what works best and send me a patch.
the attached patch does just what you suggested. The color was already
disabled, strange. Yesterday or the day before I had the control
characters in kdevelop. Hmm.
Please apply.
Bye
Alex
--
GMX Produkte empfehlen und ganz einfach Geld verdienen!
Satte Provisionen für GMX Partner: http://www.gmx.net/de/go/partner
Index: Source/cmLocalKdevelopGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmLocalKdevelopGenerator.cxx,v
retrieving revision 1.18
diff -b -u -p -r1.18 cmLocalKdevelopGenerator.cxx
--- Source/cmLocalKdevelopGenerator.cxx 18 Oct 2005 20:09:34 -0000 1.18
+++ Source/cmLocalKdevelopGenerator.cxx 8 Apr 2006 16:25:48 -0000
@@ -29,6 +29,10 @@
cmLocalKdevelopGenerator::cmLocalKdevelopGenerator()
:cmLocalUnixMakefileGenerator3()
{
+ // KDevelop can itself shorten the output, so it should
+ // always get the full output, otherwise the "full output"
+ // option in kdevelop doesn't make much sense, Alex
+ this->ForceVerboseMakefiles=true;
}
cmLocalKdevelopGenerator::~cmLocalKdevelopGenerator()
Index: Source/cmLocalUnixMakefileGenerator3.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmLocalUnixMakefileGenerator3.cxx,v
retrieving revision 1.126
diff -b -u -p -r1.126 cmLocalUnixMakefileGenerator3.cxx
--- Source/cmLocalUnixMakefileGenerator3.cxx 30 Mar 2006 20:39:03 -0000 1.126
+++ Source/cmLocalUnixMakefileGenerator3.cxx 8 Apr 2006 16:25:48 -0000
@@ -69,6 +69,7 @@ cmLocalUnixMakefileGenerator3::cmLocalUn
this->EchoNeedsQuote = true;
this->DefineWindowsNULL = false;
this->UnixCD = true;
+ this->ForceVerboseMakefiles=false;
}
//----------------------------------------------------------------------------
@@ -599,7 +600,7 @@ cmLocalUnixMakefileGenerator3
std::vector<std::string> commands;
std::vector<std::string> no_depends;
commands.clear();
- if(this->Makefile->IsOn("CMAKE_VERBOSE_MAKEFILE"))
+ if((this->Makefile->IsOn("CMAKE_VERBOSE_MAKEFILE")) || (this->ForceVerboseMakefiles))
{
makefileStream
<< "# Produce verbose output by default.\n"
Index: Source/cmLocalUnixMakefileGenerator3.h
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmLocalUnixMakefileGenerator3.h,v
retrieving revision 1.44
diff -b -u -p -r1.44 cmLocalUnixMakefileGenerator3.h
--- Source/cmLocalUnixMakefileGenerator3.h 30 Mar 2006 20:39:03 -0000 1.44
+++ Source/cmLocalUnixMakefileGenerator3.h 8 Apr 2006 16:25:48 -0000
@@ -279,6 +279,7 @@ protected:
const std::vector<std::string>& files,
cmTarget& target, const char* filename =0);
+ bool ForceVerboseMakefiles;
private:
friend class cmMakefileTargetGenerator;
friend class cmMakefileExecutableTargetGenerator;
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake