summaryrefslogtreecommitdiff
path: root/Modules/CheckFortranSourceRuns.cmake
diff options
context:
space:
mode:
authorscivision <scivision@users.noreply.github.com>2023-02-04 20:25:58 -0500
committerBrad King <brad.king@kitware.com>2023-02-06 09:55:23 -0500
commitb19036d8b38aaebd892ef8bff1fe5eb0a37fc6a3 (patch)
treeffc97617a0eacf5b1ea285efa17e79f576ce7b0e /Modules/CheckFortranSourceRuns.cmake
parent2a0c105cf08190284b288057c693eeddef5066fc (diff)
downloadcmake-b19036d8b38aaebd892ef8bff1fe5eb0a37fc6a3.tar.gz
Help: CheckSource{Compiles,Runs}: fix typo and clarify
Diffstat (limited to 'Modules/CheckFortranSourceRuns.cmake')
-rw-r--r--Modules/CheckFortranSourceRuns.cmake10
1 files changed, 7 insertions, 3 deletions
diff --git a/Modules/CheckFortranSourceRuns.cmake b/Modules/CheckFortranSourceRuns.cmake
index 28f713fdf0..985c765599 100644
--- a/Modules/CheckFortranSourceRuns.cmake
+++ b/Modules/CheckFortranSourceRuns.cmake
@@ -18,12 +18,16 @@ subsequently be run.
[SRC_EXT <extension>])
Check that the source supplied in ``<code>`` can be compiled as a Fortran source
- file, linked as an executable and then run. The ``<code>`` must be a Fortran program
- containing at least an ``end`` statement--for example:
+ file, linked as an executable and then run. The ``<code>`` must be a Fortran
+ ``program``.
.. code-block:: cmake
- check_fortran_source_runs("real :: x[*]; call co_sum(x); end" F2018coarrayOK)
+ check_fortran_source_runs("program test
+ real :: x[*]
+ call co_sum(x)
+ end program"
+ HAVE_COARRAY)
This command can help avoid costly build processes when a compiler lacks support
for a necessary feature, or a particular vendor library is not compatible with