diff options
author | Scot Breitenfeld <brtnfld@hdfgroup.org> | 2008-08-26 16:05:06 (GMT) |
---|---|---|
committer | Scot Breitenfeld <brtnfld@hdfgroup.org> | 2008-08-26 16:05:06 (GMT) |
commit | d30db46df3405b08fe71336f642db9849dc711cc (patch) | |
tree | ba7c439119a75d6b61ab72d678b9aa2ff1ee0b62 /configure.in | |
parent | 64842512fd88f7020e0bc7feb189d5fe60793671 (diff) | |
download | hdf5-d30db46df3405b08fe71336f642db9849dc711cc.zip hdf5-d30db46df3405b08fe71336f642db9849dc711cc.tar.gz hdf5-d30db46df3405b08fe71336f642db9849dc711cc.tar.bz2 |
[svn-r15534] Description:
Added a test program to determine if -r8 or the default of REAL is DOUBLE PRECISION. Sets the variable FORTRAN_DEFAULT_REALisDBLE_F to true if default REAL is DOUBLE PRECISION.
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/configure.in b/configure.in index 8512685d..514fcef 100644 --- a/configure.in +++ b/configure.in @@ -381,12 +381,44 @@ dnl ], AC_MSG_RESULT(yes), dnl AC_MSG_RESULT(no) dnl FCFLAGS="$FCFLAGS_saved") + + + FORTRAN_DEFAULT_REALisDBLE="no" + AC_MSG_CHECKING([if Fortran default REAL is DOUBLE PRECISION]) + + AC_TRY_RUN([ + MODULE type_mod + INTERFACE h5t + MODULE PROCEDURE h5t_real + MODULE PROCEDURE h5t_dble + END INTERFACE + CONTAINS + SUBROUTINE h5t_real(r) + REAL :: r + END SUBROUTINE h5t_real + SUBROUTINE h5t_dble(d) + DOUBLE PRECISION :: d + END SUBROUTINE h5t_dble + END MODULE type_mod + PROGRAM main + USE type_mod + REAL :: r + DOUBLE PRECISION :: d + CALL h5t(r) + CALL h5t(d) + END PROGRAM main + ], + AC_MSG_RESULT(no), + [AC_MSG_RESULT(yes) + FORTRAN_DEFAULT_REALisDBLE="yes"]) dnl Change back to the C language AC_LANG_POP(Fortran) else echo "no" fi +AM_CONDITIONAL([FORTRAN_DEFAULT_REALisDBLE_F], [test "X$FORTRAN_DEFAULT_REALisDBLE" = "Xyes"]) + dnl ---------------------------------------------------------------------- dnl Check if they would like the C++ interface compiled dnl |