File: README

package info (click to toggle)
publican 2.8-3
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 5,404 kB
  • sloc: xml: 8,372; perl: 7,501; makefile: 34; sh: 6
file content (138 lines) | stat: -rw-r--r-- 3,354 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
# BUGBUG 2.2 web site changes

1: rebuild home pages!
2:

ALTER TABLE main.books ADD COLUMN subtitle text;
ALTER TABLE main.books ADD COLUMN abstract text;
drop table settings;

Common files and scripts for building Red Hat documentation.

Assumptions: DocBook xml, *nix, en-US source language.

Q: What actions are there?

A: publican --help

Q: How do I update the POT files for translation?

A: publican update_pot

Q: How do I add a language?

A: publican update_po --langs=<xx-YY>

This will create the language directory and the language specific po files.

Q: How do I update all po files?

A: publican update_po --langs=all

Q: What Book specific options can I use?

A: publican --help_config

Q: Where are the common files located?

A: By default they are in /usr/share/publican

Q: How do I profile publican?

A: Devel::NYTProf is a good option.

$ perl -d:NYTProf /usr/bin/publican build --langs en-US --formats html
$ nytprofhtml
$ firefox nytprof/index.html 

Q: How do I build publican from source?

A: It depends on your platform.

Get the source: svn co http://svn.fedorahosted.org/svn/publican/trunk/publican

Perl
    cd publican
TODO: deps
    perl Build.PL
    ./Build
    ./Build test
    ./Build install

RHEL/Fedora
    cd publican
TODO: deps
    perl Build.PL
    ./Build rpm

Debian
    The publican package deb files are in the debian package repo
    http://packages.debian.org/search?keywords=publican
    cd publican
    sudo apt-get install \
libfile-pushd-perl \
libconfig-simple-perl \
libxml-treebuilder-perl \
libfile-find-rule-perl \
libmakefile-parser-perl \
liblocale-maketext-gettext-perl \
perlmagick \
libimage-size-perl \
libdatetime-perl \
liblocale-po-perl \
libxml-libxslt-perl \
libdatetime-format-dateparse-perl \
libsyntax-highlight-engine-kate-perl \
libtest-perl-critic-perl \
libtest-pod-coverage-perl \
libtest-exception-perl \
libdbd-sqlite-perl \
libdevel-cover-perl \
libdbd-sqlite3-perl

    ./Build dist
TODO: put the tgz where?
    debuild

Windows
    Install Perl http://www.activestate.com/activeperl/
TODO: deps
    Install NSIS http://nsis.sourceforge.net/Download
    Install http://nsis.sourceforge.net/Environmental_Variables:_append,_prepend,_and_remove_entries
    http://nsis.sourceforge.net/NsUnzip_plugin
    
    cd publican
    perl Build.PL
    Build
    Build test
    perl win_build.pl
    compile publican.nsi in NSIS

    C:\Perl\lib\HTML\Element.pm patch from cpan
    XML-TreeBuilder patch
    Image::Magick <--- how to get this *&^*% working?
    
TODO: detail building xml2

TODO: Complete details on building required LibXML and LibXSLT modules

    vcvars32.bat

    perl Makefile.PL INC=-ID:\Data\temp\Redhat\xml2\include LIBS=-LD:\Data\temp\Redhat\xml2\lib
    nmake
    copy D:\Data\temp\Redhat\xml2\bin\*.dll blib\arch\auto\XML\LibXML
    nmake test
    nmake install

    perl Makefile.PL INC=-ID:\Data\temp\Redhat\xml2\include LIBS=-LD:\Data\temp\Redhat\xml2\lib
    nmake
    copy D:\Data\temp\Redhat\xml2\libxslt-1.1.24.win32\bin\*.dll blib\arch\auto\XML\LibXSLT
    nmake test
    nmake install

    
TODO: what about a real list of valid langauges?

	wget http://www.iana.org/assignments/language-subtag-registry

	grep -A 1 -B 0 -P '^Type: (language|redundant)' language-subtag-registry | grep -P '^(Subtag|Tag)' | perl -p -e 's/^(Subtag|Tag):\s*//gi' | wc -l