mirror of
https://github.com/Kitware/CMake.git
synced 2026-04-22 14:23:10 -05:00
Merge branch 'upstream-KWSys' into update-kwsys
* upstream-KWSys: KWSys 2017-11-07 (5249a82d)
This commit is contained in:
@@ -1150,17 +1150,17 @@ IF(KWSYS_STANDALONE OR CMake_SOURCE_DIR)
|
||||
SET(testProcess_COMPILE_FLAGS "")
|
||||
# Some Apple compilers produce bad optimizations in this source.
|
||||
IF(APPLE AND CMAKE_C_COMPILER_ID MATCHES "^(GNU|LLVM)$")
|
||||
STRING(APPEND testProcess_COMPILE_FLAGS " -O0")
|
||||
SET(testProcess_COMPILE_FLAGS "${testProcess_COMPILE_FLAGS} -O0")
|
||||
ELSEIF(CMAKE_C_COMPILER_ID STREQUAL "XL" AND
|
||||
NOT (CMAKE_SYSTEM MATCHES "Linux.*ppc64le" AND
|
||||
NOT CMAKE_C_COMPILER_VERSION VERSION_LESS "13.1.1"))
|
||||
# Tell IBM XL not to warn about our test infinite loop
|
||||
# v13.1.1 and newer on Linux ppc64le is clang based and does not accept
|
||||
# the -qsuppress option
|
||||
STRING(APPEND testProcess_COMPILE_FLAGS " -qsuppress=1500-010")
|
||||
SET(testProcess_COMPILE_FLAGS "${testProcess_COMPILE_FLAGS} -qsuppress=1500-010")
|
||||
ENDIF()
|
||||
IF(CMAKE_C_FLAGS MATCHES "-fsanitize=")
|
||||
STRING(APPEND testProcess_COMPILE_FLAGS " -DCRASH_USING_ABORT")
|
||||
SET(testProcess_COMPILE_FLAGS "${testProcess_COMPILE_FLAGS} -DCRASH_USING_ABORT")
|
||||
ENDIF()
|
||||
SET_PROPERTY(SOURCE testProcess.c PROPERTY COMPILE_FLAGS "${testProcess_COMPILE_FLAGS}")
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@ namespace @KWSYS_NAMESPACE@ {
|
||||
* or absolute) pathname. Otherwise, the dynamic linker searches for the
|
||||
* library as follows : see ld.so(8) for further details):
|
||||
* Whereas this distinction does not exist on Win32. Therefore ideally you
|
||||
* should be doing full path to garantee to have a consistent way of dealing
|
||||
* should be doing full path to guarantee to have a consistent way of dealing
|
||||
* with dynamic loading of shared library.
|
||||
*
|
||||
* \warning the Cygwin implementation do not use the Win32 HMODULE. Put extra
|
||||
@@ -72,7 +72,7 @@ public:
|
||||
static LibraryHandle OpenLibrary(const std::string&);
|
||||
|
||||
/** Attempt to detach a dynamic library from the
|
||||
* process. A value of true is returned if it is sucessful. */
|
||||
* process. A value of true is returned if it is successful. */
|
||||
static int CloseLibrary(LibraryHandle);
|
||||
|
||||
/** Find the address of the symbol in the given library. */
|
||||
|
||||
@@ -421,7 +421,7 @@ enum kwsysProcess_Pipes_e
|
||||
|
||||
/**
|
||||
* Block until the child process terminates or the given timeout
|
||||
* expires. If no process is running, returns immediatly. The
|
||||
* expires. If no process is running, returns immediately. The
|
||||
* argument is:
|
||||
*
|
||||
* timeout = Specifies the maximum time this call may block. Upon
|
||||
|
||||
@@ -109,12 +109,12 @@ namespace @KWSYS_NAMESPACE@ {
|
||||
* object as an argument and creates an object initialized with the
|
||||
* information from the given RegularExpression object.
|
||||
*
|
||||
* The find member function finds the first occurence of the regualr
|
||||
* The find member function finds the first occurrence of the regular
|
||||
* expression of that object in the string given to find as an argument. Find
|
||||
* returns a boolean, and if true, mutates the private data appropriately.
|
||||
* Find sets pointers to the beginning and end of the thing last found, they
|
||||
* are pointers into the actual string that was searched. The start and end
|
||||
* member functions return indicies into the searched string that correspond
|
||||
* member functions return indices into the searched string that correspond
|
||||
* to the beginning and end pointers respectively. The compile member
|
||||
* function takes a char* and puts the compiled version of the char* argument
|
||||
* into the object's private data fields. The == and != operators only check
|
||||
|
||||
@@ -3633,7 +3633,7 @@ SystemInformationImplementation::GetHostMemoryAvailable(
|
||||
// apply resource limits across groups of processes.
|
||||
// this is of use on certain SMP systems (eg. SGI UV)
|
||||
// where the host has a large amount of ram but a given user's
|
||||
// access to it is severly restricted. The system will
|
||||
// access to it is severely restricted. The system will
|
||||
// apply a limit across a set of processes. Units are in KiB.
|
||||
if (hostLimitEnvVarName) {
|
||||
const char* hostLimitEnvVarValue = getenv(hostLimitEnvVarName);
|
||||
|
||||
@@ -124,7 +124,7 @@ public:
|
||||
// are the processes comprising an mpi program which is running in
|
||||
// parallel. The amount of memory reported may differ from the host
|
||||
// total if a host wide resource limit is applied. Such reource limits
|
||||
// are reported to us via an applicaiton specified environment variable.
|
||||
// are reported to us via an application specified environment variable.
|
||||
LongLong GetHostMemoryAvailable(const char* hostLimitEnvVarName = NULL);
|
||||
|
||||
// Get total system RAM in units of KiB available to this process.
|
||||
|
||||
@@ -1691,7 +1691,7 @@ bool SystemTools::StringEndsWith(const std::string& str1, const char* str2)
|
||||
: false;
|
||||
}
|
||||
|
||||
// Returns a pointer to the last occurence of str2 in str1
|
||||
// Returns a pointer to the last occurrence of str2 in str1
|
||||
const char* SystemTools::FindLastString(const char* str1, const char* str2)
|
||||
{
|
||||
if (!str1 || !str2) {
|
||||
|
||||
@@ -107,7 +107,7 @@ public:
|
||||
}
|
||||
|
||||
/**
|
||||
* Replace replace all occurences of the string in the source string.
|
||||
* Replace replace all occurrences of the string in the source string.
|
||||
*/
|
||||
static void ReplaceString(std::string& source, const char* replace,
|
||||
const char* with);
|
||||
@@ -175,7 +175,7 @@ public:
|
||||
static bool StringEndsWith(const std::string& str1, const char* str2);
|
||||
|
||||
/**
|
||||
* Returns a pointer to the last occurence of str2 in str1
|
||||
* Returns a pointer to the last occurrence of str2 in str1
|
||||
*/
|
||||
static const char* FindLastString(const char* str1, const char* str2);
|
||||
|
||||
@@ -905,7 +905,7 @@ public:
|
||||
|
||||
/**
|
||||
* Delay the execution for a specified amount of time specified
|
||||
* in miliseconds
|
||||
* in milliseconds
|
||||
*/
|
||||
static void Delay(unsigned int msec);
|
||||
|
||||
|
||||
@@ -281,7 +281,7 @@ int main()
|
||||
#ifdef TEST_KWSYS_CXX_HAS_BACKTRACE
|
||||
#if defined(__PATHSCALE__) || defined(__PATHCC__) || \
|
||||
(defined(__LSB_VERSION__) && (__LSB_VERSION__ < 41))
|
||||
backtrace doesnt work with this compiler or os
|
||||
backtrace does not work with this compiler or os
|
||||
#endif
|
||||
#if (defined(__GNUC__) || defined(__PGI)) && !defined(_GNU_SOURCE)
|
||||
#define _GNU_SOURCE
|
||||
|
||||
Reference in New Issue
Block a user