diff options
author | KWSys Robot <kwrobot@kitware.com> | 2015-06-03 18:25:01 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-06-04 13:22:48 (GMT) |
commit | 6cafd8ed0bc8458ba2c6eb0e792c894cf4f37f90 (patch) | |
tree | b7f546925df589e72e6f23e31c376d641ad185f3 /kwsysPlatformTestsCXX.cxx | |
parent | ee71b75133d3e515172b5fbe3dccf7d3906f5a19 (diff) | |
download | CMake-6cafd8ed0bc8458ba2c6eb0e792c894cf4f37f90.zip CMake-6cafd8ed0bc8458ba2c6eb0e792c894cf4f37f90.tar.gz CMake-6cafd8ed0bc8458ba2c6eb0e792c894cf4f37f90.tar.bz2 |
KWSys 2015-06-03 (8533a79b)
Extract upstream KWSys using the following shell commands.
$ git archive --prefix=upstream-kwsys/ 8533a79b | tar x
$ git shortlog --no-merges --abbrev=8 --format='%h %s' 61e0419f..8533a79b
Zack Galbreath (1):
8533a79b SystemInformation: Add GetLoadAverage() method
Diffstat (limited to 'kwsysPlatformTestsCXX.cxx')
-rw-r--r-- | kwsysPlatformTestsCXX.cxx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/kwsysPlatformTestsCXX.cxx b/kwsysPlatformTestsCXX.cxx index 82620da..1596fe4 100644 --- a/kwsysPlatformTestsCXX.cxx +++ b/kwsysPlatformTestsCXX.cxx @@ -452,6 +452,19 @@ int main() } #endif +#ifdef TEST_KWSYS_CXX_HAS_GETLOADAVG +// Match feature definitions from SystemInformation.cxx +#if (defined(__GNUC__) || defined(__PGI)) && !defined(_GNU_SOURCE) +# define _GNU_SOURCE +#endif +#include <stdlib.h> +int main() +{ + double loadavg[3] = { 0.0, 0.0, 0.0 }; + return getloadavg(loadavg, 3); +} +#endif + #ifdef TEST_KWSYS_CXX_HAS_RLIMIT64 # if defined(KWSYS_HAS_LFS) # define _LARGEFILE_SOURCE |