Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
CMake
CMake
Commits
369308ca
Commit
369308ca
authored
Jun 22, 2005
by
Ken Martin
Browse files
ENH: make LOCATION an computed property of the target and get rid of a bunch of const junk
parent
5fab6eeb
Changes
27
Hide whitespace changes
Inline
Side-by-side
Source/cmExportLibraryDependencies.cxx
View file @
369308ca
...
...
@@ -91,7 +91,7 @@ void cmExportLibraryDependenciesCommand::FinalPass()
cmTargets
&
tgts
=
gen
->
GetMakefile
()
->
GetTargets
();
std
::
vector
<
std
::
string
>
depends
;
const
char
*
defType
;
for
(
cmTargets
::
const_
iterator
l
=
tgts
.
begin
();
for
(
cmTargets
::
iterator
l
=
tgts
.
begin
();
l
!=
tgts
.
end
();
++
l
)
{
if
((
l
->
second
.
GetType
()
!=
cmTarget
::
INSTALL_FILES
)
...
...
Source/cmGlobalGenerator.cxx
View file @
369308ca
...
...
@@ -531,9 +531,9 @@ void cmGlobalGenerator::Configure()
{
manager
=
m_LocalGenerators
[
i
]
->
GetMakefile
()
->
GetCacheManager
();
m_LocalGenerators
[
i
]
->
ConfigureFinalPass
();
cmTargets
const
&
targets
=
cmTargets
&
targets
=
m_LocalGenerators
[
i
]
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
const_
iterator
l
=
targets
.
begin
();
for
(
cmTargets
::
iterator
l
=
targets
.
begin
();
l
!=
targets
.
end
();
l
++
)
{
cmTarget
::
LinkLibraries
libs
=
l
->
second
.
GetLinkLibraries
();
...
...
Source/cmGlobalKdevelopGenerator.cxx
View file @
369308ca
...
...
@@ -78,7 +78,7 @@ void cmGlobalKdevelopGenerator::Generate()
//run from kdevelop for now just pick the first executable found
std
::
string
executable
;
cmTargets
&
targets
=
mf
->
GetTargets
();
for
(
cmTargets
::
const_
iterator
ti
=
targets
.
begin
();
for
(
cmTargets
::
iterator
ti
=
targets
.
begin
();
ti
!=
targets
.
end
();
ti
++
)
{
if
(
ti
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
...
...
@@ -134,7 +134,7 @@ bool cmGlobalKdevelopGenerator
//get all sources
cmTargets
&
targets
=
makefile
->
GetTargets
();
for
(
cmTargets
::
const_
iterator
ti
=
targets
.
begin
();
for
(
cmTargets
::
iterator
ti
=
targets
.
begin
();
ti
!=
targets
.
end
();
ti
++
)
{
const
std
::
vector
<
cmSourceFile
*>&
sources
=
ti
->
second
.
GetSourceFiles
();
...
...
Source/cmGlobalUnixMakefileGenerator3.cxx
View file @
369308ca
...
...
@@ -467,7 +467,7 @@ cmGlobalUnixMakefileGenerator3
std
::
vector
<
std
::
string
>
all_tgts
;
// for all of out targets
for
(
cmTargets
::
const_
iterator
l
=
lg
->
GetMakefile
()
->
GetTargets
().
begin
();
for
(
cmTargets
::
iterator
l
=
lg
->
GetMakefile
()
->
GetTargets
().
begin
();
l
!=
lg
->
GetMakefile
()
->
GetTargets
().
end
();
l
++
)
{
if
((
l
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
||
...
...
@@ -528,7 +528,7 @@ cmGlobalUnixMakefileGenerator3
std
::
vector
<
std
::
string
>
all_tgts
;
// for all of out targets
for
(
cmTargets
::
const_
iterator
l
=
lg
->
GetMakefile
()
->
GetTargets
().
begin
();
for
(
cmTargets
::
iterator
l
=
lg
->
GetMakefile
()
->
GetTargets
().
begin
();
l
!=
lg
->
GetMakefile
()
->
GetTargets
().
end
();
l
++
)
{
if
((
l
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
||
...
...
@@ -597,7 +597,7 @@ cmGlobalUnixMakefileGenerator3
std
::
vector
<
std
::
string
>
all_tgts
;
// for all of out targets
for
(
cmTargets
::
const_
iterator
l
=
lg
->
GetMakefile
()
->
GetTargets
().
begin
();
for
(
cmTargets
::
iterator
l
=
lg
->
GetMakefile
()
->
GetTargets
().
begin
();
l
!=
lg
->
GetMakefile
()
->
GetTargets
().
end
();
l
++
)
{
if
((
l
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
||
...
...
@@ -658,7 +658,7 @@ cmGlobalUnixMakefileGenerator3
std
::
vector
<
std
::
string
>
all_tgts
;
// for all of out targets
for
(
cmTargets
::
const_
iterator
l
=
lg
->
GetMakefile
()
->
GetTargets
().
begin
();
for
(
cmTargets
::
iterator
l
=
lg
->
GetMakefile
()
->
GetTargets
().
begin
();
l
!=
lg
->
GetMakefile
()
->
GetTargets
().
end
();
l
++
)
{
if
((
l
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
||
...
...
@@ -713,8 +713,8 @@ cmGlobalUnixMakefileGenerator3
depends
.
push_back
(
"cmake_check_build_system"
);
// for each target Generate the rule files for each target.
const
cmTargets
&
targets
=
lg
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
const_
iterator
t
=
targets
.
begin
();
t
!=
targets
.
end
();
++
t
)
cmTargets
&
targets
=
lg
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
iterator
t
=
targets
.
begin
();
t
!=
targets
.
end
();
++
t
)
{
if
((
t
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
||
(
t
->
second
.
GetType
()
==
cmTarget
::
STATIC_LIBRARY
)
||
...
...
@@ -767,9 +767,9 @@ cmGlobalUnixMakefileGenerator3
depends
.
push_back
(
"cmake_check_build_system"
);
// for each target Generate the rule files for each target.
const
cmTargets
&
targets
=
lg
->
GetMakefile
()
->
GetTargets
();
cmTargets
&
targets
=
lg
->
GetMakefile
()
->
GetTargets
();
bool
needRequiresStep
=
this
->
NeedRequiresStep
(
lg
);
for
(
cmTargets
::
const_
iterator
t
=
targets
.
begin
();
t
!=
targets
.
end
();
++
t
)
for
(
cmTargets
::
iterator
t
=
targets
.
begin
();
t
!=
targets
.
end
();
++
t
)
{
if
(((
t
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
||
(
t
->
second
.
GetType
()
==
cmTarget
::
STATIC_LIBRARY
)
||
...
...
@@ -870,7 +870,7 @@ cmGlobalUnixMakefileGenerator3
void
cmGlobalUnixMakefileGenerator3
::
AppendGlobalTargetDepends
(
std
::
vector
<
std
::
string
>&
depends
,
const
cmTarget
&
target
)
cmTarget
&
target
)
{
// Keep track of dependencies already listed.
std
::
set
<
cmStdString
>
emitted
;
...
...
@@ -964,8 +964,8 @@ cmGlobalUnixMakefileGenerator3::WriteHelpRule(std::ostream& ruleFileStream)
lg
=
static_cast
<
cmLocalUnixMakefileGenerator3
*>
(
m_LocalGenerators
[
i
]);
// for each target Generate the rule files for each target.
const
cmTargets
&
targets
=
lg
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
const_
iterator
t
=
targets
.
begin
();
t
!=
targets
.
end
();
++
t
)
cmTargets
&
targets
=
lg
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
iterator
t
=
targets
.
begin
();
t
!=
targets
.
end
();
++
t
)
{
if
((
t
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
||
(
t
->
second
.
GetType
()
==
cmTarget
::
STATIC_LIBRARY
)
||
...
...
Source/cmGlobalUnixMakefileGenerator3.h
View file @
369308ca
...
...
@@ -106,7 +106,7 @@ protected:
cmLocalUnixMakefileGenerator3
*
lg
);
void
AppendGlobalTargetDepends
(
std
::
vector
<
std
::
string
>&
depends
,
const
cmTarget
&
target
);
cmTarget
&
target
);
void
AppendAnyGlobalDepend
(
std
::
vector
<
std
::
string
>&
depends
,
const
char
*
name
);
...
...
Source/cmGlobalVisualStudio6Generator.cxx
View file @
369308ca
...
...
@@ -247,9 +247,8 @@ void cmGlobalVisualStudio6Generator::WriteDSWFile(std::ostream& fout,
unsigned
int
j
;
for
(
j
=
0
;
j
<
generators
.
size
();
++
j
)
{
const
cmTargets
&
atgts
=
generators
[
j
]
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
const_iterator
al
=
atgts
.
begin
();
cmTargets
&
atgts
=
generators
[
j
]
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
iterator
al
=
atgts
.
begin
();
al
!=
atgts
.
end
();
++
al
)
{
if
(
al
->
second
.
IsInAll
())
...
...
@@ -368,7 +367,7 @@ void cmGlobalVisualStudio6Generator::OutputDSWFile()
void
cmGlobalVisualStudio6Generator
::
WriteProject
(
std
::
ostream
&
fout
,
const
char
*
dspname
,
const
char
*
dir
,
const
cmTarget
&
target
)
cmTarget
&
target
)
{
fout
<<
"#########################################################"
"######################
\n\n
"
;
...
...
Source/cmGlobalVisualStudio6Generator.h
View file @
369308ca
...
...
@@ -79,8 +79,7 @@ private:
void
WriteDSWFile
(
std
::
ostream
&
fout
);
void
WriteDSWHeader
(
std
::
ostream
&
fout
);
void
WriteProject
(
std
::
ostream
&
fout
,
const
char
*
name
,
const
char
*
path
,
const
cmTarget
&
t
);
const
char
*
name
,
const
char
*
path
,
cmTarget
&
t
);
void
WriteExternalProject
(
std
::
ostream
&
fout
,
const
char
*
name
,
const
char
*
path
,
const
std
::
vector
<
std
::
string
>&
dependencies
);
...
...
Source/cmGlobalVisualStudio71Generator.cxx
View file @
369308ca
...
...
@@ -96,9 +96,8 @@ void cmGlobalVisualStudio71Generator::WriteSLNFile(std::ostream& fout,
unsigned
int
j
;
for
(
j
=
0
;
j
<
generators
.
size
();
++
j
)
{
const
cmTargets
&
atgts
=
generators
[
j
]
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
const_iterator
al
=
atgts
.
begin
();
cmTargets
&
atgts
=
generators
[
j
]
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
iterator
al
=
atgts
.
begin
();
al
!=
atgts
.
end
();
++
al
)
{
if
(
al
->
second
.
IsInAll
())
...
...
@@ -229,7 +228,7 @@ void
cmGlobalVisualStudio71Generator
::
WriteProject
(
std
::
ostream
&
fout
,
const
char
*
dspname
,
const
char
*
dir
,
const
cmTarget
&
t
)
cmTarget
&
t
)
{
std
::
string
d
=
cmSystemTools
::
ConvertToOutputPath
(
dir
);
fout
<<
"Project(
\"
{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}
\"
) =
\"
"
...
...
@@ -252,8 +251,7 @@ void
cmGlobalVisualStudio71Generator
::
WriteProjectDepends
(
std
::
ostream
&
fout
,
const
char
*
dspname
,
const
char
*
,
const
cmTarget
&
target
)
const
char
*
,
cmTarget
&
target
)
{
// insert Begin Project Dependency Project_Dep_Name project stuff here
if
(
target
.
GetType
()
!=
cmTarget
::
STATIC_LIBRARY
)
...
...
Source/cmGlobalVisualStudio71Generator.h
View file @
369308ca
...
...
@@ -47,11 +47,9 @@ protected:
cmLocalGenerator
*
root
,
std
::
vector
<
cmLocalGenerator
*>&
generators
);
virtual
void
WriteProject
(
std
::
ostream
&
fout
,
const
char
*
name
,
const
char
*
path
,
const
cmTarget
&
t
);
const
char
*
name
,
const
char
*
path
,
cmTarget
&
t
);
virtual
void
WriteProjectDepends
(
std
::
ostream
&
fout
,
const
char
*
name
,
const
char
*
path
,
const
cmTarget
&
t
);
const
char
*
name
,
const
char
*
path
,
cmTarget
&
t
);
virtual
void
WriteProjectConfigurations
(
std
::
ostream
&
fout
,
const
char
*
name
,
bool
in_all
);
virtual
void
WriteExternalProject
(
std
::
ostream
&
fout
,
const
char
*
name
,
const
char
*
path
,
const
std
::
vector
<
std
::
string
>&
depends
);
...
...
Source/cmGlobalVisualStudio7Generator.cxx
View file @
369308ca
...
...
@@ -312,9 +312,8 @@ void cmGlobalVisualStudio7Generator::WriteSLNFile(std::ostream& fout,
unsigned
int
j
;
for
(
j
=
0
;
j
<
generators
.
size
();
++
j
)
{
const
cmTargets
&
atgts
=
generators
[
j
]
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
const_iterator
al
=
atgts
.
begin
();
cmTargets
&
atgts
=
generators
[
j
]
->
GetMakefile
()
->
GetTargets
();
for
(
cmTargets
::
iterator
al
=
atgts
.
begin
();
al
!=
atgts
.
end
();
++
al
)
{
if
(
al
->
second
.
IsInAll
())
...
...
@@ -498,8 +497,7 @@ void cmGlobalVisualStudio7Generator::WriteSLNFile(std::ostream& fout,
// the libraries it uses are also done here
void
cmGlobalVisualStudio7Generator
::
WriteProject
(
std
::
ostream
&
fout
,
const
char
*
dspname
,
const
char
*
dir
,
const
cmTarget
&
)
const
char
*
dir
,
cmTarget
&
)
{
std
::
string
d
=
cmSystemTools
::
ConvertToOutputPath
(
dir
);
fout
<<
"Project(
\"
{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}
\"
) =
\"
"
...
...
@@ -517,8 +515,7 @@ void
cmGlobalVisualStudio7Generator
::
WriteProjectDepends
(
std
::
ostream
&
fout
,
const
char
*
dspname
,
const
char
*
,
const
cmTarget
&
target
)
const
char
*
,
cmTarget
&
target
)
{
int
depcount
=
0
;
// insert Begin Project Dependency Project_Dep_Name project stuff here
...
...
Source/cmGlobalVisualStudio7Generator.h
View file @
369308ca
...
...
@@ -86,11 +86,9 @@ protected:
virtual
void
WriteSLNFile
(
std
::
ostream
&
fout
,
cmLocalGenerator
*
root
,
std
::
vector
<
cmLocalGenerator
*>&
generators
);
virtual
void
WriteProject
(
std
::
ostream
&
fout
,
const
char
*
name
,
const
char
*
path
,
const
cmTarget
&
t
);
const
char
*
name
,
const
char
*
path
,
cmTarget
&
t
);
virtual
void
WriteProjectDepends
(
std
::
ostream
&
fout
,
const
char
*
name
,
const
char
*
path
,
const
cmTarget
&
t
);
const
char
*
name
,
const
char
*
path
,
cmTarget
&
t
);
virtual
void
WriteProjectConfigurations
(
std
::
ostream
&
fout
,
const
char
*
name
,
bool
in_all
);
virtual
void
WriteSLNFooter
(
std
::
ostream
&
fout
);
virtual
void
WriteSLNHeader
(
std
::
ostream
&
fout
);
...
...
Source/cmLocalGenerator.cxx
View file @
369308ca
...
...
@@ -190,7 +190,7 @@ void cmLocalGenerator::GenerateTestFiles()
void
cmLocalGenerator
::
GenerateInstallRules
()
{
const
cmTargets
&
tgts
=
m_Makefile
->
GetTargets
();
cmTargets
&
tgts
=
m_Makefile
->
GetTargets
();
const
char
*
prefix
=
m_Makefile
->
GetDefinition
(
"CMAKE_INSTALL_PREFIX"
);
#if defined(_WIN32) && !defined(__CYGWIN__)
...
...
@@ -283,7 +283,7 @@ void cmLocalGenerator::GenerateInstallRules()
}
std
::
string
destination
;
for
(
cmTargets
::
const_
iterator
l
=
tgts
.
begin
();
for
(
cmTargets
::
iterator
l
=
tgts
.
begin
();
l
!=
tgts
.
end
();
l
++
)
{
const
char
*
preinstall
=
l
->
second
.
GetProperty
(
"PRE_INSTALL_SCRIPT"
);
...
...
@@ -1164,8 +1164,8 @@ void cmLocalGenerator::GetTargetFlags(std::string& linkLibs,
* to the name of the library. This will not link a library against itself.
*/
void
cmLocalGenerator
::
OutputLinkLibraries
(
std
::
ostream
&
fout
,
const
char
*
targetLibrary
,
const
cmTarget
&
tgt
)
const
char
*
targetLibrary
,
cmTarget
&
tgt
)
{
// Try to emit each search path once
std
::
set
<
cmStdString
>
emitted
;
...
...
Source/cmLocalGenerator.h
View file @
369308ca
...
...
@@ -154,7 +154,7 @@ protected:
cmTarget
&
target
);
///! put all the libraries for a target on into the given stream
virtual
void
OutputLinkLibraries
(
std
::
ostream
&
,
const
char
*
name
,
const
cmTarget
&
);
virtual
void
OutputLinkLibraries
(
std
::
ostream
&
,
const
char
*
name
,
cmTarget
&
);
/** Get the include flags for the current makefile and language. */
...
...
Source/cmLocalUnixMakefileGenerator3.cxx
View file @
369308ca
...
...
@@ -160,7 +160,7 @@ void cmLocalUnixMakefileGenerator3::FormatOutputPath(std::string& path,
void
cmLocalUnixMakefileGenerator3
::
WriteCustomCommands
(
const
cmTarget
&
target
,
std
::
ostream
&
ruleFileStream
,
::
WriteCustomCommands
(
cmTarget
&
target
,
std
::
ostream
&
ruleFileStream
,
std
::
vector
<
std
::
string
>&
cleanFiles
)
{
std
::
string
tgtDir
=
m_Makefile
->
GetStartOutputDirectory
();
...
...
@@ -303,7 +303,7 @@ const std::string &cmLocalUnixMakefileGenerator3::GetHomeRelativeOutputPath()
//----------------------------------------------------------------------------
void
cmLocalUnixMakefileGenerator3
::
WriteTargetRuleFiles
(
const
cmTarget
&
target
)
::
WriteTargetRuleFiles
(
cmTarget
&
target
)
{
// Create a directory for this target.
std
::
string
dir
=
this
->
GetTargetDirectory
(
target
);
...
...
@@ -496,7 +496,7 @@ void
cmLocalUnixMakefileGenerator3
::
WriteObjectBuildFile
(
std
::
string
&
obj
,
const
char
*
lang
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
cmSourceFile
&
source
,
std
::
vector
<
std
::
string
>&
depends
,
std
::
string
&
depMakeFile
)
...
...
@@ -649,7 +649,7 @@ cmLocalUnixMakefileGenerator3
//----------------------------------------------------------------------------
void
cmLocalUnixMakefileGenerator3
::
WriteObjectRuleFiles
(
const
cmTarget
&
target
,
const
cmSourceFile
&
source
,
::
WriteObjectRuleFiles
(
cmTarget
&
target
,
const
cmSourceFile
&
source
,
std
::
vector
<
std
::
string
>&
objects
)
{
// Identify the language of the source file.
...
...
@@ -771,7 +771,7 @@ cmLocalUnixMakefileGenerator3
//----------------------------------------------------------------------------
void
cmLocalUnixMakefileGenerator3
::
WriteUtilityRuleFiles
(
const
cmTarget
&
target
)
::
WriteUtilityRuleFiles
(
cmTarget
&
target
)
{
// Create a directory for this target.
std
::
string
dir
=
this
->
GetTargetDirectory
(
target
);
...
...
@@ -1253,7 +1253,7 @@ cmLocalUnixMakefileGenerator3
//----------------------------------------------------------------------------
void
cmLocalUnixMakefileGenerator3
::
WriteTargetRequiresRule
(
std
::
ostream
&
ruleFileStream
,
const
cmTarget
&
target
,
::
WriteTargetRequiresRule
(
std
::
ostream
&
ruleFileStream
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
)
{
std
::
vector
<
std
::
string
>
depends
;
...
...
@@ -1285,7 +1285,7 @@ void
cmLocalUnixMakefileGenerator3
::
WriteExecutableRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
vector
<
std
::
string
>&
cleanFiles
)
...
...
@@ -1468,7 +1468,7 @@ void
cmLocalUnixMakefileGenerator3
::
WriteStaticLibraryRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
vector
<
std
::
string
>&
cleanFiles
)
...
...
@@ -1494,7 +1494,7 @@ void
cmLocalUnixMakefileGenerator3
::
WriteSharedLibraryRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
vector
<
std
::
string
>&
cleanFiles
)
...
...
@@ -1536,7 +1536,7 @@ void
cmLocalUnixMakefileGenerator3
::
WriteModuleLibraryRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
vector
<
std
::
string
>&
cleanFiles
)
...
...
@@ -1564,7 +1564,7 @@ void
cmLocalUnixMakefileGenerator3
::
WriteLibraryRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
const
char
*
linkRuleVar
,
...
...
@@ -1793,7 +1793,7 @@ cmLocalUnixMakefileGenerator3
void
cmLocalUnixMakefileGenerator3
::
WriteObjectsVariable
(
std
::
ostream
&
ruleFileStream
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
string
&
variableName
,
...
...
@@ -1844,7 +1844,7 @@ cmLocalUnixMakefileGenerator3
void
cmLocalUnixMakefileGenerator3
::
WriteTargetDependRule
(
std
::
ostream
&
ruleFileStream
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
)
{
std
::
vector
<
std
::
string
>
depends
;
...
...
@@ -1875,7 +1875,7 @@ cmLocalUnixMakefileGenerator3
void
cmLocalUnixMakefileGenerator3
::
WriteTargetCleanRule
(
std
::
ostream
&
ruleFileStream
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
files
)
{
std
::
vector
<
std
::
string
>
no_depends
;
...
...
@@ -1922,7 +1922,7 @@ cmLocalUnixMakefileGenerator3
//----------------------------------------------------------------------------
std
::
string
cmLocalUnixMakefileGenerator3
::
GetTargetDirectory
(
const
cmTarget
&
target
)
cmLocalUnixMakefileGenerator3
::
GetTargetDirectory
(
cmTarget
&
target
)
{
std
::
string
dir
=
target
.
GetName
();
dir
+=
".dir"
;
...
...
@@ -1931,7 +1931,7 @@ cmLocalUnixMakefileGenerator3::GetTargetDirectory(const cmTarget& target)
//----------------------------------------------------------------------------
std
::
string
cmLocalUnixMakefileGenerator3
::
GetRelativeTargetDirectory
(
const
cmTarget
&
target
)
cmLocalUnixMakefileGenerator3
::
GetRelativeTargetDirectory
(
cmTarget
&
target
)
{
std
::
string
dir
=
m_Makefile
->
GetStartOutputDirectory
();
dir
+=
"/"
;
...
...
@@ -1978,7 +1978,7 @@ cmLocalUnixMakefileGenerator3
//----------------------------------------------------------------------------
std
::
string
cmLocalUnixMakefileGenerator3
::
GetObjectFileName
(
const
cmTarget
&
target
,
::
GetObjectFileName
(
cmTarget
&
target
,
const
cmSourceFile
&
source
)
{
// If the full path to the source file includes this directory,
...
...
@@ -2087,7 +2087,7 @@ cmLocalUnixMakefileGenerator3::ConvertToQuotedOutputPath(const char* p)
void
cmLocalUnixMakefileGenerator3
::
AppendTargetDepends
(
std
::
vector
<
std
::
string
>&
depends
,
const
cmTarget
&
target
)
cmTarget
&
target
)
{
// Do not bother with dependencies for static libraries.
if
(
target
.
GetType
()
==
cmTarget
::
STATIC_LIBRARY
)
...
...
@@ -2799,13 +2799,13 @@ void cmLocalUnixMakefileGenerator3::WriteLocalMakefile()
// now write out the object rules
// for each object file name
for
(
std
::
map
<
cmStdString
,
std
::
vector
<
const
cmTarget
*>
>::
iterator
lo
=
for
(
std
::
map
<
cmStdString
,
std
::
vector
<
cmTarget
*>
>::
iterator
lo
=
m_LocalObjectFiles
.
begin
();
lo
!=
m_LocalObjectFiles
.
end
();
++
lo
)
{
commands
.
clear
();
// for each target using the object file
for
(
std
::
vector
<
const
cmTarget
*>::
iterator
to
=
for
(
std
::
vector
<
cmTarget
*>::
iterator
to
=
lo
->
second
.
begin
();
to
!=
lo
->
second
.
end
();
++
to
)
{
std
::
string
tgtMakefileName
=
this
->
GetRelativeTargetDirectory
(
**
to
);
...
...
@@ -2829,9 +2829,9 @@ void cmLocalUnixMakefileGenerator3
// for each target we just provide a rule to cd up to the top and do a make
// on the target
const
cmTargets
&
targets
=
m_Makefile
->
GetTargets
();
cmTargets
&
targets
=
m_Makefile
->
GetTargets
();
std
::
string
localName
;
for
(
cmTargets
::
const_
iterator
t
=
targets
.
begin
();
t
!=
targets
.
end
();
++
t
)
for
(
cmTargets
::
iterator
t
=
targets
.
begin
();
t
!=
targets
.
end
();
++
t
)
{
if
((
t
->
second
.
GetType
()
==
cmTarget
::
EXECUTABLE
)
||
(
t
->
second
.
GetType
()
==
cmTarget
::
STATIC_LIBRARY
)
||
...
...
Source/cmLocalUnixMakefileGenerator3.h
View file @
369308ca
...
...
@@ -135,7 +135,7 @@ public:
void
WriteSpecialTargetsTop
(
std
::
ostream
&
makefileStream
);
void
WriteSpecialTargetsBottom
(
std
::
ostream
&
makefileStream
);
std
::
string
GetRelativeTargetDirectory
(
const
cmTarget
&
target
);
std
::
string
GetRelativeTargetDirectory
(
cmTarget
&
target
);
// List the files for which to check dependency integrity. Each
// language has its own list because integrity may be checked
...
...
@@ -145,10 +145,10 @@ public:
{
return
m_CheckDependFiles
;}
void
AppendTargetDepends
(
std
::
vector
<
std
::
string
>&
depends
,
const
cmTarget
&
target
);
cmTarget
&
target
);
void
AppendGlobalTargetDepends
(
std
::
vector
<
std
::
string
>&
depends
,
const
cmTarget
&
target
);
cmTarget
&
target
);
void
AppendEcho
(
std
::
vector
<
std
::
string
>&
commands
,
const
char
*
text
);
...
...
@@ -174,7 +174,7 @@ protected:
// this is responsible for writing all of the rules for all this
// directories custom commands (but not utility targets)
void
WriteCustomCommands
(
const
cmTarget
&
target
,
std
::
ostream
&
os
,
void
WriteCustomCommands
(
cmTarget
&
target
,
std
::
ostream
&
os
,
std
::
vector
<
std
::
string
>&
cleanFiles
);
// this method Writes the Directory informaiton files
...
...
@@ -187,18 +187,18 @@ protected:
void
WriteCMakeArgument
(
std
::
ostream
&
os
,
const
char
*
s
);
// write out all the rules for this target
void
WriteTargetRuleFiles
(
const
cmTarget
&
target
);
void
WriteUtilityRuleFiles
(
const
cmTarget
&
target
);
void
WriteTargetRuleFiles
(
cmTarget
&
target
);
void
WriteUtilityRuleFiles
(
cmTarget
&
target
);
// create the rule files for an object
void
WriteObjectRuleFiles
(
const
cmTarget
&
target
,
void
WriteObjectRuleFiles
(
cmTarget
&
target
,
const
cmSourceFile
&
source
,
std
::
vector
<
std
::
string
>&
objects
);
// write the build rule for an object
void
WriteObjectBuildFile
(
std
::
string
&
obj
,
const
char
*
lang
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
cmSourceFile
&
source
,
std
::
vector
<
std
::
string
>&
depends
,
std
::
string
&
depMakeFile
);
...
...
@@ -230,21 +230,21 @@ protected:
// these three make some simple changes and then call WriteLibraryRule
void
WriteStaticLibraryRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
vector
<
std
::
string
>&
cleanFiles
);
void
WriteSharedLibraryRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
vector
<
std
::
string
>&
cleanFiles
);
void
WriteModuleLibraryRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
vector
<
std
::
string
>&
cleanFiles
);
...
...
@@ -252,7 +252,7 @@ protected:
// the main code for writing the Executable target rules
void
WriteExecutableRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
vector
<
std
::
string
>&
cleanFiles
);
...
...
@@ -260,7 +260,7 @@ protected:
// the main method for writing library rules
void
WriteLibraryRule
(
std
::
ostream
&
ruleFileStream
,
const
char
*
ruleFileName
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
const
char
*
linkRuleVar
,
...
...
@@ -278,24 +278,24 @@ protected:
const
char
*
realTarget
,
const
char
*
helpTarget
);
void
WriteObjectsVariable
(
std
::
ostream
&
ruleFileStream
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
,
const
std
::
vector
<
std
::
string
>&
external_objects
,
std
::
string
&
variableName
,
std
::
string
&
variableNameExternal
);
void
WriteTargetDependRule
(
std
::
ostream
&
ruleFileStream
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
);
void
WriteTargetCleanRule
(
std
::
ostream
&
ruleFileStream
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
files
);
void
WriteTargetRequiresRule
(
std
::
ostream
&
ruleFileStream
,
const
cmTarget
&
target
,
cmTarget
&
target
,
const
std
::
vector
<
std
::
string
>&
objects
);