g77 and libraries - how to use ?

Lorenzo Del Vecchio cyberneticus@inwind.it
Mon Mar 26 13:18:00 GMT 2001


Hi.
I'm using g77 and I want to compile a program that generates random numbers using rndm
function.
Here is the program:
________________________________

programm numbers
    real x,y

    do I=1,10
        x=rndm(0.)
        y=rndm(0.)
        print *,x,y
    end do

stop
end
________________________________

My g77 doesn't reconginze rndm function. Is it in a library I must call ? What's library's name
?
What the correct sintax to succesfully compile this program ?
And to link, please ?
Can anyone explain to me, please, how can call a library ? Is there a console command ?

Please say me everything about libraries...expecially mathematics libraries (I would use
CERNLIB, in particular: HFITHN, PROB, FUNLUX, RANMAR, RNORML).

Excuse me, but I don't know too much g77 at the moment...

I've seen there's a "f77" program in my Linux Mandrake 7.2. Can I use it ? It's better than g77
?

Sorry  for all this questions ^_^ I'm learning.
Thanks

Lorenzo Del Vecchio




More information about the Gcc-help mailing list