Assume frexpl/f and fabsl/f, which are C99 (#799)

This commit is contained in:
Dana Robinson 2021-06-24 22:08:01 -07:00 committed by GitHub
parent 34f2df48b7
commit 6dd051101d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 14 additions and 52 deletions

View File

@ -156,12 +156,6 @@
/* Define to 1 if you have the `fork' function. */
#cmakedefine H5_HAVE_FORK @H5_HAVE_FORK@
/* Define to 1 if you have the `frexpf' function. */
#cmakedefine H5_HAVE_FREXPF @H5_HAVE_FREXPF@
/* Define to 1 if you have the `frexpl' function. */
#cmakedefine H5_HAVE_FREXPL @H5_HAVE_FREXPL@
/* Define to 1 if you have the `fseeko' function. */
#cmakedefine H5_HAVE_FSEEKO @H5_HAVE_FSEEKO@

View File

@ -467,8 +467,6 @@ CHECK_FUNCTION_EXISTS (alarm ${HDF_PREFIX}_HAVE_ALARM)
CHECK_FUNCTION_EXISTS (fcntl ${HDF_PREFIX}_HAVE_FCNTL)
CHECK_FUNCTION_EXISTS (flock ${HDF_PREFIX}_HAVE_FLOCK)
CHECK_FUNCTION_EXISTS (fork ${HDF_PREFIX}_HAVE_FORK)
CHECK_FUNCTION_EXISTS (frexpf ${HDF_PREFIX}_HAVE_FREXPF)
CHECK_FUNCTION_EXISTS (frexpl ${HDF_PREFIX}_HAVE_FREXPL)
CHECK_FUNCTION_EXISTS (gethostname ${HDF_PREFIX}_HAVE_GETHOSTNAME)
CHECK_FUNCTION_EXISTS (getrusage ${HDF_PREFIX}_HAVE_GETRUSAGE)

View File

@ -2007,8 +2007,8 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
## NOTE: clock_gettime may require linking to the rt or posix4 library
## so we'll search for it before calling AC_CHECK_FUNCS.
AC_SEARCH_LIBS([clock_gettime], [rt posix4])
AC_CHECK_FUNCS([alarm clock_gettime difftime fcntl flock fork frexpf])
AC_CHECK_FUNCS([frexpl gethostname getrusage gettimeofday])
AC_CHECK_FUNCS([alarm clock_gettime difftime fcntl flock fork])
AC_CHECK_FUNCS([gethostname getrusage gettimeofday])
AC_CHECK_FUNCS([lstat rand_r random setsysinfo])
AC_CHECK_FUNCS([siglongjmp sigsetjmp sigprocmask])
AC_CHECK_FUNCS([srandom strdup symlink])

View File

@ -766,12 +766,11 @@ typedef struct {
#ifndef HDfabs
#define HDfabs(X) fabs(X)
#endif /* HDfabs */
/* use ABS() because fabsf() fabsl() are not common yet. */
#ifndef HDfabsf
#define HDfabsf(X) ABS(X)
#define HDfabsf(X) fabsf(X)
#endif /* HDfabsf */
#ifndef HDfabsl
#define HDfabsl(X) ABS(X)
#define HDfabsl(X) fabsl(X)
#endif /* HDfabsl */
#ifndef HDfclose
#define HDfclose(F) fclose(F)
@ -863,20 +862,11 @@ H5_DLL H5_ATTR_CONST int Nflock(int fd, int operation);
#ifndef HDfrexp
#define HDfrexp(X, N) frexp(X, N)
#endif /* HDfrexp */
/* Check for Cray-specific 'frexpf()' and 'frexpl()' routines */
#ifndef HDfrexpf
#ifdef H5_HAVE_FREXPF
#define HDfrexpf(X, N) frexpf(X, N)
#else /* H5_HAVE_FREXPF */
#define HDfrexpf(X, N) frexp(X, N)
#endif /* H5_HAVE_FREXPF */
#endif /* HDfrexpf */
#ifndef HDfrexpl
#ifdef H5_HAVE_FREXPL
#define HDfrexpl(X, N) frexpl(X, N)
#else /* H5_HAVE_FREXPL */
#define HDfrexpl(X, N) frexp(X, N)
#endif /* H5_HAVE_FREXPL */
#endif /* HDfrexpl */
/* fscanf() variable arguments */
#ifndef HDfseek

View File

@ -108,10 +108,9 @@
#define HD_exit(N) _exit(N)
#define HDexp(X) exp(X)
#define HDfabs(X) fabs(X)
/* use ABS() because fabsf() fabsl() are not common yet. */
#define HDfabsf(X) ABS(X)
#define HDfabsl(X) ABS(X)
#define HDfclose(F) fclose(F)
#define HDfabsf(X) fabsf(X)
#define HDfabsl(X) fabsl(X)
#define HDfclose(F) fclose(F)
/* fcntl() variable arguments */
#define HDfdopen(N, S) fdopen(N, S)
#define HDfeof(F) feof(F)
@ -137,17 +136,8 @@
#define HDfree(M) free(M)
#define HDfreopen(S, M, F) freopen(S, M, F)
#define HDfrexp(X, N) frexp(X, N)
/* Check for Cray-specific 'frexpf()' and 'frexpl()' routines */
#ifdef H5_HAVE_FREXPF
#define HDfrexpf(X, N) frexpf(X, N)
#else /* H5_HAVE_FREXPF */
#define HDfrexpf(X, N) frexp(X, N)
#endif /* H5_HAVE_FREXPF */
#ifdef H5_HAVE_FREXPL
#define HDfrexpl(X, N) frexpl(X, N)
#else /* H5_HAVE_FREXPL */
#define HDfrexpl(X, N) frexp(X, N)
#endif /* H5_HAVE_FREXPL */
#define HDfrexpf(X, N) frexpf(X, N)
#define HDfrexpl(X, N) frexpl(X, N)
/* fscanf() variable arguments */
#ifdef H5_HAVE_FSEEKO
#define HDfseek(F, O, W) fseeko(F, O, W)

View File

@ -123,10 +123,9 @@
#define HD_exit(N) _exit(N)
#define HDexp(X) exp(X)
#define HDfabs(X) fabs(X)
/* use ABS() because fabsf() fabsl() are not common yet. */
#define HDfabsf(X) ABS(X)
#define HDfabsl(X) ABS(X)
#define HDfclose(F) fclose(F)
#define HDfabsf(X) fabsf(X)
#define HDfabsl(X) fabsl(X)
#define HDfclose(F) fclose(F)
/* fcntl() variable arguments */
#define HDfdopen(N, S) fdopen(N, S)
#define HDfeof(F) feof(F)
@ -152,17 +151,8 @@
#define HDfree(M) free(M)
#define HDfreopen(S, M, F) freopen(S, M, F)
#define HDfrexp(X, N) frexp(X, N)
/* Check for Cray-specific 'frexpf()' and 'frexpl()' routines */
#ifdef H5_HAVE_FREXPF
#define HDfrexpf(X, N) frexpf(X, N)
#else /* H5_HAVE_FREXPF */
#define HDfrexpf(X, N) frexp(X, N)
#endif /* H5_HAVE_FREXPF */
#ifdef H5_HAVE_FREXPL
#define HDfrexpl(X, N) frexpl(X, N)
#else /* H5_HAVE_FREXPL */
#define HDfrexpl(X, N) frexp(X, N)
#endif /* H5_HAVE_FREXPL */
#define HDfrexpf(X, N) frexpf(X, N)
#define HDfrexpl(X, N) frexpl(X, N)
/* fscanf() variable arguments */
#ifdef H5_HAVE_FSEEKO
#define HDfseek(F, O, W) fseeko(F, O, W)