diff options
author | Ådne Hovda <ahovda@openit.com> | 2015-03-30 21:32:25 +0200 |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-03-31 14:55:00 -0400 |
commit | 7b1cdb00279908cacabada92f8a53e4986465423 (patch) | |
tree | df9c868e7d757892be8f9102f6fae603d9895fd4 /Utilities/cmjsoncpp/src/lib_json | |
parent | 00214357ba6166d829da68a65c0d50a61c663bd5 (diff) | |
download | cmake-7b1cdb00279908cacabada92f8a53e4986465423.tar.gz |
jsoncpp: Provide 'isfinite' implementation on older AIX and HP-UX
Newer AIX and HP-UX platforms provide 'isfinite' as a <math.h> macro.
Older versions do not, so add the definition if it is not provided.
Diffstat (limited to 'Utilities/cmjsoncpp/src/lib_json')
-rw-r--r-- | Utilities/cmjsoncpp/src/lib_json/json_writer.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/Utilities/cmjsoncpp/src/lib_json/json_writer.cpp b/Utilities/cmjsoncpp/src/lib_json/json_writer.cpp index 7f8e6f11d5..15222d6c46 100644 --- a/Utilities/cmjsoncpp/src/lib_json/json_writer.cpp +++ b/Utilities/cmjsoncpp/src/lib_json/json_writer.cpp @@ -27,6 +27,20 @@ # define isfinite finite #endif +// AIX +#if defined(_AIX) +# if !defined(isfinite) +# define isfinite finite +# endif +#endif + +// HP-UX +#if defined(__hpux) +# if !defined(isfinite) +# define isfinite finite +# endif +#endif + // Ancient glibc #if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ < 2 # if !defined(isfinite) |