diff options
author | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 14:38:37 +0200 |
---|---|---|
committer | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 14:38:37 +0200 |
commit | 067445c1487c1a73e0ee8a9ae3e82d446406ab57 (patch) | |
tree | d47aa232ce1c82cf47aa348f20902937e073239a /documentation/tools | |
download | yocto-docs-daisy.tar.gz |
initial commit for Enea Linux 4.0daisy
Migrated from the internal git server on the daisy-enea branch
Signed-off-by: Adrian Dudau <adrian.dudau@enea.com>
Diffstat (limited to 'documentation/tools')
-rw-r--r-- | documentation/tools/eclipse-help.sed | 18 | ||||
-rw-r--r-- | documentation/tools/mega-manual.sed | 14 | ||||
-rwxr-xr-x | documentation/tools/poky-docbook-to-pdf | 51 |
3 files changed, 83 insertions, 0 deletions
diff --git a/documentation/tools/eclipse-help.sed b/documentation/tools/eclipse-help.sed new file mode 100644 index 0000000..38690bc --- /dev/null +++ b/documentation/tools/eclipse-help.sed | |||
@@ -0,0 +1,18 @@ | |||
1 | # Processes poky-ref-manual and yocto-project-qs manual (<word>-<word>-<word> style) | ||
2 | # For example: | ||
3 | # "ulink" href="http://www.yoctoproject.org/docs/1.3/poky-ref-manual/poky-ref-manual.html#faq" | ||
4 | # -> "link" href="../poky-ref-manual/faq.html" | ||
5 | s/\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/[^\/]*\/\([a-z]*-[a-z]*-[a-z]*\)\/[a-z]*-[a-z]*-[a-z]*.html#\([^\"]*\)\"/\"link\" href=\"\.\.\/\1\/\2.html\"/g | ||
6 | |||
7 | # Processes all other manuals (<word>-<word> style) | ||
8 | # For example: | ||
9 | # "ulink" href="http://www.yoctoproject.org/docs/1.3/kernel-manual/kernel-manual.html#faq" | ||
10 | # -> "link" href="../kernel-manual/faq.html" | ||
11 | s/\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/[^\/]*\/\([a-z]*-[a-z]*\)\/[a-z]*-[a-z]*.html#\([^\"]*\)\"/\"link\" href=\"\.\.\/\1\/\2.html\"/g | ||
12 | |||
13 | # Process cases where just an external manual is referenced without an id anchor | ||
14 | # For example: | ||
15 | # "ulink" href="http://www.yoctoproject.org/docs/1.3/kernel-manual/kernel-manual.html | ||
16 | # -> "link" href="../kernel-manual/index.html" | ||
17 | s/\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/[^\/]*\/\([a-z]*-[a-z]*-[a-z]*\)\/[a-z]*-[a-z]*-[a-z]*.html\"/\"link\" href=\"\.\.\/\1\/index.html\"/g | ||
18 | s/\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/[^\/]*\/\([a-z]*-[a-z]*\)\/[a-z]*-[a-z]*.html\"/\"link\" href=\"\.\.\/\1\/index.html\"/g | ||
diff --git a/documentation/tools/mega-manual.sed b/documentation/tools/mega-manual.sed new file mode 100644 index 0000000..69a5b82 --- /dev/null +++ b/documentation/tools/mega-manual.sed | |||
@@ -0,0 +1,14 @@ | |||
1 | # Processes ref-manual and yocto-project-qs manual (<word>-<word>-<word> style) | ||
2 | s/\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/[a-z]*-[a-z]*-[a-z]*\/[a-z]*-[a-z]*-[a-z]*.html#/\"link\" href=\"#/g | ||
3 | |||
4 | # Processes all other manuals (<word>-<word> style) | ||
5 | s/\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/[a-z]*-[a-z]*\/[a-z]*-[a-z]*.html#/\"link\" href=\"#/g | ||
6 | |||
7 | # Process cases where just an external manual is referenced without an id anchor | ||
8 | s/<a class=\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/yocto-project-qs\/yocto-project-qs.html\" target=\"_top\">Yocto Project Quick Start<\/a>/Yocto Project Quick Start/g | ||
9 | s/<a class=\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/dev-manual\/dev-manual.html\" target=\"_top\">Yocto Project Development Manual<\/a>/Yocto Project Development Manual/g | ||
10 | s/<a class=\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/adt-manual\/adt-manual.html\" target=\"_top\">Yocto Project Application Developer's Guide<\/a>/Yocto Project Application Developer's Guide/g | ||
11 | s/<a class=\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/bsp-guide\/bsp-guide.html\" target=\"_top\">Yocto Project Board Support Package (BSP) Developer's Guide<\/a>/Yocto Project Board Support Package (BSP) Developer's Guide/g | ||
12 | s/<a class=\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/profile-manual\/profile-manual.html\" target=\"_top\">Yocto Project Profiling and Tracing Manual<\/a>/Yocto Project Profiling and Tracing Manual/g | ||
13 | s/<a class=\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/kernel-dev\/kernel-dev.html\" target=\"_top\">Yocto Project Linux Kernel Development Manual<\/a>/Yocto Project Linux Kernel Development Manual/g | ||
14 | s/<a class=\"ulink\" href=\"http:\/\/www.yoctoproject.org\/docs\/1.7\/ref-manual\/ref-manual.html\" target=\"_top\">Yocto Project Reference Manual<\/a>/Yocto Project Reference Manual/g | ||
diff --git a/documentation/tools/poky-docbook-to-pdf b/documentation/tools/poky-docbook-to-pdf new file mode 100755 index 0000000..f55fd27 --- /dev/null +++ b/documentation/tools/poky-docbook-to-pdf | |||
@@ -0,0 +1,51 @@ | |||
1 | #!/bin/sh | ||
2 | |||
3 | if [ -z "$1" -o -z "$2" ]; then | ||
4 | echo "usage: [-v] $0 <docbook file> <templatedir>" | ||
5 | echo | ||
6 | echo "*NOTE* you need xsltproc, fop and nwalsh docbook stylesheets" | ||
7 | echo " installed for this to work!" | ||
8 | echo | ||
9 | exit 0 | ||
10 | fi | ||
11 | |||
12 | FO=`echo $1 | sed s/.xml/.fo/` || exit 1 | ||
13 | PDF=`echo $1 | sed s/.xml/.pdf/` || exit 1 | ||
14 | TEMPLATEDIR=$2 | ||
15 | |||
16 | ## | ||
17 | # These URI should be rewritten by your distribution's xml catalog to | ||
18 | # match your localy installed XSL stylesheets. | ||
19 | XSL_BASE_URI="http://docbook.sourceforge.net/release/xsl/current" | ||
20 | |||
21 | # Creates a temporary XSL stylesheet based on titlepage.xsl | ||
22 | xsltproc -o /tmp/titlepage.xsl \ | ||
23 | --xinclude \ | ||
24 | $XSL_BASE_URI/template/titlepage.xsl \ | ||
25 | $TEMPLATEDIR/titlepage.templates.xml || exit 1 | ||
26 | |||
27 | # Creates the file needed for FOP | ||
28 | xsltproc --xinclude \ | ||
29 | --stringparam hyphenate false \ | ||
30 | --stringparam formal.title.placement "figure after" \ | ||
31 | --stringparam ulink.show 1 \ | ||
32 | --stringparam body.font.master 9 \ | ||
33 | --stringparam title.font.master 11 \ | ||
34 | --stringparam draft.watermark.image "$TEMPLATEDIR/draft.png" \ | ||
35 | --stringparam chapter.autolabel 1 \ | ||
36 | --stringparam appendix.autolabel A \ | ||
37 | --stringparam section.autolabel 1 \ | ||
38 | --stringparam section.label.includes.component.label 1 \ | ||
39 | --output $FO \ | ||
40 | $TEMPLATEDIR/poky-db-pdf.xsl \ | ||
41 | $1 || exit 1 | ||
42 | |||
43 | # Invokes the Java version of FOP. Uses the additional configuration file common/fop-config.xml | ||
44 | fop -c $TEMPLATEDIR/fop-config.xml -fo $FO -pdf $PDF || exit 1 | ||
45 | |||
46 | rm -f $FO | ||
47 | rm -f /tmp/titlepage.xsl | ||
48 | |||
49 | echo | ||
50 | echo " #### Success! $PDF ready. ####" | ||
51 | echo | ||