Debian Codegraph @

doc/sty/Makefile

raw
1 #
2 # Copyright (C) 2011-2025 Alexis Bienvenüe <[email protected]>
3 #
4 # This file is part of Auto-Multiple-Choice
5 #
6 # Auto-Multiple-Choice is free software: you can redistribute it
7 # and/or modify it under the terms of the GNU General Public License
8 # as published by the Free Software Foundation, either version 2 of
9 # the License, or (at your option) any later version.
10 #
11 # Auto-Multiple-Choice is distributed in the hope that it will be
12 # useful, but WITHOUT ANY WARRANTY; without even the implied warranty
13 # of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 # General Public License for more details.
15 #
16 # You should have received a copy of the GNU General Public License
17 # along with Auto-Multiple-Choice. If not, see
18 # <http://www.gnu.org/licenses/>.
19
20 SHELL=/bin/sh
21
22 include ../../Makefile-all.conf
23
24 PACK=automultiplechoice
25
26 SAMPLES=$(wildcard sample-*.tex)
27
28 all %.pdf: export SOURCE_DATE_EPOCH=$(PACKAGE_V_EPOCH)
29 all %.pdf: export SOURCE_DATE_EPOCH_TEX_PRIMITIVES=1
30 all %.pdf: export FORCE_SOURCE_DATE=1
31
32 PDFLATEX=pdflatex -halt-on-error -interaction=nonstopmode
33 all: FORCE
34 $(PDFLATEX) $(PACK).dtx
35 $(MAKE) $(SAMPLES:.tex=.pdf)
36 $(PDFLATEX) $(PACK).dtx
37 makeindex -s gglo.ist -o $(PACK).gls $(PACK).glo
38 makeindex -s gind.ist -o $(PACK).ind $(PACK).idx
39 $(PDFLATEX) $(PACK).dtx
40 $(PDFLATEX) $(PACK).dtx
41 ./get-subxy.pl
42 $(PDFLATEX) $(PACK).dtx
43 $(MAKE) postclean
44
45 styonly: $(PACK).dtx
46 $(PDFLATEX) $<
47 $(MAKE) postclean
48
49 sample-%.datetex.in: sample-%.tex
50 $(PERLPATH) -pe 's!\\begin\{document\}!\\begin{document}\\pdfinfo{/CreationDate (D:@/PACKAGE_V_PDFDATE/@) /ModDate (D:@/PACKAGE_V_PDFDATE/@)}!;' < $< > $@
51
52 sample-%.datetex: sample-%.datetex.in
53 $(MAKE) -C ../.. doc/sty/$@
54
55 sample-%.pdf: sample-%.datetex
56 pdflatex -jobname sample-$* $<
57
58 postclean:
59 -rm -f pexa-*
60 -rm -f $(foreach ext,amc aux dvi glo gls idx ilg ind log out toc xy xy1 xy2 xy3 hd tmp,*.$(ext))
61
62 clean: postclean
63 rm -f *~
64 rm -f $(PACK).sty
65 rm -f *.pdf
66
67 FORCE: ;
68
69 .PHONY: all clean postclean FORCE