summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalVisualStudio7Generator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmGlobalVisualStudio7Generator.cxx')
-rw-r--r--Source/cmGlobalVisualStudio7Generator.cxx68
1 files changed, 16 insertions, 52 deletions
diff --git a/Source/cmGlobalVisualStudio7Generator.cxx b/Source/cmGlobalVisualStudio7Generator.cxx
index 302cd31..f2f3e98 100644
--- a/Source/cmGlobalVisualStudio7Generator.cxx
+++ b/Source/cmGlobalVisualStudio7Generator.cxx
@@ -1,19 +1,14 @@
-/*=========================================================================
+/*============================================================================
+ CMake - Cross Platform Makefile Generator
+ Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
- Program: CMake - Cross-Platform Makefile Generator
- Module: $RCSfile$
- Language: C++
- Date: $Date$
- Version: $Revision$
+ Distributed under the OSI-approved BSD License (the "License");
+ see accompanying file Copyright.txt for details.
- Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
- See Copyright.txt or http://www.cmake.org/HTML/Copyright.html for details.
-
- This software is distributed WITHOUT ANY WARRANTY; without even
- the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
- PURPOSE. See the above copyright notices for more information.
-
-=========================================================================*/
+ This software is distributed WITHOUT ANY WARRANTY; without even the
+ implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ See the License for more information.
+============================================================================*/
#include "windows.h" // this must be first to define GetCurrentDirectory
#include "cmGlobalVisualStudio7Generator.h"
#include "cmGeneratedFileStream.h"
@@ -357,17 +352,14 @@ void cmGlobalVisualStudio7Generator
{
// Write out the header for a SLN file
this->WriteSLNHeader(fout);
-
- // collect the set of targets for this project by
- // tracing depends of all targets.
- // also collect the set of targets that are explicitly
- // in this project.
- cmGlobalGenerator::TargetDependSet projectTargets;
- cmGlobalGenerator::TargetDependSet originalTargets;
- this->GetTargetSets(projectTargets,
- originalTargets,
- root, generators);
+
+ // Collect all targets under this root generator and the transitive
+ // closure of their dependencies.
+ TargetDependSet projectTargets;
+ TargetDependSet originalTargets;
+ this->GetTargetSets(projectTargets, originalTargets, root, generators);
OrderedTargetDependSet orderedProjectTargets(projectTargets);
+
this->WriteTargetsToSolution(fout, root, orderedProjectTargets);
// Write out the configurations information for the solution
fout << "Global\n"
@@ -664,34 +656,6 @@ bool cmGlobalVisualStudio7Generator::IsPartOfDefaultBuild(const char* project,
}
//----------------------------------------------------------------------------
-bool
-cmGlobalVisualStudio7Generator::TargetCompare
-::operator()(cmTarget const* l, cmTarget const* r)
-{
- // Make sure ALL_BUILD is first so it is the default active project.
- if(strcmp(r->GetName(), "ALL_BUILD") == 0)
- {
- return false;
- }
- if(strcmp(l->GetName(), "ALL_BUILD") == 0)
- {
- return true;
- }
- return strcmp(l->GetName(), r->GetName()) < 0;
-}
-
-//----------------------------------------------------------------------------
-cmGlobalVisualStudio7Generator::OrderedTargetDependSet
-::OrderedTargetDependSet(cmGlobalGenerator::TargetDependSet const& targets)
-{
- for(cmGlobalGenerator::TargetDependSet::const_iterator ti =
- targets.begin(); ti != targets.end(); ++ti)
- {
- this->insert(*ti);
- }
-}
-
-//----------------------------------------------------------------------------
static cmVS7FlagTable cmVS7ExtraFlagTable[] =
{
// Precompiled header and related options. Note that the