123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475 |
- #######################################################################
- #
- # Makefile to compile all examples and convert them to LaTeX
- #
- #######################################################################
- # Compiler
- ifndef FPC
- ifdef PP
- FPC=$(PP)
- endif
- endif
- ifndef FPC
- FPCPROG:=$(strip $(wildcard $(addsuffix /fpc$(SRCEXEEXT),$(SEARCHPATH))))
- ifneq ($(FPCPROG),)
- FPCPROG:=$(firstword $(FPCPROG))
- FPC:=$(shell $(FPCPROG) -PB)
- ifneq ($(findstring Error,$(FPC)),)
- override FPC=ppc386
- endif
- else
- override FPC=ppc386
- endif
- endif
- override FPC:=$(subst $(SRCEXEEXT),,$(FPC))
- override FPC:=$(subst \,/,$(FPC))$(SRCEXEEXT)
- # Unit directory
- # UNITDIR=/usr/lib/ppc/0.99.0/linuxunits
- # Any options you wish to pass.
- PPOPTS=
- # Script to convert the programs to LaTeX examples which can be included.
- PP2TEX=../pp2tex
- # Script to collect all examples in 1 file.
- MAKETEX=make1tex
- #######################################################################
- # No need to edit after this line.
- #######################################################################
- ifdef UNITDIR
- PPOPTS:=$(PPOPTS) -Up$(UNITDIR);
- endif
- .SUFFIXES: .pp .tex
- .PHONY: all tex clean
- OBJECTS=ex1 ex10 ex11 ex12 ex15 ex22 ex29 ex36 ex37 ex38 ex39 ex40 ex45 ex46\
- ex49 ex5 ex56 ex6 ex60 ex61 ex62 ex65 ex66 ex76 ex77 ex79 ex8 ex80 \
- ex9 ex91
- TEXOBJECTS=$(addsuffix .tex, $(OBJECTS))
- all : $(OBJECTS)
- tex : $(TEXOBJECTS)
- onetex : tex
- $(MAKETEX) $(TEXOBJECTS)
- clean :
- rm -f *.o *.s $(OBJECTS) $(TEXOBJECTS)
- rm -f *.ow *.sw *.exe *.dll
-
- $(OBJECTS): %: %.pp
- $(FPC) $(PPOPTS) $*
- $(TEXOBJECTS): %.tex: %.pp head.tex foot.tex
- $(PP2TEX) $*
|