On Tue, Apr 5, 2011 at 9:20 PM, Eduardo Viruena Silva < eduardo.viru...@esfm.ipn.mx> wrote:
> On Tue, April 5, 2011 7:44 pm, Mehmet Erol Sanliturk wrote: > > On Tue, Apr 5, 2011 at 7:46 PM, Eduardo Viruena Silva < > > eduardo.viru...@esfm.ipn.mx> wrote: > > > >> > >> Hello, FreeBSD gurus, > >> > >> I have noticed that the Fortran Compiler f77 that used to be > >> in freebsd sources is not longer there in version 8.2-stable, > >> now it's in the obsolete software list. > >> > >> Nevertheless, it has some directories in the sources: > >> > >> /usr/src/gnu/usr.bin/cc/f77 > >> /usr/src/gnu/usr.bin/cc/f77/Makefile > >> /usr/src/gnu/usr.bin/cc/f771 > >> /usr/src/gnu/usr.bin/cc/f771/Makefile > >> /usr/src/gnu/usr.bin/cc/f77doc > >> /usr/src/gnu/usr.bin/cc/f77doc/Makefile > >> > >> > >> How can I install that compiler? > >> > >> The one in the ports does not work as fine as the the one in > >> the sources. > >> > >> > >> Thanks in advace, > >> > >> Eduardo. > >> > >> PS. Please answer to my e-mail address, I'm not subscribed to > >> the list. > >> > >> > >> > > > > My answer is NOT related directly to your question , please forgive me . > > > > > > I am using G95 ( from www.g95.org which is in the packages of FreeBSD ) > in > > Windows and Linux , and I like it very much because it generates very > good > > code , especially if the stack traces are enabled in command line , on > run > > time errors it is giving nearly exact source line of the error point with > > a > > list of called subroutines chain . Since the G95 is generated from the > > same > > sources for the FreeBSD , I think there is no difference between platform > > related compilers . > > > > Another point is ( if your source files have .FOR extension , it is using > > Fortran 77 , if it is .F90 , it is using the Fortran 95 ( be careful > about > > cases of letters ) . For such points , please read its manual . If any > > Fortran 77 source file has .F90 extension , it will produce a lot of > > errors > > because Fortran 77 is fixed line format based , Fortran 90 or 95 is free > > line format based . > > > > Thank you very much . > > > > > > Mehmet Erol Sanliturk > > > > Thanks Mehmet. > > I'd better start promoting the use of g95. > > Some people in the list say that f77 users must move on in their lives > and leave f77 behind. > > > ==== > > Something curious is happening, g95 does not seem to find its library > libg95. > > I have to write explicitly: > > g95 foo.for -o foo -L/usr/local/lib > > to compile the program foo. > > /etc/rc.d/ldconfig restart does not fix the problem. > Any ideas? > > > Thanks for answering, > > Eduardo. > > The command line is important for g95 . Therefore , please write a complete command line for compilation . Since these are multi-platform software AND different platforms are NOT equivalent in their directory structure , I think , these facts are not very important points . My approach is to use a batch file in Windows and a shell script in Linux to compile programs : For example : g95-cte.sh ( cte : compile to executable , there is another cts : compile to syntax ) g95 -ftrace=full -o $1 $1.FOR ( -ftrace=full means , generate code to produce call chain trace on run-time error . ) To compile a program , use it as follows ( use your extension as it is : .for or .FOR , FreeBSD is case-sensitive ) : g95-cte.sh hello Move g95-cte.sh after making it executable into a directory which it is in the $PATH , then it will be possible to use g95-cte.sh from any directory . For specially required directories , add their names into its command line with suitable prefixes . In the following page , http://www.g95.org/downloads.shtml there are binaries for FreeBSD . Since they are specific to platforms , they MAY NOT require specification of libraries , but , again , these are NOT important , specify them in shell script command line only one time , then use it continuously . Thank you very much . Mehmet Erol Sanliturk _______________________________________________ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"