home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 3 / PDCD_3.iso / tex / texsrc3 / Src / mf / Makefile < prev    next >
Encoding:
Makefile  |  1993-05-22  |  4.0 KB  |  145 lines

  1. # This file makes MF in its various incarnations.
  2.  
  3. # It is a cut-down version of Makefile.in from the web2c distribution.
  4. # AMU seems to convert MF.p, MF.pas etc. into p.MF, pas.MF etc., so
  5. # some dependencies didn't work. Also, RISC OS doesn't have `sed', so
  6. # I've changed that small MF change file by hand.
  7.  
  8. # So to make a MF from scratch you type:
  9. #   1) amu veryclean
  10. #   2) amu mf.p
  11. #   3) amu biginimf bigvirmf OR amu inimf virmf
  12. # N.B. When making a small MF, add -DSMALLMF to the CFLAGS
  13. # Then copy (big){inimf,virmf} to your executables directory, and
  14. # tex.pool to the pool directory. Note that mf.pool is the same for
  15. # the 32-bit and 16-bit versions.
  16.  
  17. # Mark. (marks@stack.urc.tue.nl)
  18.  
  19. # Routines used everywhere.
  20. commondefines=^.lib.common_def ^.lib.texmf_def
  21. commonh=^.lib.h.common ^.lib.h.texmfmem
  22. commono=^.lib.o.library
  23.  
  24. # Routines used in TeX and Metafont.
  25. extrac=^.lib.c.texmf
  26. extrah=^.lib.h.texmf
  27.  
  28. # Routines used in TeX, Metafont, and BibTeX.
  29. fileioc=^.lib.c.openinout
  30. fileioo=o.openinout
  31.  
  32. objs=$(fileioo) o.mf0 o.mf1 o.mf2 o.mf3 o.mf4 o.mf5 o.mf6 o.mf7 \
  33.      o.mf8 o.mf9
  34. iobjs=o.iextra o.inimf
  35. vobjs=o.vextra o.imf
  36.  
  37. CC = cc
  38. CFLAGS = -throwback -W -DSMALLMF -f
  39. CPPFLAGS = -I^.lib 
  40.  
  41. CCLD = link
  42. LDFLAGS =
  43. libs = $(commono) C:o.Stubs $(extralibs)
  44.  
  45. default: all
  46. all: biginimf bigvirmf
  47. triptrap: tripmf
  48.  
  49. biginimf: $(iobjs) $(objs) $(commono)
  50.         $(CCLD) -o biginimf $(LDFLAGS) $(iobjs) $(objs) $(libs)
  51.         squeeze biginimf
  52.  
  53. bigvirmf: $(vobjs) $(objs) $(commono)
  54.         $(CCLD) -o bigvirmf $(LDFLAGS) $(vobjs) $(objs) $(libs)
  55.         squeeze bigvirmf
  56.  
  57. inimf: $(iobjs) $(objs) $(commono)
  58.         $(CCLD) -o inimf $(LDFLAGS) $(iobjs) $(objs) $(libs)
  59.         squeeze inimf
  60.  
  61. virmf: $(vobjs) $(objs) $(commono)
  62.         $(CCLD) -o virmf $(LDFLAGS) $(vobjs) $(objs) $(libs)
  63.         squeeze virmf
  64.  
  65. mf.p: mf.web mf.ch
  66.        tangle mf.web mf.ch
  67.  
  68. # The convert script produces the following:
  69. # c.mf0 c.mf1 c.mf2 c.mf3 c.mf4 c.mf5 c.mf6 c.mf7 c.mf8 c.mf9
  70. # c.imf h.coerce h.mfd, but AMU seems to want only one filename at
  71. # the start of the line. As all files are replaced by splitup, this isn't
  72. # much of a problem
  73. c.mf8: h.fixcoerce $(commondefines)
  74.         convert
  75.  
  76. # The (hand-coded) file $(extrac) and the (generated) file imf.c have
  77. # #ifdefs for INIMF, so we compile them differently.
  78. o.iextra: c.iextra
  79.         $(CC) $(CPPFLAGS) -DINIMF -DINI $(CFLAGS) -c c.iextra
  80.  
  81. o.inimf: c.inimf
  82.         $(CC) $(CPPFLAGS) -DINIMF $(CFLAGS) -c c.inimf
  83.  
  84. # Avoid compiling files in another directory.
  85. c.iextra: $(extrac)
  86.         remove c.iextra
  87.         copy $(extrac) c.iextra ~C~V
  88.  
  89. c.inimf: c.imf
  90.         remove c.inimf
  91.         copy c.imf c.inimf ~C~V
  92.  
  93. o.imf: c.imf $(commonh) h.mfd
  94.         $(CC) $(CFLAGS) $(CPPFLAGS) -c imf
  95.  
  96. c.vextra: $(extrac)
  97.         remove c.vextra
  98.         copy $(extrac) c.vextra ~C~V
  99.  
  100. o.vextra: c.vextra $(commonh) h.mfd
  101.         $(CC) $(CFLAGS) $(CPPFLAGS) -c vextra
  102.  
  103. c.openinout: $(fileioc)
  104.         remove c.openinout
  105.         copy $(fileioc) c.openinout ~C~V
  106.  
  107. o.openinout: c.openinout
  108.         $(CC) $(CFLAGS) $(CPPFLAGS) -c openinout
  109.  
  110. o.mf0: c.mf0 $(commonh) h.mfd
  111.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf0
  112. o.mf1: c.mf1 $(commonh) h.mfd
  113.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf1
  114. o.mf2: c.mf2 $(commonh) h.mfd
  115.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf2
  116. o.mf3: c.mf3 $(commonh) h.mfd
  117.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf3
  118. o.mf4: c.mf4 $(commonh) h.mfd
  119.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf4
  120. o.mf5: c.mf5 $(commonh) h.mfd
  121.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf5
  122. o.mf6: c.mf6 $(commonh) h.mfd
  123.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf6
  124. o.mf7: c.mf7 $(commonh) h.mfd
  125.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf7
  126. o.mf8: c.mf8 $(commonh) h.mfd
  127.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf8
  128. o.mf9: c.mf8 $(commonh) h.mfd
  129.         $(CC) $(CFLAGS) $(CPPFLAGS) -c mf9
  130.  
  131.  
  132. veryclean: clean
  133.         remove tripmf
  134.         remove inimf
  135.         remove biginimf
  136.         remove virmf
  137.         remove bigvirmf
  138.  
  139. clean:
  140.         wipe c.* ~CRV
  141.         wipe o.* ~CRV
  142.         remove h.coerce
  143.         remove mf.p
  144.         remove mf.pool
  145.