Makefile 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. #######################################################################
  2. #
  3. # Makefile to compile all examples and convert them to LaTeX
  4. #
  5. #######################################################################
  6. # Compiler
  7. PP=ppc386
  8. # Unit directory
  9. # UNITDIR=/usr/lib/ppc/0.99.0/linuxunits
  10. # Any options you wish to pass.
  11. PPOPTS=
  12. # Script to convert the programs to LaTeX examples which can be included.
  13. PP2TEX=../pp2tex
  14. # Script to collect all examples in 1 file.
  15. MAKETEX=make1tex
  16. #######################################################################
  17. # No need to edit after this line.
  18. #######################################################################
  19. ifdef UNITDIR
  20. PPOPTS:=$(PPOPTS) -Up$(UNITDIR);
  21. endif
  22. .SUFFIXES: .pp .tex
  23. .PHONY: all tex clean execute
  24. OBJECTS=ex1 ex2 ex3 ex4 ex5 ex6 ex7 ex8 ex9 ex10 \
  25. ex11 ex12 ex13 ex14 ex15 ex16 ex17 ex18 ex19 ex20 \
  26. ex21 ex22 ex23 ex24 ex25 ex26 ex27 ex28 ex29 ex30 \
  27. ex31 ex32 ex33 ex34 ex35 ex36 ex37 ex38 ex39 ex40 \
  28. ex41 ex42 ex43 ex44 ex45 ex46 ex47 ex48 ex49 ex50
  29. TEXOBJECTS=$(addsuffix .tex, $(OBJECTS))
  30. # This is not the same list as objects, since some of the
  31. # tests are interactive.
  32. TOTEST=ex1 ex2 ex3 ex4 ex5 ex6 ex7 ex8 ex9 ex10 \
  33. ex11 ex12 ex13 ex14 ex15 ex16 ex17 ex18 ex19 ex20 \
  34. ex21 ex22 ex23 ex24 ex25 ex26 ex27 ex28 ex29 ex30 \
  35. ex31 ex32 ex33 ex34 ex35 ex36 ex37 ex38 ex39 ex40 \
  36. ex41 ex42 ex43 ex44 ex45 ex46 ex47 ex48 ex49 ex50
  37. LOGFILE=$(addsuffix .log, $(TOTEST))
  38. all : $(OBJECTS)
  39. tex : $(TEXOBJECTS)
  40. execute: $(LOGFILE)
  41. onetex : tex
  42. $(MAKETEX) $(TEXOBJECTS)
  43. clean :
  44. rm -f *.o *.s $(OBJECTS) $(TEXOBJECTS)
  45. rm -f *.ow *.sw *.exe *.dll *.log *.tmp
  46. $(OBJECTS): %: %.pp
  47. $(PP) $(PPOPTS) $*
  48. $(TEXOBJECTS): %.tex: %.pp head.tex foot.tex
  49. $(PP2TEX) $*
  50. $(LOGFILE): %.log: %.exe
  51. $* > $*.log