1 <!-- $Id: installation.xml,v 1.3 2001-10-24 09:27:59 adam Exp $ -->
2 <chapter id="installation"><title>Compilation and Installation</title>
5 The latest version of the software will generally be found at
8 <ulink url="http://ftp.indexdata.dk/pub/yaz/">
9 http://ftp.indexdata.dk/pub/yaz/</ulink>
12 We have tried our best to keep the software portable, and on many
13 platforms, you should be able to compile everything with little or
15 So far, the software has been ported to the following platforms with
16 little or no difficulties.
19 <listitem><para>Unix systems</para>
21 <listitem><para>HP/UX</para></listitem>
22 <listitem><para>SunOS/Solaris</para></listitem>
23 <listitem><para>DEC Unix</para></listitem>
24 <listitem><para>Linux</para></listitem>
25 <listitem><para>IBM AIX</para></listitem>
26 <listitem><para>Data General DG/UX (with some CFLAGS tinkering)
28 <listitem><para>SGI/IRIX</para></listitem>
29 <listitem><para>DDE Supermax</para></listitem>
30 </itemizedlist></listitem>
31 <listitem><para>Non-unix systems</para>
33 <listitem><para>Apple Macintosh (using the Codewarrior programming
34 environment and the GUSI socket libraries)</para></listitem>
35 <listitem><para>MS Windows 95/98/NT/W2K (Win32)</para></listitem>
36 <listitem><para>IBM AS/400</para></listitem>
37 </itemizedlist></listitem>
42 If you move the software to other platforms, we'd be grateful if you'd
43 let us know about it. If you run into difficulties, we will try to help
44 if we can, and if you solve the problems, we would be happy to include
45 your fixes in the next release. So far, we have mostly avoided
46 #ifdefs for individual platforms, and we'd like to keep it that
47 way as far as it makes sense.
51 We maintain a mailing-list for the purpose of announcing new releases and
52 bug-fixes, as well as general discussion. Subscribe by sending mail to
53 <ulink url="mailto:yaz-request@indexdata.dk">
54 yaz-request@indexdata.dk
56 General questions and problems can be directed at
57 <ulink url="mailto:yaz-help@indexdata.dk">
59 </ulink>, or the address given at the top of this document.
62 <sect1 id="installation.unix"><title>UNIX</title>
65 Note that if your system doesn't have a native ANSI C compiler, you may
66 have to acquire one separately. We recommend gcc.
69 For UNIX we use GNU configure to create Makefiles for &yaz;.
70 Generally it should be sufficient to run configure without options:
78 The configure script attempts to use use the C compiler specified by
79 the <literal>CC</literal> environment variable. If not set, GNU C will be
80 used if it is available. The <literal>CFLAGS</literal> environment
81 variable holds options to be passed to the C compiler. If you're using
82 Bourne-compatible shell you may pass something like this to use a
83 particular C compiler with optimization enabled:
87 CC=/opt/ccs/bin/cc CFLAGS=-O ./configure
91 To customize &yaz; the configure script also accepts a set of options.
92 The most important are:
95 <varlistentry><term><literal>--prefix </literal>path</term>
96 <listitem><para>Specifies installation prefix. This is
97 only needed if you run <literal>make install</literal> later to
98 perform a "system" installation. The prefix is
99 <literal>/usr/local</literal> if not specified.
103 <term><literal>--enable-comp </literal></term>
104 <listitem><para> &yaz; will be built using the ASN.1 compiler for &yaz;
105 (default). If you wish to use the old decoders (in sub directory asn)
106 use <literal>--disable-comp</literal> instead.
109 <varlistentry><term><literal>--enable-threads</literal></term>
110 <listitem><para>&yaz; will be built using POSIX threads.
111 Specifically, <constant>_REENTRANT</constant> will be defined during
119 When configured, build the software by typing:
127 The following files are generated by the make process:
129 <varlistentry><term><filename>lib/libyaz.a</filename></term>
131 The &yaz; programmers' library.
132 </para></listitem></varlistentry>
134 <varlistentry><term><filename>ztest/yaz-ztest</filename></term>
135 <listitem><para>A test Z39.50 server.
136 </para></listitem></varlistentry>
138 <varlistentry><term><filename>client/yaz-client</filename></term>
139 <listitem><para>A command mode Z39.50 client.
140 </para></listitem></varlistentry>
142 <varlistentry><term><filename>yaz-config</filename></term>
143 <listitem><para>A Bourne-shell script that holds build
145 </para></listitem></varlistentry>
147 <varlistentry><term><filename>yaz-comp</filename></term>
148 <listitem><para>The ASN.1 compiler for &yaz;. Requires the
149 Tcl Shell, <application>tclsh</application>, in current path to work.
150 </para></listitem></varlistentry>
156 If you wish to install &yaz; in system directories such as
157 <filename>/usr/local/bin</filename>,
158 <filename>/usr/local/lib</filename> you can type:
166 You probably need to have root access in order to perform this.
167 You must specify the <literal>--prefix</literal> option for configure if
168 you wish to install &yaz; in other directories than the default
169 <filename>/usr/local/</filename>.
173 If you wish to perform an un-installation of &yaz; use:
181 This will only work if you haven't reconfigured &yaz; (and therefore
182 changed installation prefix). Note that uninstall will not
183 remove directories created by make install, e.g.
184 <filename>/usr/local/include/yaz</filename>.
188 <sect1 id="installation.win32"><title>WIN32</title>
191 &yaz; is shipped with "makefiles" for the NMAKE tool that comes
194 Start an MS-DOS prompt and switch the sub directory
195 <filename>WIN</filename> where the file <filename>makefile</filename>
196 is located. Customize the installation by editing the
197 <filename>makefile</filename> file (for example by using notepad).
199 The following summarises the most important settings in that file:
201 <table frame="top"><title>WIN32 makefile settings</title>
205 <entry>Setting</entry>
206 <entry>Description</entry>
212 <entry><literal>NEW_Z3950</literal></entry>
213 <entry> If 1, the auto-generated decoder/encoders
214 for Z39.50 as written by the ASN.1 compiler will be used. If 0,
215 the old decoders for Z39.50 will be used. Note, when 1, the
216 setting TCL should point to the Tcl shell on your system.
221 <entry><literal>DEBUG</literal></entry>
222 <entry> If set to 1, the software is
223 compiled with debugging libraries. If set to 0, the software
224 is compiled with release (non-debugging) libraries.
229 <entry><literal>TCL</literal></entry>
230 <entry> Specifies the name of the Tcl shell (EXE-file).
231 You do not need setting this or installing Tcl unless you wish
232 to change or add ASN.1 for &yaz;.
242 When satisfied with the settings in the makefile type
248 The following files are generated upon successful compilation:
251 <varlistentry><term><filename>bin/yaz.dll</filename></term>
253 the multi-threaded &yaz; DLL.
254 </para></listitem></varlistentry>
256 <varlistentry><term><filename>bin/yaz-ztest.exe</filename></term>
258 A console Z39.50 client application.
259 </para></listitem></varlistentry>
261 <varlistentry><term><filename>bin/yaz-ztest.exe</filename></term>
263 A console Z39.50 multi threaded server.
264 </para></listitem></varlistentry>
272 <!-- Keep this comment at the end of the file
277 sgml-minimize-attributes:nil
278 sgml-always-quote-attributes:t
281 sgml-parent-document: "yaz.xml"
282 sgml-local-catalogs: "../../docbook/docbook.cat"
283 sgml-namecase-general:t