Skip to content

Commit bf5b5f2

Browse files
committed
Update old information about building
1 parent 1c3da69 commit bf5b5f2

File tree

1 file changed

+44
-45
lines changed

1 file changed

+44
-45
lines changed

doc/users/building.rst

Lines changed: 44 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -28,40 +28,39 @@ the unit test suite.
2828
Libraries and toolchain programs
2929
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3030

31-
+ CMake version 2.8.9 and higher;
31+
+ CMake version 2.8.10 and higher;
3232
+ Git version 1.7.1 and higher;
33-
+ Python interpreter 2.4 and higher;
33+
+ Python interpreter 2.7 and higher;
3434
+ Boost libraries version 1.54.0 and higher;
3535

3636
.. note::
3737

38-
Version 1.54.0 of Boost libraries is shipped with the module and resides in the `cmake/downloaded` subdirectory.
38+
Version 1.54.0 of Boost libraries is shipped with the module and resides in the ``cmake/downloaded`` subdirectory.
3939
Unless you want to use another version of Boost, you should not worry about satisfying this dependency.
4040

4141
+ `zlib <http://www.zlib.net/>`_ version 1.2 and higher (unit test suite only);
4242
+ Doxygen version 1.7.6 and higher (documentation only)
4343
+ Perl (documentation only)
44-
+ PyYAML Python module (documentation only)
4544
+ Sphinx (documentation only)
4645

4746
PCMSolver relies on the Eigen template libraries version 3.3.0 and higher.
48-
Version 3.3.0 of Eigen libraries is shipped with the module and resides in the `external` subdirectory.
47+
Version 3.3.0 of Eigen libraries is shipped with the module and resides in the ``external`` subdirectory.
4948

5049
Configuration
5150
-------------
5251

53-
Configuration is managed through the front-end script `setup` residing in the
52+
Configuration is managed through the front-end script ``setup`` residing in the
5453
repository main directory. Issuing:
5554

5655
.. code-block:: bash
5756
5857
./setup [options] [build path]
5958
6059
will create the build directory in build path and run CMake with the given
61-
options. By default, files are configured in the `build` directory. The `-h` or
62-
`--help` option will list the available options and their effect. Options can
63-
be forwarded directly to CMake by using the `--cmake-options` flag and listing
64-
the `-D...` options. Usually the following command is sufficient to get the
60+
options. By default, files are configured in the ``build`` directory. The ``-h`` or
61+
``--help`` option will list the available options and their effect. Options can
62+
be forwarded directly to CMake by using the ``--cmake-options`` flag and listing
63+
the ``-D...`` options. Usually the following command is sufficient to get the
6564
configuration done for a debug build, including compilation of the unit test
6665
suite:
6766

@@ -70,7 +69,7 @@ suite:
7069
./setup --type=debug
7170
7271
The unit tests suite is **always** compiled in standalone mode, unless the
73-
`-DENABLE_TESTS=OFF` option is forwarded to CMake.
72+
``-DENABLE_TESTS=OFF`` option is forwarded to CMake.
7473

7574
Getting Boost
7675
~~~~~~~~~~~~~
@@ -87,22 +86,22 @@ documentation on how to build Boost on Unix variants is available
8786
`here <http://www.boost.org/doc/libs/1_56_0/more/getting_started/unix-variants.html>`_.
8887
It is here assumed that the user **does not** have root access to the machine
8988
and will install the libraries to a local prefix, a subdirectory of
90-
`/home/user-name` tipically.
89+
``/home/user-name`` tipically.
9190
Once you've downloaded and unpacked the archive, run the bootstrap script to configure:
9291

9392
.. code-block:: bash
9493
9594
cd path/to/boost
9695
./bootstrap.sh --prefix=/home/user-name/boost
9796
98-
Running `./bootstrap.sh --help` will list the available options for the script. To build run:
97+
Running ``./bootstrap.sh --help`` will list the available options for the script. To build run:
9998

