X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=doc%2Fautomake.mk;h=37a62153cb53c02e65b055ecb104d2b0116a0328;hb=6014da385d5f3f2a3971f0049d2d54c0dc6e95f8;hp=29871f7fce79cc324a6d2601a979e43bb90ea623;hpb=2fda41bd152e292b85160c1384419a2c554dea2b;p=pspp diff --git a/doc/automake.mk b/doc/automake.mk index 29871f7fce..37a62153cb 100644 --- a/doc/automake.mk +++ b/doc/automake.mk @@ -59,6 +59,7 @@ doc_pspp_dev_TEXINFOS = doc/version-dev.texi \ doc/dev/pc+-file-format.texi \ doc/dev/portable-file-format.texi \ doc/dev/spv-file-format.texi \ + doc/dev/tlo-file-format.texi \ doc/dev/encrypted-file-wrappers.texi \ doc/dev/q2c.texi @@ -106,87 +107,104 @@ EXTRA_DIST += \ doc/pspp-manual.css -AM_MAKEINFOFLAGS=-I $(top_srcdir)/doc/examples -I $(top_builddir)/doc/examples -am__TEXINFO_TEX_DIR=:$(top_srcdir)/doc/examples:$(top_builddir)/doc/examples +AM_MAKEINFOFLAGS=-I $(top_srcdir)/doc/pspp-figures -I $(top_builddir)/doc/pspp-figures +am__TEXINFO_TEX_DIR=:$(top_srcdir)/doc/pspp-figures:$(top_builddir)/doc/pspp-figures ################# Example programs ############################## -EXAMPLE_SYNTAX = \ - doc/examples/autorecode.sps \ - doc/examples/chisquare.sps \ - doc/examples/compute.sps \ - doc/examples/count.sps \ - doc/examples/descriptives.sps \ - doc/examples/flip.sps \ - doc/examples/frequencies.sps \ - doc/examples/means.sps \ - doc/examples/one-sample-t.sps \ - doc/examples/independent-samples-t.sps \ - doc/examples/reliability.sps \ - doc/examples/split.sps \ - doc/examples/tutorial1.sps \ - doc/examples/tutorial2.sps \ - doc/examples/tutorial3.sps \ - doc/examples/tutorial4.sps \ - doc/examples/tutorial5.sps \ - doc/examples/tutorial6.sps \ - doc/examples/tutorial7.sps \ - doc/examples/weight.sps - - -EXTRA_DIST += $(EXAMPLE_SYNTAX) - -EXAMPLE_SPVS = $(EXAMPLE_SYNTAX:.sps=.spv) doc/examples/tutorial7b.spv -EXAMPLE_OUTPUTS = $(EXAMPLE_SPVS:.spv=.out) -EXAMPLE_HTML = $(EXAMPLE_SPVS:.spv=.html) - -example-spv: $(EXAMPLE_SPVS) -example-outputs: $(EXAMPLE_OUTPUTS) -example-html: $(EXAMPLE_HTML) -PHONY += example-outputs example-html - -$(top_builddir)/doc/pspp.info: $(EXAMPLE_OUTPUTS) -$(top_builddir)/doc/pspp.ps: $(EXAMPLE_OUTPUTS) -$(top_builddir)/doc/pspp.dvi: $(EXAMPLE_OUTPUTS) -$(top_builddir)/doc/pspp.html: $(EXAMPLE_HTML) -$(top_builddir)/doc/pspp.pdf: $(EXAMPLE_OUTPUTS) -$(top_builddir)/doc/pspp.xml: $(EXAMPLE_OUTPUTS) - -CLEANFILES += $(EXAMPLE_OUTPUTS) $(EXAMPLE_SPVS) -SUFFIXES += .sps .spv +FIGURE_SYNTAX = \ + doc/pspp-figures/autorecode.sps \ + doc/pspp-figures/chisquare.sps \ + doc/pspp-figures/compute.sps \ + doc/pspp-figures/count.sps \ + doc/pspp-figures/descriptives.sps \ + doc/pspp-figures/flip.sps \ + doc/pspp-figures/frequencies.sps \ + doc/pspp-figures/means.sps \ + doc/pspp-figures/one-sample-t.sps \ + doc/pspp-figures/independent-samples-t.sps \ + doc/pspp-figures/reliability.sps \ + doc/pspp-figures/split.sps \ + doc/pspp-figures/tutorial1.sps \ + doc/pspp-figures/tutorial2.sps \ + doc/pspp-figures/tutorial3.sps \ + doc/pspp-figures/tutorial4.sps \ + doc/pspp-figures/tutorial5.sps \ + doc/pspp-figures/tutorial6.sps \ + doc/pspp-figures/tutorial7.sps \ + doc/pspp-figures/weight.sps + + +EXTRA_DIST += $(FIGURE_SYNTAX) + +FIGURE_SPVS = $(FIGURE_SYNTAX:.sps=.spv) \ + doc/pspp-figures/tutorial2a.spv \ + doc/pspp-figures/tutorial2b.spv \ + doc/pspp-figures/tutorial5a.spv \ + doc/pspp-figures/tutorial5b.spv \ + doc/pspp-figures/tutorial7a.spv \ + doc/pspp-figures/tutorial7b.spv +FIGURE_TXTS = $(FIGURE_SPVS:.spv=.txt) +FIGURE_TEXIS = $(FIGURE_TXTS:.txt=.texi) +FIGURE_HTML = $(FIGURE_SPVS:.spv=.html) +FIGURE_PDF = $(FIGURE_SPVS:.spv=.pdf) + +figure-spv: $(FIGURE_SPVS) +figure-txts: $(FIGURE_TXTS) +figure-texis: $(FIGURE_TEXIS) +figure-html: $(FIGURE_HTML) +figure-pdf: $(FIGURE_PDF) +PHONY += figure-spv figure-txts figure-texis figure-html figure-pdf + +$(top_builddir)/doc/pspp.info: $(FIGURE_TEXIS) +$(top_builddir)/doc/pspp.ps: $(FIGURE_TEXIS) +$(top_builddir)/doc/pspp.dvi: $(FIGURE_TEXIS) +$(top_builddir)/doc/pspp.html: $(FIGURE_HTML) +$(top_builddir)/doc/pspp.pdf: $(FIGURE_TEXIS) +$(top_builddir)/doc/pspp.xml: $(FIGURE_TEXIS) + +CLEANFILES += $(FIGURE_TXTS) $(FIGURE_SPVS) $(FIGURE_TEXIS) $(FIGURE_HTML) +SUFFIXES += .sps .spv .txt .html .texi .pdf # Use pspp to process a syntax file into an output file. pspp = src/ui/terminal/pspp -$(EXAMPLE_SPVS): $(pspp) +$(FIGURE_SPVS): $(pspp)$(EXEEXT) .sps.spv: $(AM_V_GEN)(cd $(top_srcdir)/examples \ - && $(abs_top_builddir)/$(pspp) ../doc/examples/$( $@.tmp + && $(abs_top_builddir)/$(pspp) ../doc/pspp-figures/$( $@.tmp $(AM_V_at)mv $@.tmp $@ -# The tutorial only wants some parts of the output here. +# In some cases, the tutorial only wants some parts of the output. pspp_output = utilities/pspp-output -doc/examples/tutorial7b.spv: doc/examples/tutorial7.spv $(pspp_output) - $(AM_V_GEN)$(pspp_output) convert --subtypes=coefficients $< $@ +convert = $(AM_V_GEN)$(pspp_output) convert $< $@ +doc/pspp-figures/tutorial2a.spv: doc/pspp-figures/tutorial2.spv $(pspp_output) + $(convert) --command='Descriptives' +doc/pspp-figures/tutorial2b.spv: doc/pspp-figures/tutorial2.spv $(pspp_output) + $(convert) --label='Extreme Values' +doc/pspp-figures/tutorial5a.spv: doc/pspp-figures/tutorial5.spv $(pspp_output) + $(convert) --commands=examine --nth-command=1 --labels=descriptives +doc/pspp-figures/tutorial5b.spv: doc/pspp-figures/tutorial5.spv $(pspp_output) + $(convert) --commands=examine --nth-command=2 --labels=descriptives +doc/pspp-figures/tutorial7a.spv: doc/pspp-figures/tutorial7.spv $(pspp_output) + $(convert) --commands=regression --nth-command=1 --subtypes=coefficients +doc/pspp-figures/tutorial7b.spv: doc/pspp-figures/tutorial7.spv $(pspp_output) + $(convert) --commands=regression --nth-command=2 --subtypes=coefficients # Convert an output file into a text file or HTML file. -# -# (For HTML, use sed to include only the contents of .) -$(EXAMPLE_OUTPUTS) $(EXAMPLE_HTML): $(pspp_output) -.spv.out: +$(FIGURE_TXTS) $(FIGURE_HTML): $(pspp_output) +.spv.txt: $(AM_V_GEN)utilities/pspp-output convert $< $@ +.spv.pdf: + $(AM_V_GEN)utilities/pspp-output convert $< $@ -O left-margin=0pt -O right-margin=0pt -O top-margin=0pt -O bottom-margin=0pt -O paper-size=6x20in -O font-size=12000 --table-look=$(HOME)/pspp/spss15/Looks/report.tlo .spv.html: - $(AM_V_GEN)utilities/pspp-output convert $< - -O format=html \ - | $(SED) -e '\% $@.tmp - $(AM_V_at)mv $@.tmp $@ + $(AM_V_GEN)utilities/pspp-output convert $< $@ -O format=html -O bare=true + +# Convert a text file into a Texinfo file. +.txt.texi: + $(AM_V_GEN)$(SED) -e 's/@/@@/g' $< > $@ -# Insert the link tag for the cascading style sheet. -# But make sure these operations are idempotent. +AM_MAKEINFOHTMLFLAGS = $(AM_MAKEINFOFLAGS) --css-ref=pspp-manual.css html-local: - for h in doc/pspp.html/*.html; do \ - if grep -Fq '/i \\\ -' $$h; \ - done install-html-local: html-local $(MKDIR_P) $(DESTDIR)$(prefix)/share/doc/pspp/pspp.html