summaryrefslogtreecommitdiffstats
path: root/fortran/src
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2011-08-19 15:11:10 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2011-08-19 15:11:10 (GMT)
commit13426d47feb8b5d417c83a1b38de08fff66cf1e0 (patch)
treeb6eb4329c68168b9d36dd6dd001619175e5b1faf /fortran/src
parent5213c69fd59f34733dcbd5285ddc00d2b2b9e7a5 (diff)
downloadhdf5-13426d47feb8b5d417c83a1b38de08fff66cf1e0.zip
hdf5-13426d47feb8b5d417c83a1b38de08fff66cf1e0.tar.gz
hdf5-13426d47feb8b5d417c83a1b38de08fff66cf1e0.tar.bz2
[svn-r21263] Add F2003 support to CMake builds
Diffstat (limited to 'fortran/src')
-rw-r--r--fortran/src/CMakeLists.txt20
1 files changed, 20 insertions, 0 deletions
diff --git a/fortran/src/CMakeLists.txt b/fortran/src/CMakeLists.txt
index e2da265..bb927eb 100644
--- a/fortran/src/CMakeLists.txt
+++ b/fortran/src/CMakeLists.txt
@@ -120,6 +120,17 @@ SET_GLOBAL_VARIABLE (HDF5_LIBRARIES_TO_EXPORT "${HDF5_LIBRARIES_TO_EXPORT};${HDF
H5_SET_LIB_OPTIONS (${HDF5_F90_C_LIB_TARGET} ${HDF5_F90_C_LIB_NAME} ${LIB_TYPE})
#-----------------------------------------------------------------------------
+# Fortran 2003 standard
+#-----------------------------------------------------------------------------
+IF (FORTRAN_HAVE_ISO_C_BINDING AND HDF5_ENABLE_F2003)
+ # default real is 4 bytes, so include double signatures
+ SET (F_STATUS "_F03")
+ELSE (FORTRAN_HAVE_ISO_C_BINDING AND HDF5_ENABLE_F2003)
+ # default real is 8 bytes, so exclude double signatures
+ SET (F_STATUS "_F90")
+ENDIF (FORTRAN_HAVE_ISO_C_BINDING AND HDF5_ENABLE_F2003)
+
+#-----------------------------------------------------------------------------
# Fortran Real Size
#-----------------------------------------------------------------------------
IF (FORTRAN_DEFAULT_REAL_NOT_DOUBLE)
@@ -139,6 +150,7 @@ SET (f90_F_SRCS
# normal distribution
${HDF5_F90_SRC_SOURCE_DIR}/H5f90global.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5_ff${F_STATUS}.f90
${HDF5_F90_SRC_SOURCE_DIR}/H5_ff.f90
${HDF5_F90_SRC_SOURCE_DIR}/H5Aff.f90
${HDF5_F90_SRC_SOURCE_DIR}/H5Dff.f90
@@ -153,6 +165,14 @@ SET (f90_F_SRCS
${HDF5_F90_SRC_SOURCE_DIR}/H5Sff.f90
${HDF5_F90_SRC_SOURCE_DIR}/H5Tff.f90
${HDF5_F90_SRC_SOURCE_DIR}/H5Zff.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5Aff${F_STATUS}.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5Dff${F_STATUS}.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5Eff${F_STATUS}.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5Lff${F_STATUS}.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5Off${F_STATUS}.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5Pff${F_STATUS}.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5Rff${F_STATUS}.f90
+ ${HDF5_F90_SRC_SOURCE_DIR}/H5Tff${F_STATUS}.f90
${HDF5_F90_SRC_SOURCE_DIR}/H5_DBLE_Interface${F_DBLE}.f90
)