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
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
|
<html>
<head>
<title>The XML C library for Gnome</title>
<meta name="GENERATOR" content="amaya V4.1">
<meta http-equiv="Content-Type" content="text/html">
</head>
<body bgcolor="#ffffff">
<p><a href="http://www.gnome.org/"><img src="smallfootonly.gif"
alt="Gnome Logo"></a><a href="http://www.redhat.com"><img src="redhat.gif"
alt="Red Hat Logo"></a></p>
<h1 align="center">The XSLT C library for Gnome</h1>
<h1 style="text-align: center">libxslt</h1>
<p></p>
<ul>
<li><a href="#Introducti">Introduction</a></li>
<li><a href="#Documentat">Documentation</a></li>
<li><a href="#Reporting">Reporting bugs and getting help</a></li>
<li><a href="#help">how to help</a></li>
<li><a href="#Downloads">Downloads</a></li>
<li><a href="#News">News</a></li>
<li><a href="#XML">The xsltproc command</a></li>
<li><a href="#XSLT">The programming API</a></li>
</ul>
<h2><a name="Introducti">Introduction</a></h2>
<p>This document describes <a href="http://xmlsoft.org/XSLT/">libxslt</a>, the
<a href="http://www.w3.org/TR/xslt">XSLT</a> C library developped for the <a
href="http://www.gnome.org/">Gnome</a> project.</p>
<p>Here are some key points about libxslt:</p>
<ul>
<li>Libxslt is a C implementation</li>
<li>Libxslt is based on libxml for XML parsing, tree manipulation and XPath
support</li>
<li>It is written in plain C, making as few assumptions as possible, and
sticking closely to ANSI C/POSIX for easy embedding. Should works on
Linux/Unix/Windows.</li>
<li>This library is released under the <a
href="http://www.gnu.org/copyleft/lesser.html">GNU LGPL</a>. If you are
not happy with this, drop me a mail.</li>
<li>Though not designed primarily with performances in mind, libxslt seems
to be a relatively fast processor.</li>
</ul>
<h2><a name="Documentat">Documentation</a></h2>
<p>There are some on-line resources about using libxslt:</p>
<ol>
<li>Check the <a href="html/libxslt-lib.html#LIBXSLT-LIB">API
documentation</a> automatically extracted from code comments (using <a
href="http://cvs.gnome.org/bonsai/rview.cgi?cvsroot=/cvs/gnome&dir=gtk-doc">gtk
doc</a>).</li>
<li>Look at the <a href="/messages/">mailing-list archive</a>.</li>
<li>Of course since libxslt is based on libxml, it's a good idea to at least
read <a href="http://xmlsoft.org/">libxml description</a></li>
</ol>
<h2><a name="Reporting">Reporting bugs and getting help</a></h2>
<p>Well, bugs or missing features are always possible, and I will make a point
of fixing them in a timely fashion. The best way to report a bug is to use the
<a href="http://bugzilla.gnome.org/buglist.cgi?product=libxslt">Gnome bug
tracking database</a> (make sure to use the "libxslt" module name). I look at
reports there regularly and it's good to have a reminder when a bug is still
open. Check the <a href="http://bugs.gnome.org/Reporting.html">instructions on
reporting bugs</a> and be sure to specify that the bug is for the package
libxslt.</p>
<p>There is also a mailing-list <a
href="mailto:xslt@gnome.org">xslt@gnome.org</a> for libxslt, with an <a
href="http://xmlsoft.org/messages">on-line archive</a>. To subscribe to this
list, please visit the <a
href="http://mail.gnome.org/mailman/listinfo/xslt">associated Web</a> page and
follow the instructions.</p>
<p>Alternatively, you can just send the bug to the <a
href="mailto:xslt@gnome.org">xslt@gnome.org</a> list, if it's really libxslt
related I will approve it..</p>
<p>Of course, bugs reports with a suggested patch for fixing them will
probably be processed faster.</p>
<p>If you're looking for help, a quick look at <a
href="http://xmlsoft.org/messages/#407">the list archive</a> may actually
provide the answer, I usually send source samples when answering libxml usage
questions. The <a href="html/libxslt-lib.html#LIBXSLT-LIB">auto-generated
documentation</a> is not as polished as I would like (I need to learn more
about Docbook), but it's a good starting point.</p>
<h2><a name="help">How to help</a></h2>
<p>You can help the project in various ways, the best thing to do first is to
subscribe to the mailing-list as explained before, check the <a
href="http://xmlsoft.org/messages/">archives </a>and the <a
href="http://bugs.gnome.org/db/pa/lgnome-xml.html">Gnome bug
database:</a>:</p>
<ol>
<li>provide patches when you find problems</li>
<li>provide the diffs when you port libxslt to a new platform. They may not
be integrated in all cases but help pinpointing portability problems
and</li>
<li>provice documentation fixes (either as patches to the code comments or
as HTML diffs).</li>
<li>provide new documentations pieces (translations, examples, etc ...)</li>
<li>Check the TODO file and try to close one of the items</li>
<li>take one of the points raised in the archive or the bug database and
provide a fix. <a href="mailto:Daniel.Veillard@imag.fr">Get in touch with
me </a>before to avoid synchronization problems and check that the
suggested fix will fit in nicely :-)</li>
</ol>
<h2><a name="Downloads">Downloads</a></h2>
<p>The latest versions of libxslt can be found on <a
href="ftp://xmlsoft.org/">xmlsoft.org</a> or on the <a
href="ftp://ftp.gnome.org/pub/GNOME/MIRRORS.html">Gnome FTP server</a> either
as a <a href="ftp://ftp.gnome.org/pub/GNOME/unstable/sources/libxml/">source
archive</a> or <a
href="ftp://ftp.gnome.org/pub/GNOME/contrib/redhat/SRPMS/">RPM packages</a>.
(NOTE that you need the <a
href="http://rpmfind.net/linux/RPM/libxml2.html">libxml2</a>, <a
href="http://rpmfind.net/linux/RPM/libxml2-devel.html">libxml2-devel</a>, <a
href="http://rpmfind.net/linux/RPM/libxslt.html">libxslt</a> and <a
href="http://rpmfind.net/linux/RPM/libxslt-devel.html">libxslt-devel</a>
packages installed to compile applications using libxslt.)</p>
<p><a name="Contribs">Contribs:</a></p>
<p>I do accept external contributions, especially if compiling on another
platform, get in touch with me to upload the package. I will keep them in the
<a href="ftp://xmlsoft.org/contribs/">contrib directory</a></p>
<p>Libxslt is also available from CVS:</p>
<ul>
<li><p>The <a
href="http://cvs.gnome.org/bonsai/rview.cgi?cvsroot=/cvs/gnome&dir=libxslt">Gnome
CVS base</a>. Check the <a
href="http://developer.gnome.org/tools/cvs.html">Gnome CVS Tools</a> page;
the CVS module is <b>libxslt</b>.</p>
</li>
</ul>
<h2><a name="News">News</a></h2>
<h3>CVS only : check the <a
href="http://cvs.gnome.org/lxr/source/libxslt/ChangeLog">Changelog</a> file
for a really accurate description</h3>
<h3>0.5.0: Mar 10 2001</h3>
<ul>
<li>fifth beta</li>
<li>some optimization work, for the moment 2 XSLT transform cannot use the
same stylesheet at the same time (to be fixed)</li>
<li>fixed problems with handling of tree results</li>
<li>fixed a reported strip-spaces problem</li>
<li>added more reported/fixed bugs to the test suite</li>
<li>incorporated William M. Brack fix for imports and global variables as
well as patch for with-param support in apply-templates</li>
<li>a bug fix on for-each</li>
</ul>
<h3>0.4.0: Mar 1 2001</h3>
<ul>
<li>fourth beta test, released at the same time of libxml2-2.3.3</li>
<li>bug fixes</li>
<li>some optimization</li>
<li>started implement extension support, not finished</li>
<li>implemented but not tested multiple file output</li>
</ul>
<h3>0.3.0: Feb 24 2001</h3>
<ul>
<li>third beta test, released at the same time of libxml2-2.3.2</li>
<li>lot of bug fixes</li>
<li>some optimization</li>
<li>added DocBook XSL based testsuite</li>
</ul>
<h3>0.2.0: Feb 15 2001</h3>
<ul>
<li>second beta version, released at the same time as libxml2-2.3.1</li>
<li>getting close to feature completion, lot of bug fixes, some in the HTML
and XPath support of libxml</li>
<li>start becoming usable for real work. This version can now regenerate the
XML 2e HTML from the original XML sources and the associated stylesheets
(in <a href="http://www.w3.org/TR/REC-xml#b4d250b6c21">section I of the
XML REC</a>)</li>
<li>Still misses extension element/function/prefixes support. Support of
key() and document() is not complete</li>
</ul>
<h3>0.1.0: Feb 8 2001</h3>
<ul>
<li>first beta version, released at the same time as libxml2-2.3.0</li>
<li>lots of bug fixes, first "testing" version, but incomplete</li>
</ul>
<h3>0.0.1: Jan 25 2001</h3>
<ul>
<li>first alpha version released at the same time as libxml2-2.2.12</li>
<li>Framework in place, should work on simple examples, but far from being
feature complete</li>
</ul>
<h2>The xsltproc command</h2>
<p>This program is the simplest way to use libxslt from the command line, it
takes as first argument the path or URL to an XSLT stylesheet. the next
arguments are filenames or URIs of the inputs to be processed. The output of
the processing is redirected on the standard output.</p>
<h2>The programming API</h2>
<p>Okay this section is clearly incomplete. But integrating libxslt into your
application should be realitively easy. First check the few steps described
below, then for more detailed informations, look at the<a
href="libxslt-lib.html"> generated pages</a> for the API and the source of
xsltproc.c .</p>
<p>Basically doing an XSLT transformation can be done in a few steps:</p>
<ol>
<li>configure the parser for XSLT:
<p>xmlSubstituteEntitiesDefault(1);</p>
<p>xmlLoadExtDtdDefaultValue = 1;</p>
</li>
<li>parse the stylesheet with xsltParseStylesheetFile()</li>
<li>parse the document with xmlParseFile()</li>
<li>apply the stylesheet using xsltApplyStylesheet()</li>
<li>save the result using xsltSaveResultToFile() if needed set
xmlIndentTreeOutput to 1</li>
</ol>
<p>Steps 2,3, and 5 will probably need to be changed depending on you
processing needs and environment for example if reading/saving from/to memory,
or if you want to apply XInclude processing to the stylesheet or input
documents.</p>
<h2><a name="Contributi">Contributions</a></h2>
<ul>
<li>Bjorn Reese is the author of the number support</li>
</ul>
<p></p>
<p><a href="mailto:Daniel.Veillard@imag.fr">Daniel Veillard</a></p>
<p>$Id$</p>
</body>
</html>
|