summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/generic/pst-pdf/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/generic/pst-pdf/Makefile')
-rw-r--r--Master/texmf-dist/source/generic/pst-pdf/Makefile85
1 files changed, 85 insertions, 0 deletions
diff --git a/Master/texmf-dist/source/generic/pst-pdf/Makefile b/Master/texmf-dist/source/generic/pst-pdf/Makefile
new file mode 100644
index 00000000000..81332c1c20e
--- /dev/null
+++ b/Master/texmf-dist/source/generic/pst-pdf/Makefile
@@ -0,0 +1,85 @@
+
+# `pst-pdf' -- Rolf Niepraschk, 2005/03/25, Rolf.Niepraschk@ptb.de
+
+
+.SUFFIXES : .tex .ltx .dvi .ps .pdf .eps
+
+PACKAGE = pst-pdf
+
+PDFLATEX = pdflatex
+
+LATEX = latex
+
+ARCHNAME = $(PACKAGE)-$(shell date +"%y%m%d")
+#ARCHNAME = $(PACKAGE)-$(shell date +"%y%m%d-%H%M")
+
+EXAMPLE = $(PACKAGE)-example.tex
+
+ADDINPUTS = penguin.eps elephant.ps knuth.png psf-demo.eps \
+ insect1.eps insect15.eps
+
+PDF_CONTAINER = $(EXAMPLE:.tex=-pics.pdf)
+
+ARCHFILES = $(PACKAGE).dtx $(PACKAGE).ins $(ADDINPUTS) Makefile \
+ ps4pdf CHANGES \
+ CHANGES.tex ps4pdf.bat ps4pdf.bat.w95
+ #ppf-example.tex TODO
+ #pstricks2.sty pstricks2.tex pstricks2.pro pst-dots2.pro
+
+PS2PDF = GS_OPTIONS=-dPDFSETTINGS=/prepress ps2pdf
+
+all : pdf
+
+pdf : $(EXAMPLE:.tex=.pdf)
+
+doc : $(PACKAGE).pdf
+
+$(EXAMPLE:.tex=.pdf) : $(EXAMPLE) $(ADDINPUTS) $(PDF_CONTAINER) $(PACKAGE).sty
+ $(PDFLATEX) $<
+
+%.pdf : %.dtx $(PACKAGE).sty
+ test -f $(basename $<).glo || touch -f $(basename $<).glo
+ test -f $(basename $<).idx || touch -f $(basename $<).idx
+ makeindex -s gglo.ist -t $(basename $<).glg -o $(basename $<).gls \
+ $(basename $<).glo
+ makeindex -s gind.ist -t $(basename $<).ilg -o $(basename $<).ind \
+ $(basename $<).idx
+ $(PDFLATEX) $<
+
+%.pdf : %.tex
+ $(PDFLATEX) $<
+
+$(PACKAGE).sty $(EXAMPLE) : $(PACKAGE).ins $(PACKAGE).dtx
+ tex $<
+
+$(EXAMPLE:.tex=.dvi) : $(EXAMPLE) $(ADDINPUTS) $(PACKAGE).sty
+ $(LATEX) $<
+
+$(PDF_CONTAINER:.pdf=.ps) : $(EXAMPLE:.tex=.dvi)
+ dvips -Ppdf -o $@ $<
+
+$(PDF_CONTAINER) : $(PDF_CONTAINER:.pdf=.ps)
+ @ if grep "needs cropping" $(<:-pics.ps=.log) > /dev/null; \
+ then \
+ $(PS2PDF) $< $@.tmp; pdfcrop $@.tmp $@ ; rm $@.tmp; \
+ else \
+ $(PS2PDF) $< $@; \
+ fi
+
+CHANGES : CHANGES.tex $(PACKAGE).pdf
+ $(PDFLATEX) $<
+ pdftotext -layout -nopgbrk $(<:.tex=.pdf) $@
+
+arch : CHANGES
+ zip $(ARCHNAME).zip $(ARCHFILES)
+
+clean :
+ $(RM) $(addprefix $(PACKAGE), \
+ .dvi .log .aux .bbl .blg .idx .ind .ilg .gls .glg .glo) \
+ $(addprefix $(basename $(EXAMPLE)), .ps .dvi .log .aux) \
+ $(EXAMPLE) $(PDF_CONTAINER:.pdf=.ps) $(PDF_CONTAINER)
+
+veryclean : clean
+ $(RM) $(PACKAGE).pdf $(EXAMPLE:.tex=.pdf)
+
+# EOF