ENH: keep cleaning up Tcl/Tk modules
[cmake.git] / Source / cmGlobalVisualStudioGenerator.h
blob1db56795187e200f5c6e1dd0447a690cd7158395
1 /*=========================================================================
3 Program: CMake - Cross-Platform Makefile Generator
4 Module: $RCSfile: cmGlobalVisualStudioGenerator.h,v $
5 Language: C++
6 Date: $Date: 2007-12-21 20:04:06 $
7 Version: $Revision: 1.6 $
9 Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
10 See Copyright.txt or http://www.cmake.org/HTML/Copyright.html for details.
12 This software is distributed WITHOUT ANY WARRANTY; without even
13 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 PURPOSE. See the above copyright notices for more information.
16 =========================================================================*/
17 #ifndef cmGlobalVisualStudioGenerator_h
18 #define cmGlobalVisualStudioGenerator_h
20 #include "cmGlobalGenerator.h"
22 /** \class cmGlobalVisualStudioGenerator
23 * \brief Base class for global Visual Studio generators.
25 * cmGlobalVisualStudioGenerator provides functionality common to all
26 * global Visual Studio generators.
28 class cmGlobalVisualStudioGenerator : public cmGlobalGenerator
30 public:
31 cmGlobalVisualStudioGenerator();
32 virtual ~cmGlobalVisualStudioGenerator();
34 /**
35 * Basic generate implementation for all VS generators.
37 virtual void Generate();
39 /**
40 * Configure CMake's Visual Studio macros file into the user's Visual
41 * Studio macros directory.
43 virtual void ConfigureCMakeVisualStudioMacros();
45 /**
46 * Where does this version of Visual Studio look for macros for the
47 * current user? Returns the empty string if this version of Visual
48 * Studio does not implement support for VB macros.
50 virtual std::string GetUserMacrosDirectory();
52 enum MacroName {MacroReload, MacroStop};
54 /**
55 * Call the ReloadProjects macro if necessary based on
56 * GetFilesReplacedDuringGenerate results.
58 virtual void CallVisualStudioMacro(MacroName m,
59 const char* vsSolutionFile = 0);
61 protected:
62 virtual void CreateGUID(const char*) {}
63 void FixUtilityDepends();
64 const char* GetUtilityForTarget(cmTarget& target, const char*);
66 // Does this VS version link targets to each other if there are
67 // dependencies in the SLN file? This was done for VS versions
68 // below 8.
69 virtual bool VSLinksDependencies() const { return true; }
71 private:
72 void FixUtilityDependsForTarget(cmTarget& target);
73 void CreateUtilityDependTarget(cmTarget& target);
74 bool CheckTargetLinks(cmTarget& target, const char* name);
77 #endif