1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90
|
#----------------------------------------------------------------------------
#
# pgSphere documentation makefile
#
#----------------------------------------------------------------------------
USE_PGXS = 1
ifdef USE_PGXS
PG_CONFIG = pg_config
PGXS := $(shell $(PG_CONFIG) --pgxs)
include $(PGXS)
else
subdir = contrib/pg_sphere/doc
top_builddir = ../../..
include $(top_builddir)/src/Makefile.global
include $(top_srcdir)/contrib/contrib-global.mk
endif
.SECONDARY:
.NOTPARALLEL:
ifndef COLLATEINDEX
COLLATEINDEX = $(DOCBOOKSTYLE)/bin/collateindex.pl
endif
ifndef JADE
JADE = openjade
endif
SGMLINCLUDE = -D $(srcdir)
ALLSGML := $(wildcard $(srcdir)/*.sgm)
ifdef DOCBOOKSTYLE
CATALOG = -c $(DOCBOOKSTYLE)/catalog
endif
COLLATEINDEX := $(PERL) $(COLLATEINDEX) -f -g
all : html
.PHONY: html pdf ps
XMLDCL = declaration/xml.dcl
html : pg_sphere.xml $(ALLSGML) pg_sphere.dsl
@rm -f *.html
@rm -rf html
mkdir html
mkdir html/img
cp img/*.jpg img/*.png html/img
cp pg_sphere.css html
$(JADE) $(JADEFLAGS) $(SGMLINCLUDE) $(CATALOG) -b UTF-8 -d pg_sphere.dsl -i html -t sgml $(XMLDCL) $<
mv *.html html
pg_sphere.tex : pg_sphere.xml $(ALLSGML) pg_sphere.dsl
$(JADE) $(JADEFLAGS) $(SGMLINCLUDE) $(CATALOG) -d pg_sphere.dsl -i print -t tex -o $@ $(XMLDCL) $<
pdf : jadetex.cfg pg_sphere.pdf
pg_sphere.pdf: pg_sphere.tex
@rm -f $*.aux $*.log $*.out
pdfjadetex $<
pdfjadetex $<
pdfjadetex $<
ps : pg_sphere.ps
pg_sphere.ps: pg_sphere.pdf
pdftops $< $@
pg_sphere.dsl : pg_sphere.dsl-dist
cp $< $@
jadetex.cfg : jadetex.cfg-dist
cp $< $@
##
## Clean
##
clean distclean maintainer-clean:
# HTML
rm -rf html pg_sphere.dsl
# print
rm -f *.rtf *.tex *.dvi *.aux *.log *.ps *.pdf *.out *.fot jadetex.cfg
# img
make clean -C img
|