2020-11-21 02:29:25 +08:00
|
|
|
# vcpkg_find_fortran
|
|
|
|
|
2021-03-11 01:56:07 +08:00
|
|
|
The latest version of this document lives in the [vcpkg repo](https://github.com/Microsoft/vcpkg/blob/master/docs/maintainers/vcpkg_find_fortran.md).
|
2021-03-01 05:17:19 +08:00
|
|
|
|
2020-11-21 02:29:25 +08:00
|
|
|
Checks if a Fortran compiler can be found.
|
|
|
|
Windows(x86/x64) Only: If not it will switch/enable MinGW gfortran
|
|
|
|
and return required cmake args for building.
|
|
|
|
|
|
|
|
## Usage
|
|
|
|
```cmake
|
2021-08-17 04:42:31 +08:00
|
|
|
vcpkg_find_fortran(<out_var>)
|
|
|
|
```
|
|
|
|
|
|
|
|
## Example
|
|
|
|
```cmake
|
|
|
|
vcpkg_find_fortran(fortran_args)
|
|
|
|
# ...
|
|
|
|
vcpkg_configure_cmake(...
|
|
|
|
OPTIONS
|
|
|
|
${fortran_args}
|
|
|
|
)
|
2020-11-21 02:29:25 +08:00
|
|
|
```
|
|
|
|
|
|
|
|
## Source
|
2021-03-01 05:17:19 +08:00
|
|
|
[scripts/cmake/vcpkg\_find\_fortran.cmake](https://github.com/Microsoft/vcpkg/blob/master/scripts/cmake/vcpkg_find_fortran.cmake)
|