10099
.. code-block:: bash
101100
102101
./b2 install
103102
104103
This might take a while. After a successful build you will find the headers in
105-
`/home/user-name/boost/include` and libraries in `/home/user-name/boost/lib`
104+
``/home/user-name/boost/include`` and libraries in ``/home/user-name/boost/lib``
106105
Now, you will have Boost in a nonstandard location. Without hints CMake will
107106
not be able to find it and configuration of `PCMSolver` will fail. To avoid
108107
this, you will have to pass the location of the headers and libraries to the
@@ -124,55 +123,55 @@ Advanced configuration options
124123
These options are marked as advanced as it is highly unlikely they will
125124
be useful when not programming the library:
126125

127-
* `--exdiag` Enable C++ extended diagnostics flags. Disabled by default.
128-
* `--ccache` Enable use of ccache for C/C++ compilation caching.
126+
* ``--exdiag`` Enable C++ extended diagnostics flags. Disabled by default.
127+
* ``--ccache`` Enable use of ccache for C/C++ compilation caching.
129128
Enabled by default, unless ccache is not available.
130-
* `--build-boost` Deactivate Boost detection and build on-the-fly. Disabled by default.
131-
* `--eigen` Root directory for Eigen3. Search for Eigen3 in the location provided by the
129+
* ``--build-boost`` Deactivate Boost detection and build on-the-fly. Disabled by default.
130+
* ``--eigen`` Root directory for Eigen3. Search for Eigen3 in the location provided by the
132131
user. If search fails, fall back to the version bundled with the library.
133-
* `--static` Create only static library. Disabled by default.
132+
* ``--static`` Create only static library. Disabled by default.
134133

135-
Some options can only be tweaked `via` `--cmake-options` to the setup script:
134+
Some options can only be tweaked `via` ``--cmake-options`` to the setup script:
136135

137-
* `ENABLE_CXX11_SUPPORT` Enable C++11 support. Tries to detect which C++11 features
136+
* ``ENABLE_CXX11_SUPPORT`` Enable C++11 support. Tries to detect which C++11 features
138137
are supported by the compiler and enables use of the new standard. Enabled by default.
139138

140139
.. warning::
141140

142141
This option is **always** overridden for some compilers that have
143142
buggy C++11 support.
144143

145-
* `ENABLE_DOCS` Enable build of documentation. This requires a number of additional dependencies.
144+
* ``ENABLE_DOCS`` Enable build of documentation. This requires a number of additional dependencies.
146145
If any of these are not met, documentation is not built. Enabled by default.
147-
* `ENABLE_LOGGER` Enable compilation of logger sources. Disabled by default.
146+
* ``ENABLE_LOGGER`` Enable compilation of logger sources. Disabled by default.
148147

149148
.. warning::
150149

151150
The logger is not currently in use in any part of the code.
152151

