diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2019-12-06 18:57:38 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2019-12-06 18:57:38 (GMT) |
commit | cf61098fa66bfba8a44738f7cc8843d667064596 (patch) | |
tree | 1533399015a0e91951c62e0150421ca038342233 /src | |
parent | eb52c2ea6ff2e78c0c1025d6a5db85f9d2cc8c92 (diff) | |
download | hdf5-cf61098fa66bfba8a44738f7cc8843d667064596.zip hdf5-cf61098fa66bfba8a44738f7cc8843d667064596.tar.gz hdf5-cf61098fa66bfba8a44738f7cc8843d667064596.tar.bz2 |
Fix compile errors - mostly in jni
Diffstat (limited to 'src')
-rw-r--r-- | src/H5private.h | 38 |
1 files changed, 17 insertions, 21 deletions
diff --git a/src/H5private.h b/src/H5private.h index c39c946..5ab9daf 100644 --- a/src/H5private.h +++ b/src/H5private.h @@ -1190,13 +1190,23 @@ typedef off_t h5_stat_size_t; #define HDrandom() HDrand() #endif /* HDrandom */ H5_DLL int HDrand(void); -#elif H5_HAVE_RANDOM + #ifndef HDsrandom + #define HDsrandom(S) HDsrand(S) + #endif /* HDsrandom */ + H5_DLL void HDsrand(unsigned int seed); +#elif defined(H5_HAVE_RANDOM) #ifndef HDrand #define HDrand() random() #endif /* HDrand */ #ifndef HDrandom #define HDrandom() random() #endif /* HDrandom */ + #ifndef HDsrand + #define HDsrand(S) srandom(S) + #endif /* HDsrand */ + #ifndef HDsrandom + #define HDsrandom(S) srandom(S) + #endif /* HDsrandom */ #else /* H5_HAVE_RANDOM */ #ifndef HDrand #define HDrand() rand() @@ -1204,6 +1214,12 @@ typedef off_t h5_stat_size_t; #ifndef HDrandom #define HDrandom() rand() #endif /* HDrandom */ + #ifndef HDsrand + #define HDsrand(S) srand(S) + #endif /* HDsrand */ + #ifndef HDsrandom + #define HDsrandom(S) srand(S) + #endif /* HDsrandom */ #endif /* H5_HAVE_RANDOM */ #ifndef HDread @@ -1324,26 +1340,6 @@ typedef off_t h5_stat_size_t; #ifndef HDsqrt #define HDsqrt(X) sqrt(X) #endif /* HDsqrt */ -#ifdef H5_HAVE_RAND_R - H5_DLL void HDsrand(unsigned int seed); - #ifndef HDsrandom - #define HDsrandom(S) HDsrand(S) - #endif /* HDsrandom */ -#elif H5_HAVE_RANDOM - #ifndef HDsrand - #define HDsrand(S) srandom(S) - #endif /* HDsrand */ - #ifndef HDsrandom - #define HDsrandom(S) srandom(S) - #endif /* HDsrandom */ -#else /* H5_HAVE_RAND_R */ - #ifndef HDsrand - #define HDsrand(S) srand(S) - #endif /* HDsrand */ - #ifndef HDsrandom - #define HDsrandom(S) srand(S) - #endif /* HDsrandom */ -#endif /* H5_HAVE_RAND_R */ #ifndef HDsscanf #define HDsscanf(S,FMT,...) sscanf(S,FMT,__VA_ARGS__) #endif /* HDsscanf */ |