diff options
author | Allen Byrne <50328838+byrnHDF@users.noreply.github.com> | 2021-12-02 19:06:53 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-02 19:06:53 (GMT) |
commit | dc39092ced51917c08caf17067b1a8efe17deeaa (patch) | |
tree | b66a4710a4f9d6f5e0030c65c41714c831624a0d /config/cmake/HDF5UseFortran.cmake | |
parent | 9149dbad88fb5a906425afc0f8b5974f022b315a (diff) | |
download | hdf5-dc39092ced51917c08caf17067b1a8efe17deeaa.zip hdf5-dc39092ced51917c08caf17067b1a8efe17deeaa.tar.gz hdf5-dc39092ced51917c08caf17067b1a8efe17deeaa.tar.bz2 |
Merge Fix Fortran REGEX and newlines #1226 (#1228)
Diffstat (limited to 'config/cmake/HDF5UseFortran.cmake')
-rw-r--r-- | config/cmake/HDF5UseFortran.cmake | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/config/cmake/HDF5UseFortran.cmake b/config/cmake/HDF5UseFortran.cmake index 40027ea..0d05e20 100644 --- a/config/cmake/HDF5UseFortran.cmake +++ b/config/cmake/HDF5UseFortran.cmake @@ -141,7 +141,7 @@ FORTRAN_RUN ("REAL and INTEGER KINDs" # dnl -- LINE 5 -- number of valid real kinds # # Convert the string to a list of strings by replacing the carriage return with a semicolon -string (REGEX REPLACE "\n" ";" PROG_OUTPUT "${PROG_OUTPUT}") +string (REGEX REPLACE "[\r\n]+" ";" PROG_OUTPUT "${PROG_OUTPUT}") list (GET PROG_OUTPUT 0 pac_validIntKinds) list (GET PROG_OUTPUT 1 pac_validRealKinds) @@ -195,7 +195,7 @@ foreach (KIND ${VAR}) " ) FORTRAN_RUN("INTEGER KIND SIZEOF" ${PROG_SRC_${KIND}} XX YY VALIDINTKINDS_RESULT_${KIND} PROG_OUTPUT1) - string (REGEX REPLACE "\n" "" PROG_OUTPUT1 "${PROG_OUTPUT1}") + string (REGEX REPLACE "[\r\n]+" "" PROG_OUTPUT1 "${PROG_OUTPUT1}") set (pack_int_sizeof "${pack_int_sizeof} ${PROG_OUTPUT1},") endforeach () @@ -238,7 +238,7 @@ foreach (KIND ${VAR} ) " ) FORTRAN_RUN ("REAL KIND SIZEOF" ${PROG_SRC2_${KIND}} XX YY VALIDREALKINDS_RESULT_${KIND} PROG_OUTPUT2) - string (REGEX REPLACE "\n" "" PROG_OUTPUT2 "${PROG_OUTPUT2}") + string (REGEX REPLACE "[\r\n]+" "" PROG_OUTPUT2 "${PROG_OUTPUT2}") set (pack_real_sizeof "${pack_real_sizeof} ${PROG_OUTPUT2},") endforeach () @@ -296,7 +296,7 @@ FORTRAN_RUN ("SIZEOF NATIVE KINDs" ${PROG_SRC3} XX YY PAC_SIZEOF_NATIVE_KINDS_RE # dnl -- LINE 6 -- kind of DOUBLE PRECISION # # Convert the string to a list of strings by replacing the carriage return with a semicolon -string (REGEX REPLACE "\n" ";" PROG_OUTPUT3 "${PROG_OUTPUT3}") +string (REGEX REPLACE "[\r\n]+" ";" PROG_OUTPUT3 "${PROG_OUTPUT3}") list (GET PROG_OUTPUT3 0 PAC_FORTRAN_NATIVE_INTEGER_SIZEOF) list (GET PROG_OUTPUT3 1 PAC_FORTRAN_NATIVE_INTEGER_KIND) |