153-
* `ENABLE_TIMER` Enable compilation of timer sources. Enabled by default.
154-
* `BUILD_STANDALONE` Enable compilation of standalone `run_pcm` executable. Enabled by default.
155-
* `ENABLE_Fortran_API` Enable compilation of the Fortran90 bindings for the API. Enabled by default.
156-
* `ENABLE_GENERIC` Enable mostly static linking in shared library. Disabled by default.
157-
* `ENABLE_TESTS` Enable compilation of unit tests suite. Enabled by default.
158-
* `SHARED_LIBRARY_ONLY` Create only shared library. Opposite of `--static`.
159-
* `PYMOD_INSTALL_LIBDIR` *If set*, installs python scripts/modules to
152+
* ``ENABLE_TIMER`` Enable compilation of timer sources. Enabled by default.
153+
* ``BUILD_STANDALONE`` Enable compilation of standalone ``run_pcm`` executable. Enabled by default.
154+
* ``ENABLE_Fortran_API`` Enable compilation of the Fortran90 bindings for the API. Enabled by default.
155+
* ``ENABLE_GENERIC`` Enable mostly static linking in shared library. Disabled by default.
156+
* ``ENABLE_TESTS`` Enable compilation of unit tests suite. Enabled by default.
157+
* ``SHARED_LIBRARY_ONLY`` Create only shared library. Opposite of ``--static``.
158+
* ``PYMOD_INSTALL_LIBDIR`` *If set*, installs python scripts/modules to
160159
``${CMAKE_INSTALL_LIBDIR}${PYMOD_INSTALL_LIBDIR}/pcmsolver`` rather than the
161160
default ``${CMAKE_INSTALL_BINDIR}`` (i.e., ``bin``).
162-
* `CMAKE_INSTALL_BINDIR` Where to install executables, if not to ``bin``.
163-
* `CMAKE_INSTALL_LIBDIR` Where to install executables, if not to ``bin``.
164-
* `CMAKE_INSTALL_INCLUDESDIR` Where to install executables, if not to ``bin``.
165-
166-
* `CMAKE_INSTALL_BINDIR` Location within CMAKE_INSTALL_PREFIX (``--prefix``) to
167-
which executables are installed (default: bin).
168-
* `CMAKE_INSTALL_LIBDIR` Location within CMAKE_INSTALL_PREFIX (``--prefix``) to
169-
which libraries are installed (default: lib).
170-
* `CMAKE_INSTALL_INCLUDEDIR` Location within CMAKE_INSTALL_PREFIX (``--prefix``)
171-
to which headers are installed (default: include).
172-
* `PYMOD_INSTALL_LIBDIR` *If set*, location within CMAKE_INSTALL_LIBDIR to which
161+
* ``CMAKE_INSTALL_BINDIR`` Where to install executables, if not to ``bin``.
162+
* ``CMAKE_INSTALL_LIBDIR`` Where to install executables, if not to ``bin``.
163+
* ``CMAKE_INSTALL_INCLUDESDIR`` Where to install executables, if not to ``bin``.
164+
165+
* ``CMAKE_INSTALL_BINDIR`` Location within ``CMAKE_INSTALL_PREFIX`` (``--prefix``) to
166+
which executables are installed (default: ``bin``).
167+
* ``CMAKE_INSTALL_LIBDIR`` Location within ``CMAKE_INSTALL_PREFIX`` (``--prefix``) to
168+
which libraries are installed (default: ``lib``).
169+
* ``CMAKE_INSTALL_INCLUDEDIR`` Location within ``CMAKE_INSTALL_PREFIX`` (``--prefix```)
170+
to which headers are installed (default: ``include``).
171+
* ``PYMOD_INSTALL_LIBDIR`` *If set*, location within ``CMAKE_INSTALL_LIBDIR`` to which
173172
python modules are installed,
174-
``${CMAKE_INSTALL_LIBDIR}${PYMOD_INSTALL_LIBDIR}/pcmsolver``. *If not set*,
175-
python modules installed to default ``${CMAKE_INSTALL_BINDIR}`` (i.e., ``bin``).
173+
``${CMAKE_INSTALL_LIBDIR}/${PYMOD_INSTALL_LIBDIR}/pcmsolver``. *If not set*,
174+
python modules installed to default ``${CMAKE_INSTALL_LIBDIR}/python/pcmsolver``.
176175

177176
Build and test
178177
--------------
@@ -183,13 +182,13 @@ To compile and link, just go to the build directory and run:
183182
184183
make -j N
185184
186-
where `N` is the number of cores you want to use when building.
185+
where ``N`` is the number of cores you want to use when building.
187186

188187
.. note::
189188

190189
Building on more than one core can sometimes result in a "race condition"
191190
and a crash. If that happens, please report the problem as an issue on our
192-
issue tracker on GitHub. Running `make` on a single core might get you through
191+
issue tracker on GitHub. Running ``make`` on a single core might get you through
193192
compilation.
194193

195194
To run the whole test suite:

0 commit comments

Comments
 (0)