-
Notifications
You must be signed in to change notification settings - Fork 0
/
install.html
403 lines (379 loc) · 21.3 KB
/
install.html
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
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta content="Build and installation instructions for BASIS." name="description" />
<title>Installation — BASIS</title>
<link rel="stylesheet" href="_static/cmake-basis.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: 'v3.3 (fb18c98)',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="shortcut icon" href="_static/favicon.ico"/>
<link rel="author" title="About these documents" href="about.html" />
<link rel="top" title="BASIS" href="index.html" />
<link rel="next" title="Support" href="help.html" />
<link rel="prev" title="Download" href="download.html" />
<meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9">
</head>
<body>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="help.html" title="Support"
accesskey="N">next</a></li>
<li class="right" >
<a href="download.html" title="Download"
accesskey="P">previous</a> |</li>
<li><a href="sidebar.html">BASIS</a> »</li>
</ul>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="installation">
<h1>Installation<a class="headerlink" href="#installation" title="Permalink to this headline">¶</a></h1>
<div class="section" id="prerequisites">
<span id="basisbuilddependencies"></span><h2>Prerequisites<a class="headerlink" href="#prerequisites" title="Permalink to this headline">¶</a></h2>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">The stated package versions are the minimum versions for which it is known that
BASIS is working with.</p>
</div>
<div class="section" id="required-packages">
<h3>Required Packages<a class="headerlink" href="#required-packages" title="Permalink to this headline">¶</a></h3>
<p>This section summarizes software packages which have to be installed on your system before
BASIS can be build and installed from its sources.</p>
<table border="1" class="docutils">
<colgroup>
<col width="27%" />
<col width="11%" />
<col width="62%" />
</colgroup>
<thead valign="bottom">
<tr class="row-odd"><th class="head">Package</th>
<th class="head">Version</th>
<th class="head">Description</th>
</tr>
</thead>
<tbody valign="top">
<tr class="row-even"><td><a class="reference external" href="http://www.cmake.org/">CMake</a></td>
<td>2.8.12</td>
<td><p class="first">A cross-platform, open-source build tool used to generate
platform specific build configurations. It configures the
system for the various build tools which perform the actual
build of the software.</p>
<p class="last">If your operating system such as certain Linux distribution
does not include a pre-build binary package of the required
version yet, download a more recent CMake version from the
<a class="reference external" href="http://www.cmake.org/cmake/resources/software.html">CMake download page</a> and build and install it from sources.
Often this is easiest accomplished by using the CMake version
provided by the Linux distribution in order to configure the
build system for the more recent CMake version. To avoid
conflict with native CMake installation, it is recommended
to install your own build of CMake in a different directory.</p>
</td>
</tr>
<tr class="row-odd"><td><a class="reference external" href="http://www.gnu.org/software/make/">GNU Make</a>, <a class="reference external" href="http://martine.github.io/ninja/">ninja</a>, etc.</td>
<td> </td>
<td>All build tools supported by the CMake generator.</td>
</tr>
<tr class="row-even"><td><a class="reference external" href="http://gcc.gnu.org/">GNU Compiler Collection</a>,
<a class="reference external" href="http://clang.llvm.org/">Clang</a>, etc.</td>
<td> </td>
<td>A C++ compiler is required to compile the BASIS source code.</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="optional-packages">
<h3>Optional Packages<a class="headerlink" href="#optional-packages" title="Permalink to this headline">¶</a></h3>
<p>The packages named in the following table are used by BASIS only if installed on your system,
and their presence is generally not required. Hence, you will be able to use the software even without
these.</p>
<table border="1" class="docutils">
<colgroup>
<col width="27%" />
<col width="11%" />
<col width="62%" />
</colgroup>
<thead valign="bottom">
<tr class="row-odd"><th class="head">Package</th>
<th class="head">Version</th>
<th class="head">Description</th>
</tr>
</thead>
<tbody valign="top">
<tr class="row-even"><td><a class="reference external" href="http://www.stack.nl/~dimitri/doxygen/">Doxygen</a></td>
<td>1.8.0</td>
<td>This tools is required for the generation of the API
documentation from in-source comments in C++, CMake, Bash,
Python, and Perl. Note that only since version 1.8.0, Python
and the use of Markdown (Extra) are support by Doxygen.</td>
</tr>
<tr class="row-odd"><td><a class="reference external" href="http://www.python.org/">Python</a></td>
<td>2.7</td>
<td>Python is used by the basisproject tool that generates
template projects. Python is also generally supported
for the implementation of tools and libraries following
the BASIS standard.</td>
</tr>
<tr class="row-even"><td><a class="reference external" href="http://sphinx.pooco.org/">Sphinx</a></td>
<td>1.2</td>
<td>This tool can be used for the generation of the documentation
from in-source Python comments and in particular from
<a class="reference external" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a>.</td>
</tr>
<tr class="row-odd"><td><a class="reference external" href="http://www.latex-project.org/">LaTeX</a></td>
<td> </td>
<td>The LaTeX tools may be required for the generation of the
software manuals. Usually these are, however, already
included in PDF in which case a LaTeX installation is only
needed if you want to regenerate these from the LaTeX sources
(if available after all).</td>
</tr>
<tr class="row-even"><td><a class="reference external" href="http://www.itk.org/">ITK</a></td>
<td>3.14</td>
<td>The standalone <code class="docutils literal"><span class="pre">basistest-driver</span></code> executable currently
makes use of the ITK, either version 3 or 4 and above,
for the comparison of a test image to one or more
baseline images. If no installation of this library is
found, this executable is excluded from the build and
installation. Note that many packages developed at SBIA
make use of this executable in their tests. If BASIS has
been built without the <code class="docutils literal"><span class="pre">basistest-driver</span></code>, these
packages have to be build with the <code class="docutils literal"><span class="pre">BUILD_TESTING</span></code>
option set to <code class="docutils literal"><span class="pre">OFF</span></code> (the default).</td>
</tr>
<tr class="row-odd"><td><a class="reference external" href="http://www.mathworks.com/products/matlab/">MATLAB</a></td>
<td>R2009b</td>
<td>The MATLAB tools are used by BASIS to build <a class="reference external" href="http://www.mathworks.com/help/techdoc/matlab_external/f7667.html">MEX-Files</a>
from C++ sources. If <code class="docutils literal"><span class="pre">BUILD_TESTING</span></code> is set to <code class="docutils literal"><span class="pre">ON</span></code>
and the <a class="reference external" href="http://www.mathworks.com/help/techdoc/ref/mex.html">MEX</a> script is found, the tests for the build of
MEX files are run. Otherwise, these are excluded from
the test.</td>
</tr>
<tr class="row-even"><td><a class="reference external" href="http://www.mathworks.com/products/compiler/">MATLAB Compiler</a></td>
<td>R2009b</td>
<td>The MATLAB Compiler (MCC) is used by BASIS to build
stand-alone executables from MATLAB source files.
If <code class="docutils literal"><span class="pre">BUILD_TESTING</span></code> is set to <code class="docutils literal"><span class="pre">ON</span></code> and MCC is found,
the tests for the build of such binaries are run.
Otherwise, these are excluded from the test.</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="build-and-installation">
<span id="basisinstallationsteps"></span><h2>Build and Installation<a class="headerlink" href="#build-and-installation" title="Permalink to this headline">¶</a></h2>
<div class="section" id="build-steps">
<h3>Build Steps<a class="headerlink" href="#build-steps" title="Permalink to this headline">¶</a></h3>
<p>The steps to build, test, and install BASIS are as follows:</p>
<ol class="arabic simple">
<li>Extract source files.</li>
<li>Create build directory and change to it.</li>
<li>Run CMake to configure the build tree.</li>
<li>Build the software using selected build tool.</li>
<li>Test the built software.</li>
<li>Install the built files.</li>
</ol>
<p>On Unix-like systems with GNU Make as build tool, these build steps can be
summarized by the following sequence of commands executed in a shell,
where $package and $version are shell variables which represent the name
of this package and the obtained version of the software.</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ tar xzf cmake-basis-<span class="nv">$version</span>.tar.gz
$ <span class="nb">cd</span> cmake-basis-<span class="nv">$version</span>
$ mkdir build <span class="o">&&</span> <span class="nb">cd</span> build
$ ccmake ..
</pre></div>
</div>
<ul class="simple">
<li>Press ‘c’ to configure the build system and ‘e’ to ignore warnings.</li>
<li>Set CMAKE_INSTALL_PREFIX and other CMake variables and options.</li>
<li>Continue pressing ‘c’ until the option ‘g’ is available.</li>
<li>Then press ‘g’ to generate the configuration files for GNU Make.</li>
</ul>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ make
$ make <span class="nb">test</span> <span class="o">(</span>optional<span class="o">)</span>
$ make install <span class="o">(</span>optional<span class="o">)</span>
</pre></div>
</div>
<p>Please refer to the detailed <a class="reference internal" href="howto/install.html"><span class="doc">Build and Installation How-To Guide</span></a>
which applies to any project developed using BASIS if you are uncertain about above
steps or have problems to build, test, or install the software on your system.
If this guide does not help you resolve the issue, please
<a class="reference external" href="https://github.com/cmake-basis/BASIS/issues">Report the Issue on GitHub</a>.
In case of failing tests, please attach the output of the following
command:</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>$ ctest -V ><span class="p">&</span> test.log
</pre></div>
</div>
</div>
<div class="section" id="cmake-options">
<span id="basisinstallationoptions"></span><h3>CMake Options<a class="headerlink" href="#cmake-options" title="Permalink to this headline">¶</a></h3>
<p>In the following, only CMake settings available to configure the build and
installation of BASIS itself are documented. See <a class="reference internal" href="howto/cmake-options.html"><span class="doc">CMake Options</span></a>
for detailed information on general CMake Options available for the build
and installation of any package developed with BASIS.</p>
<dl class="option">
<dt id="cmdoption-DDEPENDS_ITK_DIR">
<code class="descname">-DDEPENDS_ITK_DIR</code><code class="descclassname">:PATH</code><a class="headerlink" href="#cmdoption-DDEPENDS_ITK_DIR" title="Permalink to this definition">¶</a></dt>
<dd><p>Specify directory of ITKConfig.cmake file. The ITK library is
used by the basistest-driver executable if available. See
Build Dependencies for more details.</p>
</dd></dl>
<dl class="option">
<dt id="cmdoption-DDEPENDS_MATLAB_DIR">
<code class="descname">-DDEPENDS_MATLAB_DIR</code><code class="descclassname">:PATH</code><a class="headerlink" href="#cmdoption-DDEPENDS_MATLAB_DIR" title="Permalink to this definition">¶</a></dt>
<dd><p>Specify installation root directory of <a class="reference external" href="http://www.mathworks.com/products/matlab/">MATLAB</a>. This variable
is only available if BUILD_TESTING was set to ON and setting
it can be omitted. If a MATLAB installation was specified,
however, the tests for the build of binaries using the <a class="reference external" href="http://www.mathworks.com/products/compiler/">MATLAB Compiler</a>
or the <a class="reference external" href="http://www.mathworks.com/help/techdoc/ref/mex.html">MEX</a> script respectively can be run.</p>
</dd></dl>
<dl class="option">
<dt id="cmdoption-DDEFAULT_TEMPLATE">
<code class="descname">-DDEFAULT_TEMPLATE</code><code class="descclassname">:PATH</code><a class="headerlink" href="#cmdoption-DDEFAULT_TEMPLATE" title="Permalink to this definition">¶</a></dt>
<dd><p>Path to the directory and version of the default mad-libs style text substitution project
template that will be installed with BASIS. See the
<a class="reference internal" href="howto/use-and-customize-templates.html"><span class="doc">Template Customization How-To</span></a> for details.</p>
</dd></dl>
<dl class="option">
<dt id="cmdoption-DINSTALL_TEMPLATE_DIR">
<code class="descname">-DINSTALL_TEMPLATE_DIR</code><code class="descclassname">:BOOL</code><a class="headerlink" href="#cmdoption-DINSTALL_TEMPLATE_DIR" title="Permalink to this definition">¶</a></dt>
<dd><p>Custom installation directory for project templates.</p>
</dd></dl>
<div class="section" id="advanced-cmake-options">
<h4>Advanced CMake Options<a class="headerlink" href="#advanced-cmake-options" title="Permalink to this headline">¶</a></h4>
<p>Depending on which language interpreters are installed on your system,
the following CMake options are available:</p>
<dl class="option">
<dt id="cmdoption-DWITH_ITK">
<code class="descname">-DWITH_ITK</code><code class="descclassname">:BOOLEAN</code><a class="headerlink" href="#cmdoption-DWITH_ITK" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether to link the standalone test driver with ITK.</p>
</dd></dl>
<dl class="option">
<dt id="cmdoption-DWITH_Python">
<code class="descname">-DWITH_Python</code><code class="descclassname">:BOOLEAN</code><a class="headerlink" href="#cmdoption-DWITH_Python" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether to build/enable the Python utilities.</p>
</dd></dl>
<dl class="option">
<dt id="cmdoption-DWITH_Perl">
<code class="descname">-DWITH_Perl</code><code class="descclassname">:BOOLEAN</code><a class="headerlink" href="#cmdoption-DWITH_Perl" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether to build/enable the Perl utilities.</p>
</dd></dl>
<dl class="option">
<dt id="cmdoption-DWITH_BASH">
<code class="descname">-DWITH_BASH</code><code class="descclassname">:BOOLEAN</code><a class="headerlink" href="#cmdoption-DWITH_BASH" title="Permalink to this definition">¶</a></dt>
<dd><p>Whether to build/enable the BASH utilities.</p>
</dd></dl>
</div>
</div>
</div>
<div class="section" id="set-up-the-environment">
<span id="basisenvironmentsetup"></span><h2>Set up the Environment<a class="headerlink" href="#set-up-the-environment" title="Permalink to this headline">¶</a></h2>
<p>In order to ease the execution of the main executable files, we suggest to
add the path <code class="docutils literal"><span class="pre"><prefix>/bin/</span></code> to the search path for executable files, i.e.,
the <code class="docutils literal"><span class="pre">PATH</span></code> environment variable. This is, however, generally not required.
It only eases the execution of the command-line tools provided by the software
package.</p>
<p>For example, if you use <a class="reference external" href="http://www.gnu.org/software/bash/">Bash</a> add the following line to the <code class="docutils literal"><span class="pre">~/.bashrc</span></code> file:</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span><span class="nb">export</span> <span class="nv">PATH</span><span class="o">=</span><span class="s2">"<prefix>/bin:</span><span class="si">${</span><span class="nv">PATH</span><span class="si">}</span><span class="s2">"</span>
</pre></div>
</div>
</div>
<div class="section" id="deinstallation">
<span id="basisdeinstallation"></span><h2>Deinstallation<a class="headerlink" href="#deinstallation" title="Permalink to this headline">¶</a></h2>
<p>During the installation, a manifest of all installed files and a CMake
script which reads in this list in order to remove these files again
is generated and installed in <code class="docutils literal"><span class="pre"><prefix>/lib/cmake/basis/</span></code>.</p>
<p>The uninstaller is located in <code class="docutils literal"><span class="pre"><prefix>/bin/</span></code> and named <code class="docutils literal"><span class="pre">uninstall-basis</span></code>.
In order to remove all files installed by this package as well as the empty
directories left behind inside the installation root directory given by <code class="docutils literal"><span class="pre"><prefix></span></code>,
run the command:</p>
<div class="highlight-bash"><div class="highlight"><pre><span></span>uninstall-basis
</pre></div>
</div>
<p>assuming that you added <code class="docutils literal"><span class="pre"><prefix>/bin/</span></code> to your <span class="target" id="index-0"></span><a class="reference internal" href="howto/install.html#envvar-PATH"><code class="xref std std-envvar docutils literal"><span class="pre">PATH</span></code></a> environment variable.</p>
</div>
</div>
</div>
</div>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<p class="logo"><a href="index.html">
<img class="logo" src="_static/logo_title.svg" alt="Logo"/>
</a></p>
<div id="searchbox" style="display: none">
<h3>Quick search</h3>
<form class="search" action="search.html" method="get">
<input type="text" name="q" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
<h3><a href="contents.html">Table Of Contents</a></h3>
<ul>
<li class="toctree-l1"><a class="reference internal" href="index.html">Overview</a></li>
<li class="toctree-l1"><a class="reference internal" href="quickstart.html">Quick Start</a></li>
<li class="toctree-l1"><a class="reference internal" href="howto.html">How-to Guides</a></li>
<li class="toctree-l1"><a class="reference internal" href="standard.html">Standards</a></li>
<li class="toctree-l1"><a class="reference internal" href="guideline.html">Guidelines</a></li>
<li class="toctree-l1"><a class="reference internal" href="reference.html">Reference</a></li>
<li class="toctree-l1"><a class="reference internal" href="apidoc.html">API</a></li>
</ul>
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="changelog.html">News</a></li>
<li class="toctree-l1"><a class="reference internal" href="download.html">Download</a></li>
<li class="toctree-l1 current"><a class="current reference internal" href="#">Installation</a><ul>
<li class="toctree-l2"><a class="reference internal" href="#prerequisites">Prerequisites</a><ul>
<li class="toctree-l3"><a class="reference internal" href="#required-packages">Required Packages</a></li>
<li class="toctree-l3"><a class="reference internal" href="#optional-packages">Optional Packages</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="#build-and-installation">Build and Installation</a><ul>
<li class="toctree-l3"><a class="reference internal" href="#build-steps">Build Steps</a></li>
<li class="toctree-l3"><a class="reference internal" href="#cmake-options">CMake Options</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="#set-up-the-environment">Set up the Environment</a></li>
<li class="toctree-l2"><a class="reference internal" href="#deinstallation">Deinstallation</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="help.html">Support</a></li>
<li class="toctree-l1"><a class="reference internal" href="about.html">About</a></li>
</ul>
<h3>External Links</h3>
<ul>
<li><a href="https://github.com/cmake-basis/BASIS">Repository</a></ li>
<li><a href="https://github.com/cmake-basis/BASIS/issues">Issues</a></ li>
</ul>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="footer">
© Copyright 2011-12 University of Pennsylvania, 2013-14 Carnegie Mellon University, 2013-16 Andreas Schuh.
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.4.1.
</div>
</body>
</html>