home *** CD-ROM | disk | FTP | other *** search
/ Encyclopedia of Graphics File Formats Companion / GFF_CD.ISO / software / unix / saoimage / sao1_07.tar / makefile.main < prev    next >
Makefile  |  1991-08-03  |  6KB  |  180 lines

  1. #
  2. # Makefile for SAOimage
  3. #
  4. # To build:
  5. #    % make aix        # IBM RS/6000 running AIX
  6. #    % make alliant        # Alliant FX series
  7. #    % make apollo        # Any Apollo, software floating point
  8. #    % make apollo_68882    # Apollo for MC68882 fp
  9. #    % make apollo_fpa    # Apollo for FPA1
  10. #    % make apollo_prism    # Apollo for PRISM architecture (a88k)
  11. #    % make hp        # HP-UX
  12. #    % make mips        # MIPStation running RISCOS
  13. #    % make sgi        # SGI Personal Iris running Irix
  14. #     % make sun        # All Sun architectures, maybe software fp
  15. #    % make sun_sparc    # Sun SPARC
  16. #    % make sun_ffpa        # Sun-3 floating point accelerator
  17. #    % make sun_f68881    # Sun-3 motorola f68881 floating point
  18. #    % make sun_fswitch    # All Suns, switchable floating point
  19. #    % make ultrix        # DECstation and VAXstation
  20. #
  21. # The full "make install" both installs SAOimage in Unix and sets up for
  22. # communications with IRAF:
  23. #    % make install
  24. #    (or, % make install SAOBINDIR = "/ourown/local/bindir")
  25. #
  26. # Partial installs may also be used:
  27. #    % make install_saobin    # just install binary (can add SAOBINDIR)
  28. #    % make install_saoman    # just install manual page
  29. #    % make install_fifo    # just install iraf fifo's
  30. #    % make install_imtoolrc    # just install iraf imtoolrc file
  31. #
  32. # NOTICE: You can't run the installation targets from this umbrella makefile.
  33. # You must run the correct makefile.<machine> for the workstation you are
  34. # installing on.  For instance,
  35. #
  36. #    % make -f makefile.dec install
  37. #
  38. # Other options:
  39. #    % make manual        # make manual.dvi file in doc subdirectory
  40. #    % make clean        # clean up object & miscellaneous other files
  41. #    % make tar        # make saoimage.tar in CWD
  42. #    % make -s pipe        # create tarfile on stdout for piping
  43. #    % make tape        # create tarfile on /dev/nrxt8
  44. #
  45. # Make macros (parameters) that can be specified on command line:
  46. #    SAOBINDIR        # Destination directory for SAOimage program
  47. #    SAOMANDIR        # Destination directory for on-line manpage
  48. #    ARCFILE            # Disk archive file name (used with make tar)
  49. #    TAPEDEV            # Tape archive device name (used with make tape)
  50.  
  51. SAOIMAGE = saoimage
  52.  
  53. oops:
  54.     @echo No architecture specified.  Please re-run as \"make ARCH\", \
  55.     where ARCH is one of
  56.     @grep '^[a-z].*:' makefile | grep -v $@ | sed 's/:.*$$//'
  57.  
  58. # It would be nicer to print out the supported architectures in a pretty
  59. # table, but the AIX awk complains that END is a syntax error, so we will
  60. # leave this out for now.
  61.  
  62. #        awk '{printf ("    %-14.14s", $$0); np++; \
  63. #         if (np == 3) {printf ("\n"); np=0} \
  64. #         } END {if (np > 0) print ""}'
  65.  
  66.  
  67. # Following are targets for all the supported architecures.  Note that there
  68. # is a different makefile.<vendor> for each workstation manufacturer; this
  69. # is sufficient at this stage.  The only changes that should be required in
  70. # selecting a particular architecture is the adjustment of the ADFLAGS macro,
  71. # which sets the architecture-dependent flags for compilation and linking.
  72.  
  73.  
  74. aix:                        # IBM RT6000 (AIX)
  75.     $(MAKE) -f makefile.ibm $(SAOIMAGE) ARCH=$@ \
  76.         ADFLAGS="-D_BSD"
  77.  
  78.  
  79. alliant:                    # Alliant FX
  80.     $(MAKE) -f makefile.alnt $(SAOIMAGE) ARCH=$@
  81.  
  82.  
  83. # For Apollo, note that you need ADFLAGS = -DXV11R2 for OS prior to SR10.2.
  84. # The XV11R2 flag is necessary when libX11 does not contain an entry for
  85. # "XVisualIDFromVisual"; the relevant ifdef is in clrinit.c.
  86.  
  87. apollo:                        # Apollo, software floating pt
  88.     $(MAKE) -f makefile.apo $(SAOIMAGE) ARCH=$@ \
  89.         ADFLAGS="-W0,-opt,3,-ndb -L/usr/lib/X11"
  90.  
  91. apollo_68882:                    # Apollo, MC68882 floating pt
  92.     $(MAKE) -f makefile.apo $(SAOIMAGE) ARCH=$@ \
  93.         ADFLAGS="-W0,-opt,3,-cpu,3000,-ndb -L/usr/lib/X11"
  94.  
  95. apollo_fpa:                    # Apollo, Weitek FPA floating pt
  96.     $(MAKE) -f makefile.apo $(SAOIMAGE) ARCH=$@ \
  97.         ADFLAGS="-W0,-opt,3,-cpu,FPA1,-ndb -L/usr/lib/X11"
  98.  
  99. apollo_prism:                    # Apollo, PRISM architecture
  100.     $(MAKE) -f makefile.apo $(SAOIMAGE) ARCH=$@ \
  101.         ADFLAGS="-W0,-opt,3,-cpu,a88k,-ndb -L/usr/lib/X11"
  102.  
  103. apollo_a88k:
  104.     $(MAKE) apollo_prism
  105.  
  106. apollo_m68k:
  107.     $(MAKE) apollo_68882
  108.  
  109.  
  110. hp:                        # Hewlett-Packard (HPUX)
  111.     $(MAKE) -f makefile.hp $(SAOIMAGE) ARCH=$@
  112.  
  113.  
  114. mips:                        # MIPS, Inc. (RISCOS)
  115.     $(MAKE) -f makefile.mips $(SAOIMAGE) ARCH=$@
  116.  
  117.  
  118. sgi:                        # SGI Personal Iris (Irix)
  119.     $(MAKE) -f makefile.sgi $(SAOIMAGE) ARCH=$@ \
  120.         ADFLAGS="-I/usr/include/sun -I/usr/include/bsd"
  121.  
  122.  
  123. sun:                        # Sun generic => SPARC
  124.     $(MAKE) sun_sparc
  125.  
  126. sun_sparc:                    # Sun, sparc architecture
  127.     $(MAKE) -f makefile.sun $(SAOIMAGE) ARCH=$@
  128.  
  129. sun_f68881:                    # Sun3, mc68881 floating pt
  130.     $(MAKE) -f makefile.sun $(SAOIMAGE) ARCH=$@ \
  131.         ADFLAGS="-f68881"
  132.  
  133. sun_ffpa:                    # Sun3, ffpa floating pt
  134.     $(MAKE) -f makefile.sun $(SAOIMAGE) ARCH=$@ \
  135.         ADFLAGS="-ffpa"
  136.  
  137. sun_fswitch:                    # Suns, switchable fp
  138.     $(MAKE) -f makefile.sun $(SAOIMAGE) ARCH=$@ \
  139.         ADFLAGS="-fswitch"
  140.  
  141.  
  142. ultrix:                        # DECstation/VAXstation (Ultrix)
  143.     $(MAKE) -f makefile.dec $(SAOIMAGE) ARCH=$@
  144.  
  145. dec:                        # DEC (Ultrix)
  146.     $(MAKE) ultrix
  147.  
  148.  
  149. # Some of the utility targets are generic enough that we can just point to
  150. # one of the architecture-specific makefiles.
  151.  
  152. MAKEUTIL = makefile.dec
  153.  
  154. ARCFILE = saoimage.tar
  155. TAPEDEV = /dev/nrxt8
  156.  
  157. tar:
  158. #    $(MAKE) -f makefile`ls .buildarch.* | sed 's/\.buildarch//'` $@
  159.     $(MAKE) -f $(MAKEUTIL) $@ ARCFILE=$(ARCFILE)
  160. pipe:
  161.     $(MAKE) -f $(MAKEUTIL) -s tar ARCFILE=-
  162. tape:
  163.     $(MAKE) -f $(MAKEUTIL) tar ARCFILE=$(TAPEDEV)
  164. clean:
  165.     $(MAKE) -f $(MAKEUTIL) $@
  166.  
  167. install:
  168.     @echo You can\'t run install from this umbrella makefile. \
  169.         You must run the correct
  170.     @echo makefile.machine for the workstation \
  171.         you are installing on.  For instance,
  172.     @echo
  173.     @echo "    % make -f makefile.dec install"
  174.  
  175. manual:
  176.     cd doc; latex $@
  177.     @echo $@.dvi created in `pwd`.
  178.     @echo You must run a DVI translator appropriate for \
  179.         your printer, e.g., dvips.
  180.