kil@pandora.cs.wayne.edu (Joseph I. Landman) (06/11/91)
I am having great difficulty compiling forchek under TC 2.0 on an IBM Clone under dos 3.3. Is there a working MAKEFILE.TC in existance? Thanks! .;::::::;, ;: | Joe Landman Graduate Student, Computational :: :: | Condensed Matter Physics. ;: :: :: | Department of Physics, Wayne State Univ. `::::; oe ::::: andman | 666 Hancock Avenue, Detroit MI 48202 --------------------------+---+----------------------------------------- Internet/Bitnet: | / \ O / , \/ / kil@pandora.cs.wayne.edu |/ / o \ . /\ | \ userzv50@waynemts.bitnet |\ / , / <>< \/ /^\ \ 07480JLN@msu.bitnet |/ \ . \ // <O.o> / ATTnet: |\ \ ><> \ \ |\~/\ \ (313) 577-2752 |;\,./:;,..,.,,. ./:;.,.;/.\.,;;:;./|\ ./. ------------------------------+----------------------------------------- "A mind is a terrible thing." "If at first you dont succeed, use a bigger hammer."
gbastin@x102c.harris-atd.com (Gary Bastin 60293) (06/11/91)
In article <1991Jun11.005855.7527@cs.wayne.edu> kil@pandora.cs.wayne.edu (Joseph I. Landman) writes: >I am having great difficulty compiling forchek under TC 2.0 on >an IBM Clone under dos 3.3. Is there a working MAKEFILE.TC >in existance? Thanks! I posted a series of articles about FORCHEK recently. It probably comes closest to being a free 'lint for FORTRAN'. The package, as archived, had a bug in the Turbo-C makefile. I have had no problems porting FORCHEK to UNIX. There is also a makefile for VAX; I have no experience with that version of FORCHEK at all. I also posted a corrected Turbo-C makefile to allow successfully porting it to MSDOS. Anyway, here is the key info that I posted along the path to getting a running MSDOS version of FORCHEK. Enjoy! ---------------------------------------------------------------------- forchek (short for Fortran checker) is designed to detect certain errors in a Fortran program that a compiler usually does not. Forchek is not primarily intended to detect syntax errors. Its purpose is to assist the user in finding semantic errors. Semantic errors are legal in the Fortran language but are wasteful or may cause incorrect operation. For example, variables which are never used may indicate some omission in the program; uninitialized variables contain garbage which may cause incorrect results to be calculated; and variables which are not declared may not have the intended type. Bob Moniot, MONIOT@FORDMULC.BITNET ____________________________________________________________________ I would like to thank all the people who provided tips for compiling FORCHEK Ver. 2.1 on a pc; you were all very helpful! Now, I have something like lint for FORTRAN on my PC! Especially, thanks to Jim Davies (jrbd@craycos.com) who provided the vital clues needed to straighten out my thinking regarding the minimal compiler flags needed to compile FORCHEK using Turbo C on a PC. Basically, the problems were compiler directive related. It was necessary to delete the -d compiler flag. For some reason, under Turbo C Ver. 2.01, this particular flag caused the compiled executible to do very strange things (spewing strange ASCII symbols, etc.) when run. There were other, more straight forward problems, with the makefile.tc that was distributed. To help others in speeding up their compiling of FORCHEK on a PC, I have included a copy of the Turbo C makefile I found to work at the end of this posting. Many Thanks to all the people who contacted me, including: cawlfld@nye.nscee.edu (David E. Cawlfield) jrbd@craycos.com (James Davies) kxb@math.ksu.edu (Karl Buck) moshkovi@ecn.purdue.edu (Gennady Moshkovich) ndeng@owl.ce.berkeley.edu (Nan Deng) rao@amelia.nas.nasa.gov <Kuditipudi V. Rao> For anyone who missed the earlier postings, FORCHEK is available from the netlib server. Just do the following: mail netlib@research.att.com send forchek from fortran where the second line, "send forchek from fortran" is the subject, and there is no actual body to the message. A quick check of the archie server at McGill also shows that forchek is available from: Host uokmax.ecn.uoknor.edu (129.15.20.2) Last updated 05:03 20 Apr 1991 Location: /uploads FILE rw-r--r-- 107849 Jan 25 15:56 forchek.tar.Z ---- Gary Bastin, WB4YAF /-/-/ Internet: gbastin@x102c.ess.harris.com Mail Stop 102-4858 | phone: (407) 729-3045 Harris Corporation GASD | P.O.B. 94000, Melbourne FL 32902 Speaking from, but not for, Harris! new makefile.tc (Copy this to makefile prior to running make.) -------8<--CUT---HERE----------------------------------------------- # Turbo C version of Makefile for Fortran program checker # declare smaller data areas, and use the huge model. CFLAGS= -DSMALL_MACHINE -O -mh OBJS= exprtype.obj forchek.obj forlex.obj fortran.obj \ prsymtab.obj symtab.obj forchek: $(OBJS) tcc -eforchek $(CFLAGS) *.c exprtype.obj: forchek.h symtab.h tokdefs.h forchek.obj: forchek.h forlex.obj: forchek.h tokdefs.h symtab.h fortran.obj: forchek.h symtab.h fortran.c prsymtab.obj: forchek.h symtab.h symtab.obj: forchek.h symtab.h intrins.h -------8<--CUT---HERE----------------------------------------------- Gary Bastin, WB4YAF /-/-/ Internet: gbastin@x102c.ess.harris.com Mail Stop 102-4858 | phone: (407) 729-3045 Harris Corporation GASD | P.O.B. 94000, Melbourne FL 32902 Speaking from, but not for, Harris!