diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/pst-optexp/Makefile')
-rw-r--r-- | Master/texmf-dist/source/latex/pst-optexp/Makefile | 75 |
1 files changed, 40 insertions, 35 deletions
diff --git a/Master/texmf-dist/source/latex/pst-optexp/Makefile b/Master/texmf-dist/source/latex/pst-optexp/Makefile index e12b08c835d..aac418da1b4 100644 --- a/Master/texmf-dist/source/latex/pst-optexp/Makefile +++ b/Master/texmf-dist/source/latex/pst-optexp/Makefile @@ -7,53 +7,57 @@ LATEX = latex ARCHNAME = $(PACKAGE)-$(shell date +"%y%m%d") ARCHNAME_TDS = $(PACKAGE).tds -ARCHFILES = $(PACKAGE).dtx $(PACKAGE).ins Makefile \ - README Changes $(PACKAGE)-quickref.pdf \ - $(PACKAGE).pdf $(PACKAGE)-DE.pdf +ARCHFILES = Makefile README Changes \ + $(addprefix $(PACKAGE), -quickref.pdf .dtx .ins .pdf -DE.pdf) PS2PDF = GS_OPTIONS=-dPDFSETTINGS=/prepress ps2pdf -all : doc doc-DE quickref +all : doc-all Changes -doc : $(PACKAGE).pdf - -doc-DE : $(PACKAGE)-DE.pdf +doc-all: doc doc-DE doc-code quickref +doc: $(PACKAGE).pdf +doc-DE: $(PACKAGE)-DE.pdf +doc-code: $(PACKAGE)-code.pdf quickref: $(PACKAGE)-quickref.pdf -dist : doc doc-DE quickref Changes +dist : $(ARCHFILES) mkdir -p pst-optexp - cp $(ARCHFILES) pst-optexp - tar chvzf $(ARCHNAME).tar.gz pst-optexp - rm -rf pst-optexp - @ echo - @ echo $(ARCHNAME).tar.gz + cp $(ARCHFILES) $(PACKAGE) $(PACKAGE).dvi: L = english $(PACKAGE)-DE.dvi: L = ngerman +$(PACKAGE)-code.dvi: L = english %.dvi: $(PACKAGE).dtx $(PACKAGE).sty $(PACKAGE).ist $(PACKAGE).pro - $(LATEX) -jobname=$(basename $@) '\newcommand*{\mainlang}{$(L)}\input{$(PACKAGE).dtx}' - $(LATEX) -jobname=$(basename $@) '\newcommand*{\mainlang}{$(L)}\input{$(PACKAGE).dtx}' + + if [ "$@" = "$(PACKAGE)-code.dvi" ]; then \ + sed 's/^\\OnlyDescription//' < $(PACKAGE).dtx > tmp.dtx; \ + else cp $(PACKAGE).dtx tmp.dtx; \ + fi + + $(LATEX) -jobname=$(basename $@) '\newcommand*{\mainlang}{$(L)}\input{tmp.dtx}' + $(LATEX) -jobname=$(basename $@) '\newcommand*{\mainlang}{$(L)}\input{tmp.dtx}' splitindex -m "" $(basename $@).idx if test -e $(basename $@)-idx.idx; then \ makeindex -s gind.ist -t $(basename $@)-idx.ilg \ -o $(basename $@)-idx.ind $(basename $@)-idx.idx; \ fi if test -e $(basename $@)-doc.idx; then \ - makeindex -s pst-optexp.ist -t $(basename $@)-doc.ilg \ + makeindex -s $(PACKAGE).ist -t $(basename $@)-doc.ilg \ -o $(basename $@)-doc.ind $(basename $@)-doc.idx; \ fi - $(LATEX) -jobname=$(basename $@) '\newcommand*{\mainlang}{$(L)}\input{$(PACKAGE).dtx}' + $(LATEX) -jobname=$(basename $@) '\newcommand*{\mainlang}{$(L)}\input{tmp.dtx}' splitindex -m "" $(basename $@).idx if test -e $(basename $@)-idx.idx; then \ makeindex -s gind.ist -t $(basename $@)-idx.ilg \ -o $(basename $@)-idx.ind $(basename $@)-idx.idx; \ fi if test -e $(basename $@)-doc.idx; then \ - makeindex -s pst-optexp.ist -t $(basename $@)-doc.ilg \ + makeindex -s $(PACKAGE).ist -t $(basename $@)-doc.ilg \ -o $(basename $@)-doc.ind $(basename $@)-doc.idx; \ fi - $(LATEX) -jobname=$(basename $@) '\newcommand*{\mainlang}{$(L)}\input{$(PACKAGE).dtx}' + $(LATEX) -jobname=$(basename $@) '\newcommand*{\mainlang}{$(L)}\input{tmp.dtx}' + $(RM) -f tmp.dtx %.ps: %.dvi dvips $< @@ -66,7 +70,7 @@ $(PACKAGE)-quickref.tex: $(PACKAGE)-quickref.py $(PACKAGE).dtx $(PACKAGE)-quickref.pdf: $(PACKAGE)-quickref.tex pdflatex $< -$(PACKAGE).sty $(PACKAGE).pro $(PACKAGE).tex $(PACKAGE).ist: $(PACKAGE).ins $(PACKAGE).dtx +$(PACKAGE).sty $(PACKAGE).pro $(PACKAGE).ist: $(PACKAGE).ins $(PACKAGE).dtx tex $< Changes: Changes.py $(PACKAGE).dtx @@ -75,32 +79,33 @@ Changes: Changes.py $(PACKAGE).dtx arch : Changes zip $(ARCHNAME).zip $(ARCHFILES) -arch-tds : Changes +arch-tds : dist $(RM) $(ARCHNAME_TDS).zip - mkdir -p tds/tex/latex/pst-optexp - mkdir -p tds/doc/latex/pst-optexp - mkdir -p tds/source/latex/pst-optexp - mkdir -p tds/dvips/pst-optexp - cp pst-optexp.sty tds/tex/latex/pst-optexp/ - cp pst-optexp.pro tds/dvips/pst-optexp/ - cp Changes pst-optexp.pdf pst-optexp-DE.pdf \ - README pst-optexp-quickref.pdf \ - tds/doc/latex/pst-optexp/ - cp pst-optexp.dtx pst-optexp.ins Makefile \ - tds/source/latex/pst-optexp/ + mkdir -p tds/tex/latex/$(PACKAGE) + mkdir -p tds/doc/latex/$(PACKAGE) + mkdir -p tds/source/latex/$(PACKAGE) + mkdir -p tds/dvips/$(PACKAGE) + cp $(PACKAGE).sty tds/tex/latex/$(PACKAGE)/ + cp $(PACKAGE).pro tds/dvips/$(PACKAGE)/ + cp Changes $(PACKAGE).pdf $(PACKAGE)-DE.pdf \ + README $(PACKAGE)-quickref.pdf \ + tds/doc/latex/$(PACKAGE)/ + cp $(PACKAGE).dtx $(PACKAGE).ins Makefile \ + tds/source/latex/$(PACKAGE)/ cd tds ; zip -r ../$(ARCHNAME_TDS).zip tex doc source dvips cd .. rm -rf tds ctan : dist arch-tds - tar cf $(PACKAGE).tar $(ARCHNAME_TDS).zip $(ARCHNAME).tar.gz + zip -r $(PACKAGE).zip $(ARCHNAME_TDS).zip $(PACKAGE) + $(RM) -rf $(PACKAGE)/ clean : - $(RM) $(foreach prefix, $(PACKAGE) $(PACKAGE)-DE $(PACKAGE)-quickref, \ + $(RM) $(foreach prefix, $(PACKAGE) $(PACKAGE)-code $(PACKAGE)-DE $(PACKAGE)-quickref, \ $(addprefix $(prefix), .dvi .ps .log .aux .bbl .blg .out .tmp \ .toc .idx .ind .ilg .hd \ -idx.idx -idx.ilg -idx.ind -doc.idx -doc.ilg -doc.ind .hd)) \ $(PACKAGE)-quickref.tex veryclean : clean - $(RM) $(addprefix $(PACKAGE), .pdf -DE.pdf -quickref.pdf .sty .pro .ist) Changes + $(RM) $(addprefix $(PACKAGE), .pdf -DE.pdf -code.pdf -quickref.pdf .sty .pro .ist) Changes |