2001-05-18 19:25:08 +00:00
|
|
|
/*=========================================================================
|
|
|
|
|
|
|
|
Program: Insight Segmentation & Registration Toolkit
|
|
|
|
Module: $RCSfile$
|
|
|
|
Language: C++
|
|
|
|
Date: $Date$
|
|
|
|
Version: $Revision$
|
|
|
|
|
2002-01-21 20:30:43 +00:00
|
|
|
Copyright (c) 2002 Insight Consortium. All rights reserved.
|
|
|
|
See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm 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.
|
2001-05-18 19:25:08 +00:00
|
|
|
|
|
|
|
=========================================================================*/
|
|
|
|
|
|
|
|
|
|
|
|
#include "cmMakefile.h"
|
|
|
|
#include "cmStandardIncludes.h"
|
|
|
|
|
|
|
|
class cmake
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Generate the SourceFilesList from the SourceLists. This should only be
|
|
|
|
* done once to be safe.
|
|
|
|
*/
|
|
|
|
void Usage(const char *program);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Generate the SourceFilesList from the SourceLists. This should only be
|
2001-05-30 19:28:55 +00:00
|
|
|
* done once to be safe. The argument is a list of command line
|
|
|
|
* arguments. The first argument should be the name or full path
|
|
|
|
* to the command line version of cmake. For building a GUI,
|
|
|
|
* you would pass in the following arguments:
|
|
|
|
* /path/to/cmake -H/path/to/source -B/path/to/build
|
2001-07-25 22:30:27 +00:00
|
|
|
* If you only want to parse the CMakeLists.txt files,
|
|
|
|
* but not actually generate the makefiles, use buildMakefiles = false.
|
2001-05-18 19:25:08 +00:00
|
|
|
*/
|
2001-07-25 22:30:27 +00:00
|
|
|
int Generate(const std::vector<std::string>&, bool buildMakefiles = true);
|
2001-05-18 19:25:08 +00:00
|
|
|
|
2001-11-20 22:51:03 +00:00
|
|
|
///! Parse command line arguments
|
2001-05-30 19:28:55 +00:00
|
|
|
void SetArgs(cmMakefile& builder, const std::vector<std::string>&);
|
2001-11-20 22:51:03 +00:00
|
|
|
///! Parse command line arguments that might set cache values
|
|
|
|
void SetCacheArgs(cmMakefile& builder, const std::vector<std::string>&);
|
2001-05-18 19:25:08 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Generate CMAKE_ROOT and CMAKE_COMMAND cache entries
|
|
|
|
*/
|
2001-05-30 19:28:55 +00:00
|
|
|
void AddCMakePaths(const std::vector<std::string>&);
|
2001-05-18 19:25:08 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* constructor
|
|
|
|
*/
|
2001-09-06 21:28:24 +00:00
|
|
|
cmake();
|
2001-05-18 19:25:08 +00:00
|
|
|
|
2001-09-06 21:28:24 +00:00
|
|
|
private:
|
2001-05-18 19:25:08 +00:00
|
|
|
bool m_Verbose;
|
|
|
|
bool m_Local;
|
|
|
|
};
|
|
|
|
|