Commit 16fc8d78 authored by Ken Martin's avatar Ken Martin
Browse files

added SetLocal method

parent 06429282
......@@ -69,3 +69,7 @@ cmMSProjectGenerator::~cmMSProjectGenerator()
delete m_DSWMakefile;
}
void cmMSProjectGenerator::SetLocal(bool local)
{
m_BuildDSW = !local;
}
......@@ -70,20 +70,21 @@ public:
*/
virtual void GenerateMakefile();
//! controls the DSW/DSP settings
virtual void SetLocal(bool);
/**
* Turn off the generation of a Microsoft Visual C++ DSW file.
* This causes only the dsp file to be created. This
* is used to run as a command line program from inside visual
* studio.
*/
void BuildDSWOff()
{m_BuildDSW = false;}
void BuildDSWOff() {m_BuildDSW = false;}
/**
* Turn on the generation of a Microsoft Visual C++ DSW file.
*/
void BuildDSWOn()
{m_BuildDSW = true;}
void BuildDSWOn() {m_BuildDSW = true;}
/**
* Retrieve a pointer to a cmDSWMakefile instance.
......
......@@ -67,6 +67,15 @@ public:
*/
virtual void GenerateMakefile() = 0;
/**
* The local setting indicates that the generator is producing a
* fully configured makefile in the current directory. In Microsoft
* terms it is producing a DSP file if local is true and a DSW file
* if local is false. On UNIX when local is false it skips the
* dependecy check and recurses the full tree building the structure
*/
virtual void SetLocal(bool ) {};
protected:
cmMakefile* m_Makefile;
};
......
......@@ -875,3 +875,17 @@ void cmUnixMakefileGenerator::OutputMakeRule(std::ostream& fout,
}
void cmUnixMakefileGenerator::SetLocal (bool local)
{
if (local)
{
m_CacheOnly = false;
m_Recurse = false;
}
else
{
m_CacheOnly = true;
m_Recurse = true;
}
}
......@@ -55,7 +55,10 @@ class cmUnixMakefileGenerator : public cmMakefileGenerator
public:
///! Set cache only and recurse to false by default.
cmUnixMakefileGenerator();
//! just sets the Cache Only and Recurse flags
virtual void SetLocal(bool local);
/**
* If cache only is on.
* and only stub makefiles are generated, and no depends, for speed.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment