"Fossies" - the Fresh Open Source Software Archive

Member "redland/raptor/INSTALL.html" (19 Jun 2009, 7717 Bytes) of archive /windows/www/amaya-fullsrc-11.4.4.tgz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) HTML source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 <?xml version="1.0" encoding="iso-8859-1"?>
    2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    3 <html xmlns="http://www.w3.org/1999/xhtml">
    4 <head>
    5   <title>Raptor RDF Parser Toolkit - Installation</title>
    6 </head>
    7 <body>
    8 
    9 <h1 style="text-align:center">Raptor RDF Parser Toolkit - Installation</h1>
   10 <h2 style="text-align:center"><a href="http://purl.org/net/dajobe/">Dave Beckett</a><br /><a href="http://www.ilrt.bristol.ac.uk/">Institute for Learning and Research Technology</a><br /><a href="http://www.bristol.ac.uk/">University of Bristol</a></h2>
   11   
   12 
   13 <h2>1. Getting the sources</h2>
   14 
   15 <h2>1.1 Getting the sources from releases</h2>
   16 
   17 <p>The sources are available from
   18 <a href="http://www.redland.opensource.ac.uk/dist/source/">http://www.redland.opensource.ac.uk/dist/source/</a> (master site) and also from the
   19 <a href="http://sourceforge.net/projects/librdf/">SourceForge site</a>.</p>
   20 
   21 
   22 <h2>1.2 Getting the sources from CVS</h2>
   23 
   24 <p>Note that using this rather than the bundles may require having
   25 some extra development tools.  Presently this includes the gperf
   26 tool.</p>
   27 
   28 <pre>
   29   # sh, bash, ...
   30   CVSROOT=:pserver:anonymous@cvs.ilrt.org:/cvsroot
   31   export CVSROOT
   32   # csh, tcsh, ...
   33   setenv CVSROOT :pserver:anonymous@cvs.ilrt.org:/cvsroot
   34 
   35   cvs login
   36 Logging in to :pserver:anonymous@cvs.ilrt.org:2401/cvsroot
   37 CVS password: 
   38   [return]
   39 
   40   cvs checkout redland/raptor
   41 
   42   cd redland/raptor
   43 </pre>
   44 
   45 <p>At this stage, or after a <tt>cvs update</tt> you will
   46 need to create the automake and autoconf derived files, as described
   47 below in <em>create the configure program</em>
   48 by using the <tt>autogen.sh</tt> script.</p>
   49 
   50 
   51 
   52 <h2>2. Configuring and building</h2>
   53 
   54 <p>Raptor uses the GNU automake and autoconf to handle system
   55 dependency checking.  It requires an XML parser - either libxml2
   56 (2.4.0 or newer, 2.5.0 or later recommended) or expat.  It will
   57 optionally use libcurl, libxml2 for retrieving URIs.  If GNOME glib
   58 2.0 is present, it will be used for Unicode Normal Form C (NFC)
   59 checking.  If it is missing, some of the tests will note failure.</p>
   60 
   61 <p>Raptor is developed and built on x86 GNU/Linux
   62 (Redhat 9, Debian unstable) but is also regularly tested on
   63 sparc Sun Solaris 2.x, x86 FreeBSD 4.8, ppc Apple OSX 10.2 
   64 and as part of Redland on several other systems via the 
   65 <a href="http://sourceforge.net/">SourceForge</a> compile farm
   66 (AMD IA64 SuSE 8 Linux 2.4, Alpha Debian Linux 2.2).</p>
   67 
   68 <h3>2.1. Create <tt>configure</tt> program</h3>
   69 
   70 <p>If there is no <tt>configure</tt> program, you can create it 
   71 using the <tt>autogen.sh</tt> script, as long as you have the
   72 <a href="http://www.gnu.org/software/automake/automake.html">automake</a> and
   73 <a href="http://www.gnu.org/software/autoconf/autoconf.html">autoconf</a>
   74 tools.  Alternatively you can run them by hand with:</p>
   75 <pre>
   76   aclocal; autoheader; automake --add-missing; autoconf
   77 </pre>
   78 
   79 <p>The automake and autoconf tools have many different versions and
   80 at present Raptor is being developed with automake 1.6.3 (minimum
   81 version 1.6), autoconf 2.57 (minimum version 2.52) and libtool 1.4.2a
   82 (minimum version 1.4).  These are only needed when compiling from CVS
   83 sources.  It is expected that development will move to require
   84 automake 1.7, autoconf 2.57 and libtool 1.4.3.</p>
   85 
   86 
   87 <h3>2.2 Options for <tt>configure</tt></h3>
   88 
   89 <p>Raptor also supports the following extra configure options:</p>
   90 
   91 <dl>
   92 <dt><tt>--with-xml-parser=NAME</tt><br /></dt>
   93 <dd><p>Pick an XML parser to use - either <tt>libxml</tt> (default)
   94 minimum version 2.4.0 or <tt>expat</tt>.  If this option is not given,
   95 either will be used, with libxml preferred if both are present.
   96 These can either be installed system libraries or source
   97 trees in subdirectories of these sources named libxml, expat.</p>
   98 <p>Raptor has been tested with various combinations of these libraries
   99 including 
  100 expat 1.95.1 (on RedHat 7.2),
  101 expat 1.95.2-2 (on RedHat 7.3),
  102 expat 1.95.2-6 (on Debian 3.0),
  103 libxml 2.4.10 (on RedHat 7.2),
  104 libxml 2.4.13 (on OSX 10.1.5),
  105 libxml 2.4.17 (on FreeBSD 4.5-RELEASE-p2),
  106 libxml 2.4.19 (on RedHat 7.2),
  107 libxml 2.4.23 (on Debian 3.0),
  108 libxml 2.4.24 (on FreeBSD 4.7-STABLE),
  109 libxml 2.4.25, 2.4.28, 2.4.30 (Debian unstable),
  110 libxml 2.5.3-2.5.4 (Redhat 9, Debian unstable),
  111 libxml 2.5.7 (Redhat 9, Debian unstable),
  112 libxml 2.5.8-2.5.9 (Debian unstable)
  113 </p>
  114 <p>libxml1 is not supported.</p>
  115 </dd>
  116 
  117 <dt><tt>--with-www=NAME</tt><br /></dt>
  118 <dd><p>Pick a WWW library to use - either <tt>curl</tt>, 
  119 <tt>xml</tt> (for libxml), <tt>libwww</tt> for W3C libwww or
  120 <tt>none</tt> to disable it.</p></dd>
  121 
  122 <dt><tt>--with-xml2-config=NAME</tt><br /></dt>
  123 <dd><p>Set the path to the libxml xml2-config program</p></dd>
  124 
  125 <dt><tt>--with-curl-config=NAME</tt><br /></dt>
  126 <dd><p>Set the path to the ,a href="http://curl.haxx.se/libcurl/">libcurl</a> curl-config program</p></dd>
  127 
  128 <dt><tt>--with-pkg-config=NAME</tt><br /></dt>
  129 <dd><p>Set the path to the GNOME pkg-config program</p></dd>
  130 
  131 <dt><tt>--with-libwww-config=NAME</tt><br /></dt>
  132 <dd><p>Set the path to the W3C <a href="http://www.w3.org/Library/">WWW library</a> libwww-config program</p></dd>
  133 
  134 </dl>
  135 
  136 <h3>2.3 Configuring</h3>
  137 
  138 <p>If everything is in the default place, do:</p>
  139 <pre>
  140    ./configure
  141 </pre>
  142 
  143 <p>The most common configuration you will be doing something like this:</p>
  144 <pre>
  145    ./configure --with-xml-parser=expat
  146 </pre>
  147 
  148 
  149 <h3>2.4 Compiling</h3>
  150 
  151 <p>Compile the parser and the test program <tt>rapper</tt> with;</p>
  152 <pre>
  153    make
  154 </pre>
  155 <p>Note: GNU make is probably required which may be called
  156 gmake or gnumake if your system has a different make available too.</p>
  157 
  158 
  159 <h3>2.5 Testing</h3>
  160 
  161 <p>Raptor has a built-in test suite that can be invoked with:</p>
  162 <pre>
  163   make check
  164 </pre>
  165 
  166 <p>which should emit lots of exciting test messages to the screen but
  167 conclude with something like:<br />
  168   <tt>All </tt><em>n</em><tt> tests passed</tt><br />
  169 if everything works correctly. There might be some Unicode NFC
  170 tests that fail if GNOME glib2.0 was not available when raptor was
  171 compiled.</p>
  172 
  173 <p>Raptor builds a utility RDF parsing program <em>rapper</em> can
  174 be tried with RDF/XML content like this:</p>
  175 
  176 <pre>
  177   rapper dc.rdf
  178 </pre>
  179 
  180 <!-- FIXME THIS DOESN'T WORK AT PRESENT
  181 <p>It can also extract RDF content inside general XML when the
  182 <tt>--scan</tt> option is set.  e.g. if some RDF/XML is embedded
  183 inside some XHTML, it could be extracted with:</p>
  184 
  185 <pre>
  186   rapper -s /path/to/test/doc.xhtml
  187 </pre>
  188 -->
  189 
  190 <p>You can also run it on <a href="http://www.w3.org/TR/rdf-testcases/#ntriples">N-Triples</a> files like this:</p>
  191 
  192 <pre>
  193   rapper -i ntriples test.nt
  194 </pre>
  195 
  196 <p>The default output is a simple statement dump format, but it can
  197 be changed to emit <a href="http://www.w3.org/TR/rdf-testcases/#ntriples">N-Triples</a> by using the <code>-o</code> option, like this:</p>
  198 
  199 <pre>
  200   rapper -o ntriples dc.rdf
  201 </pre>
  202 
  203 
  204 
  205 <h2>3. Using the library</h2>
  206 
  207 <p>Once the library has been configured and built, there are 
  208 some C example programs that can be built apart from the rapper utility.
  209 They are in the <code>examples</code> sub-directory and can be built with:</p>
  210 <pre>
  211    cd examples
  212 
  213    # Raptor parser abort test program
  214    make raptor_abort
  215 
  216    # Raptor GUI - only if you have the GTK libraries
  217    make grapper
  218 
  219    # If you have all requirements
  220    make examples
  221 </pre>
  222 
  223 <p>The public Raptor API is described in the
  224 <a href="libraptor.html">libraptor.3</a> UNIX manual/web page
  225 </p>
  226 
  227 
  228 <hr />
  229 
  230 <p>Copyright 2000-2003 <a href="http://purl.org/net/dajobe/">Dave Beckett</a>, <a href="http://www.ilrt.bristol.ac.uk/">Institute for Learning and Research Technology</a>, <a href="http://www.bristol.ac.uk/">University of Bristol</a></p>
  231 
  232 </body>
  233 </html>