public inbox for fortran@gcc.gnu.org
 help / color / mirror / Atom feed
From: "frank.shed via fortran" <fortran@gcc.gnu.org>
To: <fortran@gcc.gnu.org>
Subject: A novice really trying to run MinGW to compile FORTRAN 77
Date: Tue, 03 Jul 2018 12:46:00 -0000	[thread overview]
Message-ID: <000301d412cb$df1bf740$9d53e5c0$@shed@btinternet.com> (raw)

Hallo,

 

Can you help me please.

 

For a task I'm doing I have managed to get a software program, which is
quite old and written in Fortran 77 computer language. The program runs ok
on a Windows system provided you have a GFortran Compiler. I have downloaded
the Fortran Compiler (MinGW) and installed it on my laptop Windows 10. To
demonstrate it is installed there are a couple of simple checks to show the
software version number and separately a "help" page. Both these work ok.

I got some instructions for this from the "MinGW" website. 

 

I have also copied down a very simple Fortran program, "hallo.for", three
lines of text, and loaded them into a folder I newly opened called
"programs", this is inside the MinGW directory, which as advised, is on the
main "C" drive.

 

The program run in DOS, by the command prompt.

 

1.)    At the command prompt I type    cd C:\    then press enter  this
gives C:\ >

 

2.)    I then type        cd C:\MinGW\programs     then press enter
this gives C:\MinGW\programs >      this is the folder where my simple
"hallo" program is

 

3.)    I then type        gfortran  -ffree-form hallo.for -o hallo.exe
this is the instruction given to access the file, compile and run the simple
"hallo" program

It doesn't work I get the error message --  gfortran : error :  hallo.for :
no such file or directory

 

For line item 3.) above I also tried gfortran hallo.for -o hallo.exe    

This doesn't work I get the error message --  gfortran : error :  hallo.for
: no such file or directory

 

I have also tried   gcc  -ffree-form hallo.for -o hallo.exe  and  gcc
hallo.for -o hallo.exe

This doesn't work I get the same error message for both  --  gcc : error :
hallo.for : no such file or directory

 
gcc : fatal error : no input files

 
compilation stopped    

 

I have tried many alternative ways to do this but the instructions provided
by MinGW are wide-ranging, covering many different operating systems and
different computer languages.   

 

I really would like your help and think I am doing something very stupid and
basically wrong.

 

Regards

Frank

 

             reply	other threads:[~2018-07-03 12:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-03 12:46 frank.shed via fortran [this message]
2018-07-03 20:01 Tim Zeisloft
2018-07-03 23:50 ` Paul Richard Thomas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='000301d412cb$df1bf740$9d53e5c0$@shed@btinternet.com' \
    --to=fortran@gcc.gnu.org \
    --cc=frank.shed@btinternet.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).