[CMake] RE: CMake 2.4.1/VC71 Why the wierd <project>.dir subdirs?

Rob Mathews Rob.Mathews at varolii.com
Wed May 9 10:29:11 EDT 2007


So I guess the important question for me is, is there a knob somewhere
that can make it work the old way? 

Otherwise I have to add a knob to get back the old behaviour ... because
I have other link lines in other non-CMake projects that depend on
particular locations for the .lib files ...

-----Original Message-----
From: Bill Hoffman [mailto:bill.hoffman at kitware.com] 
Sent: Wednesday, May 09, 2007 10:04 AM
To: Rob Mathews
Cc: cmake at cmake.org
Subject: Re: CMake 2.4.1/VC71 Why the wierd <project>.dir subdirs?

Rob Mathews wrote:
> CMake seems to be generating intermediate directories called
> <project-name>.dir and placing the obj files under them. 
>
> Ie, if my project is foo, then /foo/foo.dir/*.obj
>
> I look in the code and see that this derives from
> cmLocalVisual7Generator.cxx, which reads as follows. (The "#if 0" is
my
> addition)
>
> std::string cmLocalVisualStudio7Generator
> ::GetTargetDirectory(cmTarget& target)
> {
> #if 0
> why???? this replaces the old structure of <project>/Debug with
> <project>/<project>.dir/Debug. What's the point????!!!
> 	std::string dir;
>   dir += target.GetName();
>   dir += ".dir";
>   return dir;
> #endif
>   return ".";
> }
>
>
> As I say, what's the point? 
>
>
>   
So, you can have two object files with the same name in two different 
directories.  Each target's .obj files are isolated into a separate sub 
directory.

-Bill





More information about the CMake mailing list