Paste #tMcOyxWCYEhyXy5oULhz

=== modified file 'Makefile'
Makefile [2015-07-22 22:00:36 +0000]
Makefile [2015-07-27 23:27:56 +0000]
10 10 # All available translations
11 11 TRANSALL = $(shell basename -s .po -a desktop-guide/po/*.po)
12 12
13 all: clean startpage html translate
13 all: clean startpage html html-translations pdf pdf-translations
14 14
15 15 startpage: get-translations
16 16 mkdir -p build
55 55 pdf:
56 56 $(MAKE) -C desktop-guide pdf
57 57
58 translate: get-translations
58 translate:
59 59 $(MAKE) -C desktop-guide translate
60 60
61 translate-pdf: get-translations
62 $(MAKE) -C desktop-guide translate-pdf
63
64 test: get-translations
61 html-translations:
62 $(MAKE) -C desktop-guide html-translations
63
64 pdf-translations:
65 $(MAKE) -C desktop-guide pdf-translations
66
67 test:
65 68 $(MAKE) -C desktop-guide test
66 69
67 70 src-tarball:
68 # exclude archive, backup, and bzr files
69 tar cvfz xubuntu-doc.tar.gz --exclude="*.tar.gz" --exclude="*~" --exclude "*.bzr*" *
71 # exclude archive, VCS, and backups
72 tar -czf xubuntu-docs.tar.gz --exclude='xubuntu-docs.tar.gz' --exclude-vcs --exclude-backups .
70 73
71 74 clean:
72 75 $(MAKE) -C desktop-guide clean
73 rm -rf build
76 rm -rf build xubuntu-docs.tar.gz
74 77
75 78 .PHONY: startpage
desktop-guide/Makefile [2015-07-22 22:00:36 +0000]
desktop-guide/Makefile [2015-07-27 23:17:56 +0000]
8 8 # All available translations
9 9 TRANSALL = $(shell basename -s .po -a po/*.po)
10 10
11 all: clean html translate
11 all: clean html html-translations pdf pdf-translations
12 12
13 html: style
14 printf "<itemizedlist>\n\t<listitem><para>Attributed on each translation's page.</para></listitem>\n</itemizedlist>\n" > C/translators.xml
13 html: C/translators.xml style
15 14 xsltproc --xinclude -o ../build/C/index.html $(XUBUNTUXSL_HTML) C/index.xml
16 15 sed -i 's@\(<p>The contributors to\) this translation of the \(documentation are:</p>\)@\1 the various translations of this \2@' ../build/C/credits-license.html
17 16
18 epub: epubstyle
19 printf "<itemizedlist>\n\t<listitem><para>Attributed on each translation's page.</para></listitem>\n</itemizedlist>\n" > C/translators.xml
17 epub: C/translators.xml style-epub
20 18 xsltproc --xinclude -o ../build/C/ /usr/share/xml/docbook/stylesheet/nwalsh/epub3/chunk.xsl C/index.xml
21 19 sed -i 's@\(<p>The contributors to\) this translation of the \(documentation are:</p>\)@\1 the various translations of this \2@' ../build/C/credits-license.html
22 20 cd ../build/C; \
23 21 zip -0Xq xubuntu-docs.epub mimetype; \
24 22 zip -Xr9Dq xubuntu-docs.epub *
25 23
26 pdf:
27 printf "<itemizedlist>\n\t<listitem><para>Attributed on each translation's page.</para></listitem>\n</itemizedlist>\n" > C/translators.xml
28 xsltproc --stringparam paper.type "A4" --xinclude -o fo/C-A4.fo $(XUBUNTUXSL_PDF) C/index.xml
24 pdf: C/translators.xml
25 xsltproc --stringparam paper.type A4 --xinclude -o fo/C-A4.fo $(XUBUNTUXSL_PDF) C/index.xml
29 26 sed -i 's@\(>The contributors to\) this translation of the \(documentation are:</\)@\1 the various translations of this \2@' fo/C-A4.fo
30 27 mkdir -p ../build/C
31 28 fop -c libs/xubuntu-docbook-pdf-fonts.xml fo/C-A4.fo -pdf ../build/C/xubuntu-documentation-A4.pdf
32 29 sed 's@\(page-width\)="[^"]*" \(page-height\)="[^"]*"@\1="8.5in" \2="11in"@g' fo/C-A4.fo > fo/C-USletter.fo
33 30 fop -c libs/xubuntu-docbook-pdf-fonts.xml fo/C-USletter.fo -pdf ../build/C/xubuntu-documentation-USletter.pdf
34 31
32 C/translators.xml:
33 printf "<itemizedlist>\n\t<listitem><para>Attributed on each translation's page.</para></listitem>\n</itemizedlist>\n" > C/translators.xml
34
35 35 style:
36 36 mkdir -p ../build/libs
37 37 cp -r libs/*.css \
39 39 libs/admon \
40 40 libs/navig \
41 41 ../build/libs/
42 @touch style
42 43
43 epubstyle:
44 style-epub:
44 45 mkdir -p ../build/C/libs/images
45 46 cp libs/images/preferences-desktop.png \
46 47 libs/images/system-lock-screen.png \
51 52 libs/images/key_icon.png \
52 53 ../build/C/libs/images/
53 54
54 translate: get-translations
55 translate: | get-translations
55 56 ../scripts/translate.sh $(TRANSOPTS)
56 57 ../scripts/translators.sh $(TRANSOPTS)
58 @touch translate
59
60 html-translations: style translate
57 61 for dir in $(TRANSLATIONS); do \
58 62 xsltproc --xinclude -o ../build/$$dir/index.html $(XUBUNTUXSL_HTML) $$dir/index.xml; \
59 63 done
60 64
61 translate-pdf: get-translations
62 ../scripts/translate.sh $(TRANSOPTS)
63 ../scripts/translators.sh $(TRANSOPTS)
65 pdf-translations: translate
64 66 for dir in $(TRANSLATIONS); do \
65 xsltproc --stringparam paper.type "A4" --xinclude -o fo/$$dir-A4.fo $(XUBUNTUXSL_PDF) $$dir/index.xml; \
67 xsltproc --stringparam paper.type A4 --xinclude -o fo/$$dir-A4.fo $(XUBUNTUXSL_PDF) $$dir/index.xml; \
66 68 mkdir -p ../build/$$dir; \
67 69 fop -c libs/xubuntu-docbook-pdf-fonts.xml fo/$$dir-A4.fo -pdf ../build/$$dir/xubuntu-documentation-A4.pdf; \
68 70 sed 's@\(page-width\)="[^"]*" \(page-height\)="[^"]*"@\1="8.5in" \2="11in"@g' fo/$$dir-A4.fo > fo/$$dir-USletter.fo; \
69 71 fop -c libs/xubuntu-docbook-pdf-fonts.xml fo/$$dir-USletter.fo -pdf ../build/$$dir/xubuntu-documentation-USletter.pdf; \
70 72 done
71 73
72 test: get-translations
74 test: C/translators.xml translate
73 75 set -e; \
74 76 for dir in C $(TRANSLATIONS); do \
75 77 ../scripts/validate.sh $$dir/index.xml; \
98 100 endif
99 101
100 102 clean:
101 rm -rf $(TRANSALL) C/translators.xml fo/
103 rm -rf ../build C/translators.xml $(TRANSALL) fo style translate