Thursday, September 3, 2020

The MinGW64 + MSYS2 Environment To Install Fortran


MinGW64 is an open source C/C++ compiler for Windows platforms based on the popular gcc available on Linux and on many other Operating Systems; Mingw64 can create both 32 and 64 bit binary executables.
MSYS2 is a command shell supporting a minimalistic Linux-like environment on Windows.
Using both them you can build standard open source software [originally developed for Linux] under Windows as well, simply using the classic build tool-chain, as in:

./configure
make
make install

Install MSYS2 from http://www.msys2.org/

Once MSYS2 is installed, it will open a shell. Update repositories with:
pacman -Syu

To search of a package called e.g. gfortran use:
pacman -Ss gfortran

Install compilers
pacman -S mingw64/mingw-w64-x86_64-gcc-fortran mingw64/mingw-w64-x86_64-gcc




No comments:

Post a Comment