summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2007-05-17 14:41:52 -0400
committerBill Hoffman <bill.hoffman@kitware.com>2007-05-17 14:41:52 -0400
commit32233300a1501fad1f24cd1f6f8640c037ffead9 (patch)
tree6589b2fe3c427472dd8c79121fcde899de04c343
parentcc76f9be5814c050a9f797037c77b2765a43fc68 (diff)
downloadcmake-32233300a1501fad1f24cd1f6f8640c037ffead9.tar.gz
ENH: merge in changes from main tree
-rw-r--r--CMakeLists.txt2
-rw-r--r--ChangeLog.manual9
-rw-r--r--Source/CPack/cmCPackTarCompressGenerator.cxx7
-rw-r--r--Source/cmCTest.cxx6
-rw-r--r--Source/cmIfCommand.h10
-rw-r--r--Source/cmListFileCache.h4
-rw-r--r--Source/cmLocalGenerator.cxx2
-rw-r--r--Source/cmLocalVisualStudio7Generator.cxx17
-rw-r--r--Source/cmMakefile.cxx27
9 files changed, 57 insertions, 27 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 89737fcd6f..7f3ddbab3a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -7,7 +7,7 @@ SET(CMake_VERSION_MAJOR 2)
SET(CMake_VERSION_MINOR 4)
SET(CMake_VERSION_PATCH 7)
# for an actual release this should not be defined
-SET(CMake_VERSION_RC 5)
+SET(CMake_VERSION_RC 6)
SET(CMake_VERSION "${CMake_VERSION_MAJOR}.${CMake_VERSION_MINOR}")
SET(CMake_VERSION_FULL "${CMake_VERSION}.${CMake_VERSION_PATCH}")
diff --git a/ChangeLog.manual b/ChangeLog.manual
index afcc40cc99..b8efcf624e 100644
--- a/ChangeLog.manual
+++ b/ChangeLog.manual
@@ -1,5 +1,14 @@
Changes in CMake 2.4.7
+--- RC 6 ---
+* Fix stack reporting bug in macros and include
+* Fix double quote in -D flags for vs broken in RC 5
+
+* Fix problem with newer curl and curl_getdate changes
+
+* Do not emit link paths /usr/lib32 and /usr/lib64 with -L
+
+---RC 5 ----
* Fix for bug# 4423, LANGUAGE property now works in VS IDE
* Fix for RUN_TESTS running the tests twice in VS IDE
diff --git a/Source/CPack/cmCPackTarCompressGenerator.cxx b/Source/CPack/cmCPackTarCompressGenerator.cxx
index cd8e9da23c..ed2e8fa2e9 100644
--- a/Source/CPack/cmCPackTarCompressGenerator.cxx
+++ b/Source/CPack/cmCPackTarCompressGenerator.cxx
@@ -225,15 +225,18 @@ int cmCPackTarCompressGenerator::CompressFiles(const char* outFileName,
int cmCPackTarCompress_Compress_Output(void* client_data,
const char* data, int data_length)
{
+ if(!client_data)
+ {
+ return 0;
+ }
cmcompress_stream *cstream = static_cast<cmcompress_stream*>(client_data);
cmCPackTarCompress_Data *mydata
= static_cast<cmCPackTarCompress_Data*>(cstream->client_data);
- mydata->OutputStream->write(data, data_length);
-
if ( !mydata->OutputStream )
{
return 0;
}
+ mydata->OutputStream->write(data, data_length);
return data_length;
}
diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx
index 353af39363..4bdac1df11 100644
--- a/Source/cmCTest.cxx
+++ b/Source/cmCTest.cxx
@@ -57,6 +57,12 @@ struct tm* cmCTest::GetNightlyTime(std::string str,
{
struct tm* lctime;
time_t tctime = time(0);
+ lctime = gmtime(&tctime);
+ char buf[1024];
+ // add todays year day and month to the time in str because
+ // curl_getdate no longer assumes the day is today
+ sprintf(buf, "%d%02d%02d %s", lctime->tm_year+1900, lctime->tm_mday,
+ lctime->tm_mon, str.c_str());
cmCTestLog(this, OUTPUT, "Determine Nightly Start Time" << std::endl
<< " Specified time: " << str.c_str() << std::endl);
//Convert the nightly start time to seconds. Since we are
diff --git a/Source/cmIfCommand.h b/Source/cmIfCommand.h
index fcdbc09de0..1a892276d3 100644
--- a/Source/cmIfCommand.h
+++ b/Source/cmIfCommand.h
@@ -99,6 +99,11 @@ public:
" COMMAND1(ARGS ...)\n"
" COMMAND2(ARGS ...)\n"
" ...\n"
+ " ELSEIF(expression2)\n"
+ " # ELSEIF section.\n"
+ " COMMAND1(ARGS ...)\n"
+ " COMMAND2(ARGS ...)\n"
+ " ...\n"
" ELSE(expression)\n"
" # ELSE section.\n"
" COMMAND1(ARGS ...)\n"
@@ -107,8 +112,9 @@ public:
" ENDIF(expression)\n"
"Evaluates the given expression. If the result is true, the commands "
"in the THEN section are invoked. Otherwise, the commands in the "
- "ELSE section are invoked. The ELSE section is optional. Note that "
- "the same expression must be given to IF, ELSE, and ENDIF. Long "
+ "ELSE section are invoked. The ELSEIF and ELSE sections are "
+ "optional. You may have multiple ELSEIF clauses. Note that "
+ "the same expression must be given to IF, and ENDIF. Long "
"expressions can be used and the order or precedence is that the "
"EXISTS, COMMAND, and DEFINED operators will be evaluated first. "
"Then any EQUAL, LESS, GREATER, STRLESS, STRGREATER, STREQUAL, MATCHES "
diff --git a/Source/cmListFileCache.h b/Source/cmListFileCache.h
index 048e04f027..d0e4100198 100644
--- a/Source/cmListFileCache.h
+++ b/Source/cmListFileCache.h
@@ -28,7 +28,7 @@
struct cmListFileArgument
{
- cmListFileArgument(): Value(), Quoted(false), FilePath(0), Line(0) {}
+ cmListFileArgument(): Value(), Quoted(false), FilePath(), Line(0) {}
cmListFileArgument(const cmListFileArgument& r):
Value(r.Value), Quoted(r.Quoted), FilePath(r.FilePath), Line(r.Line) {}
cmListFileArgument(const std::string& v, bool q, const char* file,
@@ -44,7 +44,7 @@ struct cmListFileArgument
}
std::string Value;
bool Quoted;
- const char* FilePath;
+ std::string FilePath;
long Line;
};
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 6e1a3c0120..84c466a7ba 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -1467,6 +1467,8 @@ void cmLocalGenerator::OutputLinkLibraries(std::ostream& fout,
// Some search paths should never be emitted
emitted.insert("");
emitted.insert("/usr/lib");
+ emitted.insert("/usr/lib32");
+ emitted.insert("/usr/lib64");
std::string libPathFlag =
this->Makefile->GetRequiredDefinition("CMAKE_LIBRARY_PATH_FLAG");
std::string libLinkFlag =
diff --git a/Source/cmLocalVisualStudio7Generator.cxx b/Source/cmLocalVisualStudio7Generator.cxx
index c937efa111..06d12b0517 100644
--- a/Source/cmLocalVisualStudio7Generator.cxx
+++ b/Source/cmLocalVisualStudio7Generator.cxx
@@ -544,9 +544,9 @@ void cmLocalVisualStudio7Generator::WriteConfiguration(std::ostream& fout,
this->Makefile->IsOn("CMAKE_VERBOSE_MAKEFILE"));
// Add a definition for the configuration name.
- std::string configDefine = "CMAKE_INTDIR=\\\"";
+ std::string configDefine = "CMAKE_INTDIR=\"";
configDefine += configName;
- configDefine += "\\\"";
+ configDefine += "\"";
targetOptions.AddDefine(configDefine);
// Add a definition for the export macro.
@@ -1872,14 +1872,13 @@ cmLocalVisualStudio7GeneratorOptions
for(std::vector<cmStdString>::const_iterator di = this->Defines.begin();
di != this->Defines.end(); ++di)
{
- // Escape this flag for the IDE.
- std::string define =
- cmLocalVisualStudio7GeneratorEscapeForXML(di->c_str());
-
- // Old comment:
// Double-quotes in the value of the definition must be escaped
- // with a backslash. The entire definition should be quoted in
- // the generated xml attribute to avoid confusing the VS parser.
+ // with a backslash.
+ std::string define = di->c_str();
+ cmSystemTools::ReplaceString(define, "\"", "\\\"");
+
+ // Escape this flag for the IDE.
+ define = cmLocalVisualStudio7GeneratorEscapeForXML(define.c_str());
// Write this flag. Quote it if the definition is not
// alphanumeric.
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index 2494c9d914..24f00c0964 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -461,7 +461,9 @@ bool cmMakefile::ReadListFile(const char* filename_in,
cmListFile cacheFile;
if( !cacheFile.ParseFile(filenametoread, requireProjectCommand) )
{
- this->AddDefinition("CMAKE_PARENT_LIST_FILE", currentFile.c_str());
+ // pop the listfile off the stack
+ this->ListFileStack.pop_back();
+ this->AddDefinition("CMAKE_CURRENT_LIST_FILE", currentFile.c_str());
return false;
}
// add this list file to the list of dependencies
@@ -1900,7 +1902,7 @@ void cmMakefile::ExpandArguments(
// Expand the variables in the argument.
value = i->Value;
this->ExpandVariablesInString(value, false, false, false,
- i->FilePath, i->Line,
+ i->FilePath.c_str(), i->Line,
false, true);
// If the argument is quoted, it should be one argument.
@@ -2706,15 +2708,18 @@ std::vector<cmTest*> *cmMakefile::GetTests()
std::string cmMakefile::GetListFileStack()
{
- std::string tmp;
- for (std::deque<cmStdString>::iterator i = this->ListFileStack.begin();
- i != this->ListFileStack.end(); ++i)
+ cmOStringStream tmp;
+ size_t depth = this->ListFileStack.size();
+ std::deque<cmStdString>::iterator it = this->ListFileStack.end();
+ do
{
- if (i != this->ListFileStack.begin())
- {
- tmp += ";";
- }
- tmp += *i;
+ --it;
+ tmp << "\n[";
+ tmp << depth;
+ tmp << "]\t";
+ tmp << *it;
+ depth--;
}
- return tmp;
+ while (it != this->ListFileStack.begin());
+ return tmp.str();
}