Re: No linking occurs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/30/2010 6:07 AM, Gunnar Sperber wrote:
   After repeated trouble, I made the simplest possible
test.  This is my program file listing:

Knoth.f95(~)-gedit

program nothing
end


and this is my attempt to make an object file:


       ~$ gfortran -c Knoth.f95
       ~$ gfortran -o Knoth.o
gfortran: no input files; unwilling to write output files
       ~$ file Knoth.o
Knoth.o : ELF 32-bit LSB relocatable, Intel 80386, version 1
              (SYSV), not stripped

What has gone wrong here?
Your 2nd invocation of gfortran requests a link, saving the executable as Knoth.o. As you already made a file Knoth.o, it warns you that you are asking for that file to be over-written. Maybe you meant something like
gfortran -o Knoth.exe Knoth.o

--
Tim Prince



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux