1 # Copyright (C) 2008 Bert Burgemeister
3 # Permission is granted to copy, distribute and/or modify this
4 # document under the terms of the GNU Free Documentation License,
5 # Version 1.2 or any later version published by the Free Software
6 # Foundation; with no Invariant Sections, no Front-Cover Texts and
7 # no Back-Cover Texts. For details see file COPYING.
10 SEND-TO-LOG
= | tee
-a lastbuild.log
13 MAKEINDEX
= makeindex
-c
15 PSNUP-A4
= psnup
-W10.5cm
-H29.7cm
-pa4
-2
16 PSNUP-LETTER
= psnup
-W4.25in
-H11in
-pletter
-2
18 PSBOOK-FOUR
= psbook
-s4
26 RM
= rm --force --verbose
27 MV
= mv
--force --verbose
29 BZR_REVISION
= bzr revno | tr
-d
'\n\\'
30 BZR_EXPORT
= bzr
export
31 BZR_COMMIT
= bzr commit
32 DATE
= date
-I | tr
-d
'\n\\'
39 $(MAKE
) letter-booklets
40 $(MAKE
) $(CLQR
)-letter-consec.pdf
44 $(MAKE
) $(CLQR
)-a4-consec.pdf
46 letter-booklets
: $(CLQR
)-letter-booklet-all.pdf
$(CLQR
)-letter-booklet-four.pdf
48 a4-booklets
: $(CLQR
)-a4-booklet-all.pdf
$(CLQR
)-a4-booklet-four.pdf
50 $(CLQR
)-%-consec.pdf
: $(CLQR
)-%-consec.ps color-colorful.flag
51 $(PS2PDF
) $< $@
$(SEND-TO-LOG
)
53 $(CLQR
)-letter-booklet-
%.pdf
: $(CLQR
)-letter-booklet-
%.ps
54 $(PS2PDF
) -sPAPERSIZE
=letter
$< $@
$(SEND-TO-LOG
)
56 $(CLQR
)-a4-booklet-
%.pdf
: $(CLQR
)-a4-booklet-
%.ps
57 $(PS2PDF
) -sPAPERSIZE
=a4
$< $@
$(SEND-TO-LOG
)
59 $(CLQR
)-letter-booklet-
%.ps
: $(CLQR
)-letter-signature-
%.ps color-black.flag
60 $(PSNUP-LETTER
) $< > $@
$(SEND-TO-LOG
)
62 $(CLQR
)-a4-booklet-
%.ps
: $(CLQR
)-a4-signature-
%.ps color-black.flag
63 $(PSNUP-A4
) $< > $@
$(SEND-TO-LOG
)
65 $(CLQR
)-%-signature-all.ps
: $(CLQR
)-%-consec.ps
66 $(PSBOOK-ALL
) $< $@
$(SEND-TO-LOG
)
68 $(CLQR
)-%-signature-four.ps
: $(CLQR
)-%-consec.ps
69 $(PSBOOK-FOUR
) $< $@
$(SEND-TO-LOG
)
71 $(CLQR
)-%-consec.ps
: $(CLQR
)-%.
dvi
72 $(DVIPS
) -o
$@
$< $(SEND-TO-LOG
)
74 $(CLQR
)-%.
dvi: $(CLQR
).
tex $(CLQR
)-*.
tex paper-
%.flag color-current.
tex REVISION.
tex
75 $(TOUCH
) $(CLQR
).ind
$(SEND-TO-LOG
)
76 $(LATEX
) $(CLQR
).
tex $(SEND-TO-LOG
)
77 $(LATEX
) $(CLQR
).
tex $(SEND-TO-LOG
)
78 $(MAKEINDEX
) -s
$(CLQR
).ist
$(CLQR
).idx
$(SEND-TO-LOG
)
79 $(LATEX
) $(CLQR
).
tex $(SEND-TO-LOG
)
80 $(MV
) $(CLQR
).
dvi $@
$(SEND-TO-LOG
)
83 $(CP
) paper-a4.
tex paper-current.
tex $(SEND-TO-LOG
)
84 $(RM
) paper-letter.flag
$(SEND-TO-LOG
)
88 $(CP
) paper-letter.
tex paper-current.
tex $(SEND-TO-LOG
)
89 $(RM
) paper-a4.flag
$(SEND-TO-LOG
)
93 $(CP
) color-colorful.
tex color-current.
tex $(SEND-TO-LOG
)
94 $(RM
) color-black.flag
$(SEND-TO-LOG
)
98 $(CP
) color-black.
tex color-current.
tex $(SEND-TO-LOG
)
99 $(RM
) color-colorful.flag
$(SEND-TO-LOG
)
102 REVISION.
tex: DATE.
tex
103 if
$(BZR_REVISION
); then
$(BZR_REVISION
) > $@
; else $(TOUCH
) $@
; fi
$(SEND-TO-LOG
)
105 DATE.
tex: $(CLQR
).
tex $(CLQR
)-*.
tex
109 $(RM
) *.
dvi *.toc
*.aux
*.log
*.idx
*.ilg
*.ind
*.out
*.ps
*.pdf
*~ html
/*~
*.flag
*.jpg html
/*.jpg
*.
tar.gz
114 maintainance
: release publish
116 publish
: html
/sample-frontcover.jpg html
/sample-doublepage.jpg \
117 html
/sample-firstpage-all.jpg html
/sample-firstpage-four.jpg \
118 html
/sample-firstpage-consec.jpg html
/sample-source.jpg
$(CLQR
)-a4-consec.pdf
120 $(RSYNC
) --delete .
/ trebb@
shell.berlios.de
:/home
/groups
/ftp
/pub
/clqr
/clqr
/ $(SEND-TO-LOG
)
121 $(RSYNC
) .
/html
/ trebb@
shell.berlios.de
:/home
/groups
/clqr
/htdocs
/ $(SEND-TO-LOG
)
122 $(SSH
) trebb@
shell.berlios.de
/home
/groups
/ftp
/pub
/clqr
/clqr
/fetch-news.sh
$(SEND-TO-LOG
)
124 release
: emergency-commit letter a4
$(CLQR
).
tar.gz
127 html
/sample-frontcover.jpg
: $(CLQR
)-a4-consec.pdf
128 $(CONVERT
) $<'[0]' -verbose
-resize
30% temp.jpg
$(SEND-TO-LOG
)
129 $(MONTAGE
) temp.jpg
-tile
1x1
-geometry
+1+1 -background gray
$@
$(SEND-TO-LOG
)
132 html
/sample-doublepage.jpg
: $(CLQR
)-a4-booklet-four.pdf
133 $(CONVERT
) $<'[10]' -verbose
-resize
30% temp.jpg
$(SEND-TO-LOG
)
134 $(MONTAGE
) temp.jpg
-tile
1x1
-geometry
+1+1 -background gray
$@
$(SEND-TO-LOG
)
137 html
/sample-firstpage-
%.jpg
: $(CLQR
)-a4-booklet-
%.pdf
138 $(CONVERT
) $<'[0]' -verbose
-resize
15% temp.jpg
$(SEND-TO-LOG
)
139 $(MONTAGE
) temp.jpg
-tile
1x1
-geometry
+1+1 -background gray
$@
$(SEND-TO-LOG
)
142 html
/sample-firstpage-consec.jpg
: $(CLQR
)-a4-consec.pdf
143 $(CONVERT
) $<'[0]' -verbose
-resize
15% temp.jpg
$(SEND-TO-LOG
)
144 $(MONTAGE
) temp.jpg
-tile
1x1
-geometry
+1+1 -background gray
$@
$(SEND-TO-LOG
)
147 html
/sample-source.jpg
: $(CLQR
)-numbers.
tex
148 $(HEAD
) -n
57 $< |
$(TAIL
) -n
40 |
$(CONVERT
) -font Courier
-crop
120x80
+30+2 +repage label
:@
- temp.jpg
$(SEND-TO-LOG
)
149 $(MONTAGE
) temp.jpg
-tile
1x1
-geometry
+1+1 -background gray
$@
$(SEND-TO-LOG
)
152 emergency-commit
$(CLQR
).
tar.gz
:
153 if
$(BZR_COMMIT
) -m
"committed automatically by Makefile"; then true
; else true
; fi
$(SEND-TO-LOG
)
154 if
$(BZR_EXPORT
) $(CLQR
).
tar.gz
; then true
; else true
; fi
$(SEND-TO-LOG
)
157 $(RM
) *.ps
*~ html
/*~