[Cmake] CMSYSTEMTOOLS_STANDALONE

Andy Cedilnik andy.cedilnik at kitware.com
Fri Nov 29 08:00:47 EST 2002


Hi John,

I think the idea sounds kind of cool, though I guess it would be easier
to just create system utils library, which would be linked to cmake.
This way we would clean it of the cmake stuff and put that to another
let say cmCMakeSystemUtilities.

Btw, I worked on cmWin32ProcessExecution long enough, so make sure to
use it...


				Andy

On Thu, 2002-11-28 at 09:28, John Biddiscombe wrote:
> I wanted to use some of the useful functions present in cmSystemTools in
> another project (not CMake), but found I needed to pull in quite a few other
> files as well.
> 
> I've added
> #ifndef CMSYSTEMTOOLS_STANDALONE
> 
> #endif // CMSYSTEMTOOLS_STANDALONE
> 
> around a number of functions in cmSystemTools.cxx and .h so that I can
> define this flag and use the string/directory/other functions without
> pulling in cmMakefile etc. The number of places where it was needed was
> fairly small, as it tuns out.
> 
> The way I've done it I need
> cmSystemTools
> cmRegularExpression
> cmDirectory
> in my external project, which seems quite tidy.
> 
> I have #ifndef'd out the FindLibrary function because it uses cmMakefile,
> and the RunCommand because it pulls in cmWin32ProcessExecution. However, the
> run commmand looks quite useful and I wonder if maybe I ought to put it back
> in.
> 
> Anyway. I feel this is a good thing, but won't commit it if people object.





More information about the CMake mailing list