home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / fchek284.zip / makefile.unix < prev    next >
Makefile  |  1996-03-30  |  16KB  |  504 lines

  1. #=======================================================================
  2. # UNIX version of Makefile for Fortran program checker, Version 2.8.2beta
  3. #
  4. # Current target list:
  5. #    TAGS
  6. #    all            build ftnchek and its documentation files
  7. #    blurb.txt
  8. #    check            run validation test suite
  9. #    clean            remove unnecessary intermediate files
  10. #    clobber            make clean, and remove ftnchek executable
  11. #    dcl2inc.doc        ASCII form of documentation
  12. #    dcl2inc.ps        PostScript form of documentation
  13. #    distclean        remove everything that can be rebuilt
  14. #    docs            documentation files
  15. #    fcl2vcg.doc        ASCII form of documentation
  16. #    fcl2vcg.ps        PostScript form of documentation
  17. #    fortran.c        translate yacc code to C
  18. #    ftnchek            ftnchek executable program
  19. #    ftnchek.1        UNIX manual page document
  20. #    ftnchek.doc        ASCII form of documentation
  21. #    ftnchek.hlp        VAX/VMS HELP library source
  22. #    ftnchek.ps        PostScript form of documentation
  23. #    install            install ftnchek and dcl2inc and their man pages
  24. #    install-exe        install ftnchek and dcl2inc executables
  25. #    install-man        install only man pages
  26. #    install-man-sgi        install only man pages on SGI systems
  27. #    lint            run lint on source code
  28. #    mostlyclean        same as clean
  29. #    prog            same as ftnchek
  30. #    realclean        same as clobber
  31. #    spotless        make distclean, then remove formatted
  32. #                documentation (do NOT do this if you don't
  33. #                have groff or nroff/troff to recreate the
  34. #                documentation!)
  35. #    TAGS            emacs editor tags file
  36. #    tags            ex and vi editor tags file
  37. #    uninstall        undo an ftnchek installation
  38. #
  39. # Object file targets:
  40. #    ftnchek.o
  41. #    exprtype.o
  42. #    forlex.o
  43. #    fortran.o
  44. #    pgsymtab.o
  45. #    plsymtab.o
  46. #    project.o
  47. #    symtab.o
  48. #
  49. # Machine-specific convenience targets:
  50. #    DEC-ALPHA        DEC Alpha OSF/1 and OpenVMS
  51. #    DJGPP            IBM PC/DOS djgpp compiler
  52. #    GENERIC            most UNIX systems
  53. #    HP            HP 9000/7xx HP-UX 9.x
  54. #    IBM-RS6000        IBM RS/6000-xxx AIX 3.2
  55. #    LINUX            Linux on 386
  56. #    LINUX-486        Linux on 486 and up
  57. #    MIPS-MIPS        MIPS RC6280 RISCos 2.1.1
  58. #    SGI            Silicon Graphics IRIX 4.x and 5.x
  59. #    SGI-INSTALL        SGI special install for man page
  60. #    SOLARIS2.x        Sun Solaris 2.x
  61. #    SOLARIS2.x-gcc        Sun Solaris 2.x with GNU gcc
  62. #    SOLARIS2.x-apcc        Sun Solaris 2.x with Apogee apcc
  63. #    STARDENT        Stardent 15xx OS 2.2
  64. #    SUNOS5.x        Sun SunOS 5.x (same as Solaris 2.x)
  65. #    SUNOS5.x-gcc        Sun SunOS 5.x (same as Solaris 2.x) with
  66. #                GNU gcc
  67. #    SUNOS5.x-apcc        Sun SunOS 5.x (same as Solaris 2.x)
  68. #                with Apogee apcc
  69. #    SUNOS4.0        Sun SunOS 4.0
  70. #    SUNOS4.1        Sun SunOS 4.1
  71. #    ULTRIX-MIPS        DECstation ULTRIX 4.x
  72. #    UNIX            most UNIX systems
  73. #
  74. # For each of these machine-specific targets, you can modify what is
  75. # built by defining a value for TARGETS on the make command line
  76. # (default: ftnchek).
  77. #
  78. # If you use the VCG_SUPPORT option, the fcl2vcg script and documentation
  79. # should be installed using the target
  80. #    install-vcg        for all systems except SGI
  81. #    sgi-install-vcg        for SGI
  82. #
  83. #    Copyright (C) 1991 by Robert K. Moniot.
  84. #    This program is free software.  Permission is granted to
  85. #    modify it and/or redistribute it, retaining this notice.
  86. #    No guarantees accompany this software.
  87. #
  88. # Acknowledgements and thanks to Nelson H. F. Beebe of the University
  89. # of Utah for improvements to this Makefile.
  90. # [25-Apr-1994]
  91. #=======================================================================
  92.  
  93. # These definitions should be customized for your local conventions
  94. # if you want to do "make install" or "make uninstall"
  95. BINDIR          = /usr/local/bin
  96. LIBDIR        = /usr/local/lib/ftnchek
  97. MANDIR          = /usr/local/man
  98. #NROFF        = groff # if you have groff, but not nroff
  99. NROFF        = nroff
  100. #STRIP           = echo >/dev/null # if your system lacks strip
  101. STRIP           = strip
  102. # The following is only used for targets ftnchek.doc and ftnchek.hlp
  103. # which are not needed for unix platforms.  It removes control chars
  104. # and converts tabs to blanks.
  105. #COL        = /usr/5bin/col -bx    # For BSD-like systems
  106. COL        = col -bx        # For System V-like systems
  107.  
  108. # Editor tags file support
  109. CTAGS        = ctags
  110. CTAGSFLAGS    = -t
  111. ETAGS        = etags
  112.  
  113. # For "make check", we need new awk, either AT&T nawk or GNU gawk.
  114. # However, IBM RS/6000 AIX calls it awk.
  115. #NAWK        = awk
  116. #NAWK        = gawk
  117. NAWK        = nawk
  118.  
  119. # These system utilities should be standard on all UNIX systems
  120. CC              = gcc
  121. CHMOD        = /bin/chmod
  122. CP              = /bin/cp
  123. MKDIR        = /bin/mkdir
  124. MV              = /bin/mv
  125. RM              = /bin/rm -f
  126. RMDIR        = /bin/rmdir
  127. SED        = /bin/sed
  128. SHELL        = /bin/sh
  129. TR        = /usr/ucb/tr
  130.  
  131. FTNCHEK        = ./ftnchek
  132. MAN2PS        = ./man2ps
  133.  
  134. # YACC          =parser name, YSTEM=stem on tab.c, tab.h
  135. # for yacc as the parser
  136. YACC            = yacc
  137. YSTEM           = y
  138.  
  139. # for GNU bison as the parser
  140. #YACC           = bison
  141. #YSTEM          = fortran
  142.  
  143. # OPTIONS is used to define various characteristics.  Most commonly
  144. # needed ones are given below; uncomment whichever you like.
  145. # See ftnchek.h for others, with their defaults and explanations.
  146.  
  147. #  To use the defaults for everything uncomment this:
  148. # OPTIONS         =
  149.  
  150. #  To make all table sizes 10x bigger than defaults uncomment this:
  151. OPTIONS        = -DLARGE_MACHINE
  152.  
  153. #  To allow the -vcg option uncomment this:
  154. OPTIONS    = -DVCG_SUPPORT
  155.  
  156. #  To prohibit underscores in variable names, inline comments
  157. #   starting with '!',  the DO ... ENDDO loop forms and INCLUDE statements:
  158. #OPTIONS        = -DSTRICT_SYNTAX
  159.  
  160. # CFLAGS is used to define the operating system and options
  161. # Other
  162. CFLAGS          = -DUNIX $(OPTIONS) -O -D_BSD -s
  163. LDFLAGS         = -s
  164. YFLAGS          = -d
  165.  
  166. # fortran.o first because of possible remake if tokdefs.h changes (see below)
  167. OBJS            = fortran.o exprtype.o forlex.o ftnchek.o \
  168.           pgsymtab.o plsymtab.o project.o symtab.o
  169.  
  170. SRCS            = exprtype.c forlex.c fortran.c ftnchek.c \
  171.           ftnchek.h intrins.h iokeywds.h keywords.h newarge.c \
  172.           newargh.c newcome.c newcomh.c pgsymtab.c plsymtab.c \
  173.           project.c shell_mung.c symtab.c symtab.h tokdefs.h \
  174.           y.tab.h
  175.  
  176. #=======================================================================
  177.  
  178. prog:    ftnchek
  179.  
  180. all:    ftnchek docs
  181.  
  182. check:
  183.     cd test; $(MAKE) NAWK="$(NAWK)" -i -s check
  184.  
  185. lint:
  186.     lint $(LINTFLAGS) $(OBJS:.o=.c) -lm
  187.  
  188. # Remove intermediate files that are not required after the program is
  189. # built.
  190. clean mostlyclean:
  191.     -$(RM) *.o
  192.     -$(RM) \#*
  193.     -$(RM) a.out
  194.     -$(RM) *~
  195.     -$(RM) core
  196.  
  197. # Remove almost everything that make can rebuild
  198. clobber realclean:    clean
  199.     -$(RM) fortran.c
  200.     -$(RM) ftnchek
  201.  
  202. # dcl2inc.doc is ascii text form of documentation.  It should not matter
  203. # whether dcl2inc.1 or dcl2inc.man is used here.
  204. dcl2inc.doc:    dcl2inc.man
  205.     $(NROFF) -man dcl2inc.man | $(COL) >dcl2inc.doc
  206.  
  207. dcl2inc.ps:    dcl2inc.man
  208.     $(MAN2PS) <dcl2inc.man >dcl2inc.ps
  209.  
  210. # fcl2vcg.doc is ascii text form of documentation.  It should not matter
  211. # whether fcl2vcg.1 or fcl2vcg.man is used here.
  212. fcl2vcg.doc:    fcl2vcg.man
  213.     $(NROFF) -man fcl2vcg.man | $(COL) >fcl2vcg.doc
  214.  
  215. fcl2vcg.ps:    fcl2vcg.man
  216.     $(MAN2PS) <fcl2vcg.man >fcl2vcg.ps
  217.  
  218. # Remove everything that make can rebuild, preparatory to making a
  219. # distribution version.  We intentionally do NOT remove .ps and .doc
  220. # files, because some UNIX systems lack nroff/troff/groff.
  221. distclean:    realclean
  222.     -$(RM) *.dcl
  223.     -$(RM) cscope.out
  224.     -$(RM) tags
  225.     -$(RM) TAGS
  226.     -$(RM) ftnchek.1
  227.  
  228. docs:    blurb.txt dcl2inc.doc dcl2inc.ps fcl2vcg.doc fcl2vcg.ps ftnchek.doc \
  229.     ftnchek.hlp ftnchek.ps
  230.  
  231. ftnchek: $(OBJS)
  232.     $(CC) $(CFLAGS) $(LDFLAGS) -o ftnchek $(OBJS) -lm
  233.  
  234. # Documentation targets: If you make changes to the documentation,
  235. # you should edit only ftnchek.man and then re-make these targets.
  236. # If ftnchek.1 fails to make, ftnchek.man is usable directly except
  237. # that some troff-like processors may not give satisfactory results.
  238. #
  239. # Following sed script trims out the if-else machinery contained in
  240. # ftnchek.man to produce a clean nroff document.  The lines of the
  241. # script correspond to the following actions:
  242. #    1. remove text between lines of form ``.if \nh \{'' or .ie \nh \{''
  243. #       and lines of form ``\}'' (these are the help-related additions)
  244. #    2. remove lines of form ``.if !\nh \{''  (these preface man text)
  245. #       Also remove ``.if !\nb \{'' which are for blurb.
  246. #    3. remove lines of form ``.el \{''  (start of the else sections of
  247. #       the .if's of step 1)
  248. #    4. remove lines of form ``\}'' (closures of step 3 lines)
  249. #    5. remove lines of form ``.ie \nh text'' (one-liner help text)
  250. #    6. change lines of form ``.el \nh text'' to ``text'' (these are
  251. #       one-liner man text)
  252. #    7. change lines of form ``.if !\nh text'' to ``text'' (ditto)
  253. ftnchek.1:    ftnchek.man
  254.     $(SED) -e '/^\.i[fe] \\nh \\{/,/^\\}$$/d' \
  255.         -e '/^\.if !\\n[bh] \\{/d' \
  256.         -e '/^\.el \\{/d' \
  257.         -e '/^\\}/d' \
  258.         -e '/^\.i[fe] \\nh /d' \
  259.         -e 's/^\.el *\(.*\)$$/\1/' \
  260.         -e 's/^\.if !\\nh *\(.*\)$$/\1/' \
  261.          < ftnchek.man > ftnchek.1
  262.  
  263. # ftnchek.doc is ascii text form of documentation.  It should not matter
  264. # whether ftnchek.1 or ftnchek.man is used here.
  265. ftnchek.doc:    ftnchek.man
  266.     $(NROFF) -man ftnchek.man | $(COL) >ftnchek.doc
  267.  
  268. # ftnchek.ps is PostScript form of documentation.
  269. ftnchek.ps:    ftnchek.man
  270.     @make ftnchek.1
  271.     $(MAN2PS) <ftnchek.1 >ftnchek.ps
  272.  
  273. # blurb.txt is an ascii file for informational mailings.
  274. blurb.txt:    ftnchek.man
  275.     $(NROFF) -man -rb1 ftnchek.man | $(COL) >blurb.txt
  276.  
  277. # ftnchek.hlp is a VMS HELP library source document:
  278. # create ftnchek.hlb with $ LIBR/CREATE/HELP FTNCHEK.HLB FTNCHEK.HLP
  279. # The leading and trailing newlines in ftnchek.hlp should be removed.
  280. ftnchek.hlp:    ftnchek.man
  281.     $(SED) -e '1d' ftnchek.man | \
  282.     $(NROFF) -man -rh1 | $(COL) | \
  283.     $(SED) -e 's/^-\([a-zA-Z][a-zA-Z]*\)/\/\1/' \
  284.         -e 's/\([^a-zA-Z]\)-\([a-zA-Z][a-zA-Z]*\)/\1\/\2/g' \
  285.     >ftnchek.hlp
  286.  
  287. #
  288. # N.B. tokdefs.h is copy of y.tab.h used to avoid remaking stuff when
  289. # grammar changes but not tokens.
  290. # The following copies y.tab.h to tokdefs.h if changed, then aborts make,
  291. # since dependencies may have changed.
  292. fortran.c: fortran.y
  293.     $(YACC) $(YFLAGS) fortran.y
  294.     $(MV) $(YSTEM).tab.c fortran.c
  295.     @if cmp -s $(YSTEM).tab.h tokdefs.h ; then true ; else \
  296.         echo; echo tokdefs.h changed -- repeat make ; \
  297.         $(CP) $(YSTEM).tab.h tokdefs.h; \
  298.         false ; \
  299.     fi
  300.  
  301. # Install program and documentation on system
  302. install:    install-exe install-man
  303.  
  304. install-exe:    ftnchek
  305.     $(CP) ftnchek $(BINDIR)
  306.     -$(STRIP) $(BINDIR)/ftnchek
  307.     $(CHMOD) 755 $(BINDIR)/ftnchek
  308.     -$(MKDIR) $(LIBDIR)
  309.     $(CP) dcl2inc.awk $(LIBDIR)/dcl2inc.awk
  310.     $(CHMOD) 644 $(LIBDIR)/dcl2inc.awk
  311.     $(SED) -e 's@^LIBDIR=.*$$@LIBDIR=$(LIBDIR)@' -e 's/nawk/$(NAWK)/' \
  312.         <dcl2inc.sh >$(BINDIR)/dcl2inc
  313.     $(CHMOD) 755 $(BINDIR)/dcl2inc
  314.  
  315. # Install the fcl2vcg script and its documentation only if vcg is used
  316. install-vcg: install-vcg-exe install-vcg-man
  317.  
  318. install-vcg-exe:
  319.     $(CP) fcl2vcg.sh $(BINDIR)/fcl2vcg
  320.     $(CHMOD) 755 $(BINDIR)/fcl2vcg
  321.  
  322. install-vcg-man:
  323.     $(CP) fcl2vcg.man $(MANDIR)/man1/fcl2vcg.1
  324.     -$(RM) $(MANDIR)/cat1/fcl2vcg.1
  325.     $(CHMOD) 644 $(MANDIR)/man1/fcl2vcg.1
  326.  
  327. # Install man pages, taking care to remove old formatted ones, because
  328. # many man implentations fail to compare time stamps of raw and
  329. # formatted files, and will show out-of-date formatted files.
  330. install-man: ftnchek.1
  331.     $(CP) dcl2inc.man $(MANDIR)/man1/dcl2inc.1
  332.     -$(RM) $(MANDIR)/cat1/dcl2inc.1
  333.     $(CHMOD) 644 $(MANDIR)/man1/dcl2inc.1
  334.     $(CP) ftnchek.1 $(MANDIR)/man1/ftnchek.1
  335.     -$(RM) $(MANDIR)/cat1/ftnchek.1
  336.     $(CHMOD) 644 $(MANDIR)/man1/ftnchek.1
  337.  
  338. # Remove everything that the install target installed.
  339. uninstall:
  340.     -$(RM) $(BINDIR)/dcl2inc
  341.     -$(RM) $(BINDIR)/fcl2vcg
  342.     -$(RM) $(BINDIR)/ftnchek
  343.     -$(RM) $(LIBDIR)/dcl2inc.awk
  344.     -$(RM) $(MANDIR)/cat1/dcl2inc.1
  345.     -$(RM) $(MANDIR)/cat1/ftnchek.1
  346.     -$(RM) $(MANDIR)/ftnchek.z    # SGI
  347.     -$(RM) $(MANDIR)/man1/dcl2inc.1
  348.     -$(RM) $(MANDIR)/man1/fcl2vcg.1
  349.     -$(RM) $(MANDIR)/man1/ftnchek.1
  350.     -$(RMDIR) $(LIBDIR)
  351.  
  352. # WARNING: do NOT execute this target, unless you have nroff/troff or groff
  353. # to recreate the formatted documentation files.
  354. spotless:    distclean
  355.     $(RM) blurb.txt
  356.     $(RM) dcl2inc.doc
  357.     $(RM) dcl2inc.ps
  358.     $(RM) fcl2vcg.doc
  359.     $(RM) fcl2vcg.ps
  360.     $(RM) ftnchek.doc
  361.     $(RM) ftnchek.hlp
  362.     $(RM) ftnchek.ps
  363.  
  364. # ex and vi editor tags file
  365. tags:    $(SRCS)
  366.     $(CTAGS) $(CTAGSFLAGS) *.[ch]
  367.  
  368. # emacs editor tags file
  369. TAGS:    $(SRCS)
  370.     $(ETAGS) *.[ch]
  371.  
  372. #=======================================================================
  373. # Object file dependencies on include files
  374.  
  375. ftnchek.o:    ftnchek.h
  376.  
  377. exprtype.o:    ftnchek.h symtab.h tokdefs.h
  378.  
  379. forlex.o:    ftnchek.h keywords.h symtab.h tokdefs.h
  380.  
  381. fortran.o:    ftnchek.h symtab.h fortran.c
  382.  
  383. pgsymtab.o:    ftnchek.h symtab.h
  384.  
  385. plsymtab.o:    ftnchek.h symtab.h
  386.  
  387. project.o:    ftnchek.h symtab.h
  388.  
  389. symtab.o:    ftnchek.h iokeywds.h intrins.h symtab.h tokdefs.h
  390.  
  391. #=======================================================================
  392. # Machine specific targets to build ftnchek with suitable compile options.
  393. # Use 'MAKE_OPTIONS= "YACC=/usr/local/gnu/bin/bison" "YSTEM=fortran"'
  394. # to select GNU bison parser, if you have touched fortran.y.
  395.  
  396. TARGETS        = ftnchek
  397.  
  398. # On DEC Alpha systems, compilers default to fast non-IEEE-754-conformant
  399. # arithmetic that is incapable of handling denormalized numbers,
  400. # Infinity, and NaN.  ftnchek can die on at least test/complex.f if IEEE
  401. # 754 behavior is not restored with -ieee_with_inexact.  The -Olimit
  402. # value increases the optimizer table sizes.
  403. DEC-ALPHA:
  404.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -O -D_BSD" \
  405.         "CC = c89 -ieee_with_inexact -Olimit 1000" $(MAKE_OPTIONS) \
  406.         $(TARGETS)
  407.  
  408. # target for djgpp on IBM PC by Judah Milgram, U. Maryand College Park
  409. DJGPP:
  410.     $(MAKE) 'CFLAGS= $(OPTIONS) -DLARGE_MACHINE -O' \
  411.     $(MAKE_OPTIONS) $(TARGETS)
  412.     coff2exe ftnchek
  413.     del ftnchek
  414.  
  415. GENERIC LINUX STARDENT UNIX:
  416.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -O -D_BSD" \
  417.         $(MAKE_OPTIONS) $(TARGETS)
  418.  
  419. # Add compiler flag to eliminate optimizer table overflow
  420. HP:
  421.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -O -D_BSD +Obb700" \
  422.         $(MAKE_OPTIONS) $(TARGETS)
  423.  
  424. IBM-RS6000:
  425.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) \
  426.         -DAIXC -DRAND_NO_ARG -O -D_BSD" \
  427.         "CC = c89 -D_POSIX_SOURCE" $(MAKE_OPTIONS) \
  428.         $(TARGETS)
  429.  
  430. LINUX-486:
  431.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -O -D_BSD -m486" \
  432.         $(MAKE_OPTIONS) $(TARGETS)
  433.  
  434. # MIPS RC6280 (and other models) RISCos 2.1.1AC (and EP/IX)
  435. MIPS-MIPS:
  436.     $(MAKE) "CFLAGS= -DUNIX $(OPTIONS) -DLARGE_MACHINE -O -D_BSD -Olimit 1000 -systype bsd43" \
  437.         $(MAKE_OPTIONS) $(TARGETS)
  438.  
  439. # SGI target improved by Mark Hanning-Lee of JPL.  Use -O2 for full
  440. # optimization.  4.0.x users can even use -O3, but 5.2 complains about
  441. # using -O3 with the -c option.
  442. # Warning: do not split this quoted string across a line boundary; SGI
  443. # IRIX 4.0.x make incorrectly preserves the newline, causing
  444. # compilation commands to fail.  Irix 5.x make handles the newline OK.
  445.  
  446. SGIFLAGS="CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -DVMS_IO -DVMS_TAB -O2 -D_BSD"
  447. SGI:
  448.     $(MAKE) $(SGIFLAGS) $(MAKE_OPTIONS) $(TARGETS)
  449.  
  450. # IRIX uses pre-formatted, packed man pages and nroff is not bundled with it.
  451. # Only execute this target if your IRIX has nroff.
  452. SGI-INSTALL: install-exe install-man-sgi
  453.  
  454. install-man-sgi:
  455.     $(NROFF) -man dcl2inc.man > dcl2inc.cat ; \
  456.     if pack dcl2inc.cat ; \
  457.     then \
  458.         $(MV) dcl2inc.cat.z $(MANDIR)/dcl2inc.z ; \
  459.         $(CHMOD) 644 $(MANDIR)/dcl2inc.z ; \
  460.     fi
  461.     $(NROFF) -man ftnchek.man > ftnchek.cat ; \
  462.     if pack ftnchek.cat ; \
  463.     then \
  464.         $(MV) ftnchek.cat.z $(MANDIR)/ftnchek.z ; \
  465.         $(CHMOD) 644 $(MANDIR)/ftnchek.z ; \
  466.     fi
  467.  
  468. sgi-install-vcg: install-vcg-exe install-vcg-man-sgi
  469.  
  470. install-vcg-man-sgi:
  471.     $(NROFF) -man fcl2vcg.man > fcl2vcg.cat ; \
  472.     if pack fcl2vcg.cat ; \
  473.     then \
  474.         $(MV) fcl2vcg.cat.z $(MANDIR)/fcl2vcg.z ; \
  475.         $(CHMOD) 644 $(MANDIR)/fcl2vcg.z ; \
  476.     fi
  477.  
  478. SOLARIS2.x SUNOS5.x:
  479.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -xO4 -D_BSD" \
  480.         $(MAKE_OPTIONS) $(TARGETS)
  481.  
  482. SOLARIS2.x-gcc SUNOS5.x-gcc:
  483.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -O2 -D_BSD" \
  484.         $(MAKE_OPTIONS) CC=gcc $(TARGETS)
  485.  
  486. SOLARIS2.x-apcc SUNOS5.x-apcc:
  487.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -O5 -D_BSD" \
  488.         $(MAKE_OPTIONS) CC=apcc $(TARGETS)
  489.  
  490. SUNOS4.0:
  491.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -O -D_BSD" \
  492.         $(MAKE_OPTIONS) $(TARGETS)
  493.  
  494. # NB: ftnchek 2.8 fails with -O4 on SunOS 4.1.3, but -O3 is okay
  495. # The failure occurs from bad code generation for forlex.c with cc
  496. # version RELEASE SC1.0 1Mar1991 (from "showrev cc").
  497. SUNOS4.1:
  498.     $(MAKE) "CFLAGS= -DUNIX -DLARGE_MACHINE $(OPTIONS) -O3 -D_BSD" \
  499.         $(MAKE_OPTIONS) $(TARGETS)
  500.  
  501. ULTRIX-MIPS:
  502.     $(MAKE) "CFLAGS= -DUNIX $(OPTIONS) -DLARGE_MACHINE -Olimit 2000 -O -D_BSD"\
  503.         $(MAKE_OPTIONS) $(TARGETS)
  504.