Skip to content

jeandet/setup-fortran

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Setup Fortran

Test

Action to setup a Fortran compiler.

Usage

This action sets up a Fortran compiler on Ubuntu, MacOS and Windows runners.

jobs:
  test:
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, macos-latest, windows-latest]

    steps:
    - uses: awvwgk/setup-fortran@main
      id: setup-fortran
      with:
        compiler: gcc
        version: 11

    - run: ${{ env.FC }} --version
      env:
        FC: ${{ steps.setup-fortran.outputs.fc }}

Options

  • compiler: Compiler toolchain to setup, available options are gcc
  • version: Version of the compiler toolchain, available options for gcc are 5-12

Outputs

The action sets the following outputs:

  • cc: C compiler executable, e.g. gcc
  • fc: Fortran compiler executable, e.g. gfortran

Environment variables

The same values are also set as environment variables:

  • CC
  • FC

These are made available to subsequent workflow steps via the GITHUB_ENV environment file mechanism.

Runner compatibility

Support for the GCC toolchain varies across GitHub-hosted runner images.

runner 5 6 7 8 9 10 11 12
macos-11
macos-12
ubuntu-18.04
ubuntu-20.04
ubuntu-22.04
windows-2019
windows-2022

License

Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “as is” basis, without warranties or conditions of any kind, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this project by you, as defined in the Apache-2.0 license, shall be licensed as above, without any additional terms or conditions.

About

GitHub action to setup Fortran compiler and toolchain

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 98.3%
  • Fortran 1.7%