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
|
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>3.WIN32</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="YAZ User's Guide and Reference"><link rel="up" href="installation.html" title="Chapter2.Compilation and Installation"><link rel="prev" href="installation.unix.html" title="2.UNIX"><link rel="next" href="zoom.html" title="Chapter3.ZOOM"></head><body><link rel="stylesheet" type="text/css" href="common/style1.css"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">3.WIN32</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="installation.unix.html">Prev</a></td><th width="60%" align="center">Chapter2.Compilation and Installation</th><td width="20%" align="right"><a accesskey="n" href="zoom.html">Next</a></td></tr></table><hr></div><div class="sect1" title="3.WIN32"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="installation.win32"></a>3.WIN32</h2></div></div></div><p>The easiest way to install YAZ on Windows is by downloading
an installer from
<a class="ulink" href="http://ftp.indexdata.com/pub/yaz/win32/" target="_top">here</a>.
The installer comes with source too - in case you wish to
compile YAZ with different Compiler options etc.
</p><div class="sect2" title="3.1.Compiling from Source on WIN32"><div class="titlepage"><div><div><h3 class="title"><a name="installation.win32.source"></a>3.1.Compiling from Source on WIN32</h3></div></div></div><p>
YAZ is shipped with "makefiles" for the NMAKE tool that comes
with <a class="ulink" href="http://msdn.microsoft.com/vstudio/" target="_top">
Microsoft Visual Studio</a>.
Version 6 and .NET has been tested. We expect that YAZ compiles
with version 5 as well.
</p><p>
Start a command prompt and switch the sub directory
<code class="filename">WIN</code> where the file <code class="filename">makefile</code>
is located. Customize the installation by editing the
<code class="filename">makefile</code> file (for example by using notepad).
The following summarizes the most important settings in that file:
</p><div class="variablelist"><dl><dt><span class="term"><code class="literal">DEBUG</code></span></dt><dd><p>
If set to 1, the software is
compiled with debugging libraries (code generation is
multi-threaded debug DLL).
If set to 0, the software is compiled with release libraries
(code generation is multi-threaded DLL).
</p></dd><dt><span class="term"><code class="literal">HAVE_TCL</code>, <code class="literal">TCL</code></span></dt><dd><p>
If <code class="literal">HAVE_TCL</code> is set to 1, nmake will
use the ASN.1 compiler (<a class="ulink" href="http://www.tcl.tk/" target="_top">Tcl</a> based).
You must set <code class="literal">TCL</code> to the full path of the Tcl
interpreter.
</p><p>
If you do not have Tcl installed, set
<code class="literal">HAVE_TCL</code> to 0.
</p></dd><dt><span class="term"><code class="literal">HAVE_BISON</code>,
<code class="literal">BISON</code></span></dt><dd><p>
If GNU Bison is present, you might set <code class="literal">HAVE_ICONV</code>
to 1 and specify the Bison executable in <code class="literal">BISON</code>.
Bison is only required if you use the CVS version of
YAZ or if you modify the grammar for CQL
(<code class="filename">cql.y</code>).
</p><p>
A Windows version of GNU Bison is part of
<a class="ulink" href="http://sourceforge.net/projects/unxutils/" target="_top">unxutils</a>.
</p></dd><dt><span class="term"><code class="literal">HAVE_ICONV</code>,
<code class="literal">ICONV_DIR</code></span></dt><dd><p>
If <code class="literal">HAVE_ICONV</code> is set to 1, YAZ is compiled
with iconv support. In this configuration, set
<code class="literal">ICONV_DIR</code> to the iconv source directory.
</p></dd><dt><span class="term"><code class="literal">HAVE_LIBXML2</code>,
<code class="literal">LIBXML2_DIR</code></span></dt><dd><p>
If <code class="literal">HAVE_LIBXML2</code> is set to 1, YAZ is compiled
with SRU support. In this configuration, set
<code class="literal">LIBXML2_DIR</code> to the
<a class="ulink" href="http://xmlsoft.org/" target="_top">libxml2</a> source directory
and
<code class="literal">ZLIB_DIR</code> to the zlib directory.
</p><p>
Windows versions of libxslt, libxml2, zlib and iconv can be found
<a class="ulink" href="http://www.zlatkovic.com/libxml.en.html" target="_top">
Igor Zlatković' site</a>.
</p><div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>
YAZ is not using zlib but libxml2 is depending on it.
</p></div></dd><dt><span class="term"><code class="literal">HAVE_LIBXSLT</code>,
<code class="literal">LIBXSLT_DIR</code></span></dt><dd><p>
If <code class="literal">HAVE_LIBXSLT</code> is set to 1, YAZ is compiled
with XSLT support. In this configuration, set
<code class="literal">LIBXSLT_DIR</code> to the
<a class="ulink" href="http://xmlsoft.org/XSLT/" target="_top">libxslt</a> source directory.
</p><div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>
libxslt depends libxml2.
</p></div></dd><dt><span class="term"><code class="literal">HAVE_ICU</code>,
<code class="literal">ICU_DIR</code></span></dt><dd><p>
If <code class="literal">HAVE_ICU</code> is set to 1, YAZ is compiled
with <a class="ulink" href="http://www.icu-project.org/" target="_top">ICU</a> support.
In this configuration, set
<code class="literal">ICU_DIR</code> to the
<a class="ulink" href="http://www.icu-project.org/" target="_top">ICU</a> source directory.
</p></dd></dl></div><p>
</p><p>
When satisfied with the settings in the makefile, type
</p><pre class="screen">
nmake
</pre><p>
</p><div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>
If the <code class="filename">nmake</code> command is not found on your system
you probably haven't defined the environment variables required to
use that tool. To fix that, find and run the batch file
<code class="filename">vcvars32.bat</code>. You need to run it from within
the command prompt or set the environment variables "globally";
otherwise it doesn't work.
</p></div><p>
If you wish to recompile YAZ - for example if you modify
settings in the <code class="filename">makefile</code> you can delete
object files, etc by running.
</p><pre class="screen">
nmake clean
</pre><p>
</p><p>
The following files are generated upon successful compilation:
</p><div class="variablelist"><dl><dt><span class="term"><code class="filename">bin/yaz4.dll</code> /
<code class="filename">bin/yaz4d.dll</code></span></dt><dd><p>
YAZ Release/Debug DLL.
</p></dd><dt><span class="term"><code class="filename">lib/yaz4.lib</code> /
<code class="filename">lib/yaz4d.lib</code></span></dt><dd><p>
Import library for <code class="filename">yaz4.dll</code> /
<code class="filename">yaz4d.dll</code>.
</p></dd><dt><span class="term"><code class="filename">bin/yaz_cond4.dll</code> /
<code class="filename">bin/yaz_cond4d.dll</code></span></dt><dd><p>
Release/Debug DLL for condition variable utilities (condvar.c).
</p></dd><dt><span class="term"><code class="filename">lib/yaz_cond4.lib</code> /
<code class="filename">lib/yaz_cond4d.lib</code></span></dt><dd><p>
Import library for <code class="filename">yaz_cond4.dll</code> /
<code class="filename">yaz_cond4d.dll</code>.
</p></dd><dt><span class="term"><code class="filename">bin/yaz_icu4.dll</code> /
<code class="filename">bin/yaz_icu4d.dll</code></span></dt><dd><p>
Release/Debug DLL for the ICU wrapper utility.
Only build if HAVE_ICU is 1.
</p></dd><dt><span class="term"><code class="filename">lib/yaz_icu4.lib</code> /
<code class="filename">lib/yaz_icu4d.lib</code></span></dt><dd><p>
Import library for <code class="filename">yaz_icu4.dll</code> /
<code class="filename">yaz_icu4d.dll</code>.
</p></dd><dt><span class="term"><code class="filename">bin/yaz-ztest.exe</code></span></dt><dd><p>
Z39.50 multi-threaded test/example server. It's a WIN32
console application.
</p></dd><dt><span class="term"><code class="filename">bin/yaz-client.exe</code></span></dt><dd><p>
YAZ Z39.50 client application. It's a WIN32 console application.
See chapter <a class="link" href="yaz-client.html" title="yaz-client">YAZ client</a> for more
information.
</p></dd><dt><span class="term"><code class="filename">bin/yaz-icu.exe</code></span></dt><dd><p>This program exposes the ICU wrapper library if that
is enabled for YAZ. Only if ICU is available this program is
build.
</p></dd><dt><span class="term"><code class="filename">bin/zoomsh.exe</code></span></dt><dd><p>
Simple console application implemented on top of the
<a class="link" href="zoom.html" title="Chapter3.ZOOM">ZOOM</a> functions.
The application is a command line shell that allows you to enter
simple commands to perform ZOOM operations.
</p></dd><dt><span class="term"><code class="filename">bin/zoomtst1.exe</code>,
<code class="filename">bin/zoomtst2.exe</code>, ..</span></dt><dd><p>
Several small applications that demonstrates the ZOOM API.
</p></dd></dl></div><p>
</p></div><div class="sect2" title="3.2.How to make apps using YAZ on WIN32"><div class="titlepage"><div><div><h3 class="title"><a name="installation-linking-yaz-win32"></a>3.2.How to make apps using YAZ on WIN32</h3></div></div></div><p>
This section will go though the process of linking your WIN32
applications with YAZ.
</p><p>
Some people are confused by the fact that we use the nmake
tool to build YAZ. They think they have to do that too - in order
to make their WIN32 applications work with YAZ. The good news is that
you don't have to. You can use the integrated environment of
Visual Studio if desired for your own application.
</p><p>
When setting up a project or Makefile you have to set the following:
</p><div class="variablelist"><dl><dt><span class="term">include path</span></dt><dd><p>
Set it to the <code class="filename">include</code> directory of YAZ.
</p></dd><dt><span class="term">import library <code class="filename">yaz4.lib</code>
</span></dt><dd><p>
You must link with this library. It's located in the
sub directory <code class="filename">lib</code> of YAZ.
If you want to link with the debug version of YAZ, you must
link against <code class="filename">yaz4d.lib</code> instead.
</p></dd><dt><span class="term">dynamic link library <code class="filename">yaz4.dll</code>
</span></dt><dd><p>
This DLL must be in your execution path when you invoke
your application. Specifically, you should distribute this
DLL with your application.
</p></dd></dl></div><p>
</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="installation.unix.html">Prev</a></td><td width="20%" align="center"><a accesskey="u" href="installation.html">Up</a></td><td width="40%" align="right"><a accesskey="n" href="zoom.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">2.UNIX</td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top">Chapter3.ZOOM</td></tr></table></div></body></html>
|