ERR: Fixed compiler warnings.
This commit is contained in:
parent
55f3a3817e
commit
28895b0f9f
@ -54,8 +54,7 @@ public:
|
|||||||
* This is called when the command is first encountered in
|
* This is called when the command is first encountered in
|
||||||
* the CMakeLists.txt file.
|
* the CMakeLists.txt file.
|
||||||
*/
|
*/
|
||||||
virtual bool InitialPass(std::vector<std::string> const& args) {
|
virtual bool InitialPass(std::vector<std::string> const&) {return true;}
|
||||||
return true;};
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This is called at the end after all the information
|
* This is called at the end after all the information
|
||||||
|
@ -32,22 +32,22 @@ public:
|
|||||||
* should a function be blocked
|
* should a function be blocked
|
||||||
*/
|
*/
|
||||||
virtual bool IsFunctionBlocked(const char *name, const std::vector<std::string> &args,
|
virtual bool IsFunctionBlocked(const char *name, const std::vector<std::string> &args,
|
||||||
cmMakefile &mf) = 0;
|
cmMakefile&mf) = 0;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* should this function blocker be removed, useful when one function adds a
|
* should this function blocker be removed, useful when one function adds a
|
||||||
* blocker and another must remove it
|
* blocker and another must remove it
|
||||||
*/
|
*/
|
||||||
virtual bool ShouldRemove(const char *name,
|
virtual bool ShouldRemove(const char *,
|
||||||
const std::vector<std::string> &args,
|
const std::vector<std::string>&,
|
||||||
cmMakefile &mf) {return false;}
|
cmMakefile&) {return false;}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When the end of a CMakeList file is reached this method is called. It
|
* When the end of a CMakeList file is reached this method is called. It
|
||||||
* is not called on the end of an INCLUDE cmake file, just at the end of a
|
* is not called on the end of an INCLUDE cmake file, just at the end of a
|
||||||
* regular CMakeList file
|
* regular CMakeList file
|
||||||
*/
|
*/
|
||||||
virtual void ScopeEnded(cmMakefile &mf) {}
|
virtual void ScopeEnded(cmMakefile&) {}
|
||||||
|
|
||||||
virtual ~cmFunctionBlocker() {}
|
virtual ~cmFunctionBlocker() {}
|
||||||
|
|
||||||
|
@ -662,10 +662,10 @@ void cmMakefile::AddGlobalLinkInformation(const char* name, cmTarget& target)
|
|||||||
// for these targets do not add anything
|
// for these targets do not add anything
|
||||||
switch(target.GetType())
|
switch(target.GetType())
|
||||||
{
|
{
|
||||||
case cmTarget::UTILITY:
|
case cmTarget::UTILITY: return;
|
||||||
case cmTarget::INSTALL_FILES:
|
case cmTarget::INSTALL_FILES: return;
|
||||||
case cmTarget::INSTALL_PROGRAMS:
|
case cmTarget::INSTALL_PROGRAMS: return;
|
||||||
return;
|
default:;
|
||||||
}
|
}
|
||||||
std::vector<std::string>::iterator j;
|
std::vector<std::string>::iterator j;
|
||||||
for(j = m_LinkDirectories.begin();
|
for(j = m_LinkDirectories.begin();
|
||||||
|
@ -203,9 +203,9 @@ void cmSystemTools::ReplaceString(std::string& source,
|
|||||||
// HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\8.4;Root
|
// HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\8.4;Root
|
||||||
// => will return the data of the "Root" value of the key
|
// => will return the data of the "Root" value of the key
|
||||||
|
|
||||||
|
#if defined(_WIN32) && !defined(__CYGWIN__)
|
||||||
bool cmSystemTools::ReadRegistryValue(const char *key, std::string &value)
|
bool cmSystemTools::ReadRegistryValue(const char *key, std::string &value)
|
||||||
{
|
{
|
||||||
#if defined(_WIN32) && !defined(__CYGWIN__)
|
|
||||||
|
|
||||||
std::string primary = key;
|
std::string primary = key;
|
||||||
std::string second;
|
std::string second;
|
||||||
@ -276,9 +276,14 @@ bool cmSystemTools::ReadRegistryValue(const char *key, std::string &value)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool cmSystemTools::ReadRegistryValue(const char *, std::string &)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Write a registry value.
|
// Write a registry value.
|
||||||
@ -288,10 +293,9 @@ bool cmSystemTools::ReadRegistryValue(const char *key, std::string &value)
|
|||||||
// HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\8.4;Root
|
// HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\8.4;Root
|
||||||
// => will set the data of the "Root" value of the key
|
// => will set the data of the "Root" value of the key
|
||||||
|
|
||||||
|
#if defined(_WIN32) && !defined(__CYGWIN__)
|
||||||
bool cmSystemTools::WriteRegistryValue(const char *key, const char *value)
|
bool cmSystemTools::WriteRegistryValue(const char *key, const char *value)
|
||||||
{
|
{
|
||||||
#if defined(_WIN32) && !defined(__CYGWIN__)
|
|
||||||
|
|
||||||
std::string primary = key;
|
std::string primary = key;
|
||||||
std::string second;
|
std::string second;
|
||||||
std::string valuename;
|
std::string valuename;
|
||||||
@ -357,10 +361,14 @@ bool cmSystemTools::WriteRegistryValue(const char *key, const char *value)
|
|||||||
{
|
{
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool cmSystemTools::WriteRegistryValue(const char *, const char *)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
// Delete a registry value.
|
// Delete a registry value.
|
||||||
// Example :
|
// Example :
|
||||||
@ -369,10 +377,9 @@ bool cmSystemTools::WriteRegistryValue(const char *key, const char *value)
|
|||||||
// HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\8.4;Root
|
// HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\8.4;Root
|
||||||
// => will delete the data of the "Root" value of the key
|
// => will delete the data of the "Root" value of the key
|
||||||
|
|
||||||
|
#if defined(_WIN32) && !defined(__CYGWIN__)
|
||||||
bool cmSystemTools::DeleteRegistryValue(const char *key)
|
bool cmSystemTools::DeleteRegistryValue(const char *key)
|
||||||
{
|
{
|
||||||
#if defined(_WIN32) && !defined(__CYGWIN__)
|
|
||||||
|
|
||||||
std::string primary = key;
|
std::string primary = key;
|
||||||
std::string second;
|
std::string second;
|
||||||
std::string valuename;
|
std::string valuename;
|
||||||
@ -431,16 +438,20 @@ bool cmSystemTools::DeleteRegistryValue(const char *key)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool cmSystemTools::DeleteRegistryValue(const char *)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
// replace replace with with as many times as it shows up in source.
|
// replace replace with with as many times as it shows up in source.
|
||||||
// write the result into source.
|
// write the result into source.
|
||||||
|
#if defined(_WIN32) && !defined(__CYGWIN__)
|
||||||
void cmSystemTools::ExpandRegistryValues(std::string& source)
|
void cmSystemTools::ExpandRegistryValues(std::string& source)
|
||||||
{
|
{
|
||||||
#if defined(_WIN32) && !defined(__CYGWIN__)
|
|
||||||
// Regular expression to match anything inside [...] that begins in HKEY.
|
// Regular expression to match anything inside [...] that begins in HKEY.
|
||||||
// Note that there is a special rule for regular expressions to match a
|
// Note that there is a special rule for regular expressions to match a
|
||||||
// close square-bracket inside a list delimited by square brackets.
|
// close square-bracket inside a list delimited by square brackets.
|
||||||
@ -468,8 +479,12 @@ void cmSystemTools::ExpandRegistryValues(std::string& source)
|
|||||||
cmSystemTools::ReplaceString(source, reg.c_str(), "/registry");
|
cmSystemTools::ReplaceString(source, reg.c_str(), "/registry");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void cmSystemTools::ExpandRegistryValues(std::string&)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
std::string cmSystemTools::EscapeQuotes(const char* str)
|
std::string cmSystemTools::EscapeQuotes(const char* str)
|
||||||
@ -1050,8 +1065,8 @@ bool cmSystemTools::FilesDiffer(const char* source,
|
|||||||
finSource.read(source_buf, statSource.st_size);
|
finSource.read(source_buf, statSource.st_size);
|
||||||
finDestination.read(dest_buf, statSource.st_size);
|
finDestination.read(dest_buf, statSource.st_size);
|
||||||
|
|
||||||
if(statSource.st_size != finSource.gcount() ||
|
if(statSource.st_size != static_cast<long>(finSource.gcount()) ||
|
||||||
statSource.st_size != finDestination.gcount())
|
statSource.st_size != static_cast<long>(finDestination.gcount()))
|
||||||
{
|
{
|
||||||
std::strstream msg;
|
std::strstream msg;
|
||||||
msg << "FilesDiffer failed to read files (allocated: "
|
msg << "FilesDiffer failed to read files (allocated: "
|
||||||
|
@ -128,6 +128,7 @@ void cmTarget::AddLinkLibrary(cmMakefile& mf,
|
|||||||
"optimized", "Library is used for debug links only",
|
"optimized", "Library is used for debug links only",
|
||||||
cmCacheManager::STATIC);
|
cmCacheManager::STATIC);
|
||||||
break;
|
break;
|
||||||
|
case cmTarget::GENERAL: break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Add the explicit dependency information for this target. This is
|
// Add the explicit dependency information for this target. This is
|
||||||
|
Loading…
x
Reference in New Issue
Block a user