Skip to content

Commit

Permalink
updating doc for 8.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
thattil committed Nov 10, 2023
1 parent 42dc108 commit 34f2301
Show file tree
Hide file tree
Showing 6 changed files with 213 additions and 89 deletions.
30 changes: 22 additions & 8 deletions _sources/dependencies.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,24 +13,36 @@ To use the basic building blocks, meaning sls_detector_get/put and
the shared libraries these are needed:

* Linux, preferably recent kernel (currently no cross platform support)
* CMake > 3.12
* CMake > 3.14
* C++11 compatible compiler. (We test with gcc and clang)
* ZeroMQ version 4

-----------------------
GUI
Python bindings
-----------------------

* Qt 5.9
* Qwt 6.1.5 (packaged in libs/)
* Python > 3.6
* pybind11 2.11.0 (packaged in libs)

.. note ::
Refer :ref:`pybind11 notes. <pybind for different slsDetectorPackage versions>`
-----------------------
Python bindings
ZeroMQ
-----------------------

* Python > 3.6
* pybind11 (packaged in libs/)
* Zeromq 4.3.4 (packaged in libs)

.. note ::
Refer :ref:`zeromq notes. <zeromq for different slsDetectorPackage versions>`
-----------------------
GUI
-----------------------

* Qt 5.9
* Qwt 6.1.5 (packaged in libs)

-----------------------
Moench executables
Expand All @@ -55,3 +67,5 @@ Packaged in libs/
* catch2 (unit testing)
* rapidjson (streaming from receiver)
* pybind11 (python bindings)
* qwt (gui plotting)
* libzmq (streaming to/from receiver)
111 changes: 78 additions & 33 deletions _sources/installation.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -57,31 +57,16 @@ We have three different packages available:
Build from source
-------------------


1. Download Source Code from github
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. code-block:: bash
git clone https://github.com/slsdetectorgroup/slsDetectorPackage.git --branch 6.1.1
.. note ::
| **Pybind for Python**
| v7.0.0+:
| pybind11 packaged into 'libs/pybind'. No longer a submodule. No need for "recursive" or "submodule update".
|
| Older versions:
| pybind11 is a submodule. Must be cloned using "recursive" and updated when switching between versions using the following commands.
.. code-block:: bash
# clone using recursive to get pybind11 submodule
git clone --recursive https://github.com/slsdetectorgroup/slsDetectorPackage.git
# update submodule when switching between releases
cd slsDetectorPackage
git submodule update --init
For v6.x.x of slsDetectorPackage and older, refer :ref:`pybind11 notes on cloning. <pybind for different slsDetectorPackage versions>`
.. _build from source using cmake:

Expand Down Expand Up @@ -118,20 +103,21 @@ Instead of the cmake command, one can use ccmake to get a list of options to con
ccmake ..
# choose the options
# first press [c] - configure
# first press [c] - configure (maybe multiple times till you see [g])
# then press [g] - generate
=============================== ===========================================
=============================== ===============================
Example cmake options Comment
=============================== ===========================================
=============================== ===============================
-DSLS_USE_PYTHON=ON Python
-DPython_FIND_VIRTUALENV=ONLY Python from only the conda environment
-DZeroMQ_HINT=/usr/lib64 Use system zmq instead
-DPython_FIND_VIRTUALENV=ONLY Python from the conda env
-DSLS_USE_GUI=ON GUI
=============================== ===========================================
=============================== ===============================

.. note ::
For v7.x.x of slsDetectorPackage and older, refer :ref:`zeromq notes for cmake option to hint library location. <zeromq for different slsDetectorPackage versions>`
Build using in-built cmk.sh script
Expand All @@ -142,9 +128,9 @@ Build using in-built cmk.sh script
The binaries are generated in slsDetectorPackage/build/bin directory.
Usage: ./cmk.sh [-b] [-c] [-d <HDF5 directory>] [e] [g] [-h] [i] [-j <Number of threads>]
[-k <CMake command>] [-l <Install directory>] [m] [n] [-p] [-q <Zmq hint directory>]
[r] [s] [t] [u] [z]
Usage: $0 [-b] [-c] [-d <HDF5 directory>] [-e] [-g] [-h] [-i]
[-j <Number of threads>] [-k <CMake command>] [-l <Install directory>]
[-m] [-n] [-p] [-r] [-s] [-t] [-u] [-z]
-[no option]: only make
-b: Builds/Rebuilds CMake files normal mode
-c: Clean
Expand All @@ -159,7 +145,6 @@ Build using in-built cmk.sh script
-m: Manuals
-n: Manuals without compiling doxygen (only rst)
-p: Builds/Rebuilds Python API
-q: Zmq hint directory
-r: Build/Rebuilds only receiver
-s: Simulator
-t: Build/Rebuilds only text client
Expand All @@ -176,9 +161,13 @@ Build using in-built cmk.sh script
# new build, python and compile in parallel:
./cmk.sh -cbpj5
#To use the system zmq (/usr/lib64) instead
./cmk.sh -cbj5 -q /usr/lib64
#For rebuilding only certain sections
./cmk.sh -tg #only text client and gui
./cmk.sh -r #only receiver
.. note ::
For v7.x.x of slsDetectorPackage and older, refer :ref:`zeromq notes for cmk script option to hint library location. <zeromq for different slsDetectorPackage versions>`
Build on old distributions
Expand All @@ -191,7 +180,7 @@ using this compiler
.. code-block:: bash
#Create an environment with the dependencies
conda create -n myenv gxx_linux-64 cmake zmq
conda create -n myenv gxx_linux-64 cmake
conda activate myenv
# outside slsDetecorPackage folder
Expand All @@ -200,6 +189,11 @@ using this compiler
make -j12
.. note ::
For v7.x.x of slsDetectorPackage and older, refer :ref:`zeromq notes for dependencies for conda. <zeromq for different slsDetectorPackage versions>`
Build slsDetectorGui (Qt5)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Expand Down Expand Up @@ -228,9 +222,9 @@ Build slsDetectorGui (Qt5)
# create environment to compile
# on rhel7
conda create -n slsgui zeromq gxx_linux-64 gxx_linux-64 mesa-libgl-devel-cos6-x86_64 qt
conda create -n slsgui gxx_linux-64 gxx_linux-64 mesa-libgl-devel-cos6-x86_64 qt
# on fedora or newer systems
conda create -n slsgui zeromq qt
conda create -n slsgui qt
# when using conda compilers, would also need libgl, but no need for it on fedora unless maybe using it with ROOT
Expand All @@ -246,6 +240,9 @@ Build slsDetectorGui (Qt5)
cd slsDetectorPackage
./cmk.sh -cbgj9
.. note ::
For v7.x.x of slsDetectorPackage and older, refer :ref:`zeromq notes for dependencies for conda. <zeromq for different slsDetectorPackage versions>`
Expand All @@ -270,3 +267,51 @@ is to use conda
make docs # generate API docs and build Sphinx RST
make rst # rst only, saves time in case the API did not change
Pybind and Zeromq
^^^^^^^^^^^^^^^^^^^

.. _pybind for different slsDetectorPackage versions:


| **Pybind for Python**
| v8.0.0+:
| pybind11 (v2.11.0) is built
| * by default from tar file in repo (libs/pybind/v2.11.0.tar.gz)
| * or use option SLS_FETCH_PYBIND11_FROM_GITHUB `[link] <https://github.com/pybind/pybind11>`__.
|
| v7.x.x:
| pybind11 packaged into 'libs/pybind'. No longer a submodule. No need for "recursive" or "submodule update".
|
| Older versions:
| pybind11 is a submodule. Must be cloned using "recursive" and updated when switching between versions using the following commands.
.. code-block:: bash
# Note: Only for v6.x.x versions and older
# clone using recursive to get pybind11 submodule
git clone --recursive https://github.com/slsdetectorgroup/slsDetectorPackage.git
# update submodule when switching between releases
cd slsDetectorPackage
git submodule update --init
.. _zeromq for different slsDetectorPackage versions:



| **Zeromq**
| v8.0.0+:
| zeromq (v4.3.4) is built
| * by default from tar file in repo (libs/libzmq/libzmq-4.3.4.tar.gz)
| * or use option SLS_FETCH_ZMQ_FROM_GITHUB `[link] <https://github.com/zeromq/libzmq.git>`__.
|
| v7.x.x and older:
| zeromq must be installed and one can hint its location using
| * cmake option:'-DZeroMQ_HINT=/usr/lib64' or
| * option '-q' in cmk.sh script: : ./cmk.sh -cbj5 -q /usr/lib64
| * 'zeromq' dependencies when installing using conda
40 changes: 29 additions & 11 deletions dependencies.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,9 @@
<li class="toctree-l1"><a class="reference internal" href="installation.html">Installation</a></li>
<li class="toctree-l1 current"><a class="current reference internal" href="#">Dependencies</a><ul>
<li class="toctree-l2"><a class="reference internal" href="#core">Core</a></li>
<li class="toctree-l2"><a class="reference internal" href="#gui">GUI</a></li>
<li class="toctree-l2"><a class="reference internal" href="#python-bindings">Python bindings</a></li>
<li class="toctree-l2"><a class="reference internal" href="#zeromq">ZeroMQ</a></li>
<li class="toctree-l2"><a class="reference internal" href="#gui">GUI</a></li>
<li class="toctree-l2"><a class="reference internal" href="#moench-executables">Moench executables</a></li>
<li class="toctree-l2"><a class="reference internal" href="#documentation">Documentation</a></li>
<li class="toctree-l2"><a class="reference internal" href="#packaged-in-libs">Packaged in libs/</a></li>
Expand Down Expand Up @@ -150,27 +151,42 @@ <h2>Core<a class="headerlink" href="#core" title="Permalink to this heading">
<blockquote>
<div><ul class="simple">
<li><p>Linux, preferably recent kernel (currently no cross platform support)</p></li>
<li><p>CMake &gt; 3.12</p></li>
<li><p>CMake &gt; 3.14</p></li>
<li><p>C++11 compatible compiler. (We test with gcc and clang)</p></li>
<li><p>ZeroMQ version 4</p></li>
</ul>
</div></blockquote>
</section>
<section id="gui">
<h2>GUI<a class="headerlink" href="#gui" title="Permalink to this heading"></a></h2>
<section id="python-bindings">
<h2>Python bindings<a class="headerlink" href="#python-bindings" title="Permalink to this heading"></a></h2>
<blockquote>
<div><ul class="simple">
<li><p>Qt 5.9</p></li>
<li><p>Qwt 6.1.5 (packaged in libs/)</p></li>
<li><p>Python &gt; 3.6</p></li>
<li><p>pybind11 2.11.0 (packaged in libs)</p></li>
</ul>
</div></blockquote>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>Refer <a class="reference internal" href="installation.html#pybind-for-different-slsdetectorpackage-versions"><span class="std std-ref">pybind11 notes.</span></a></p>
</div>
</section>
<section id="python-bindings">
<h2>Python bindings<a class="headerlink" href="#python-bindings" title="Permalink to this heading"></a></h2>
<section id="zeromq">
<h2>ZeroMQ<a class="headerlink" href="#zeromq" title="Permalink to this heading"></a></h2>
<blockquote>
<div><ul class="simple">
<li><p>Python &gt; 3.6</p></li>
<li><p>pybind11 (packaged in libs/)</p></li>
<li><p>Zeromq 4.3.4 (packaged in libs)</p></li>
</ul>
</div></blockquote>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>Refer <a class="reference internal" href="installation.html#zeromq-for-different-slsdetectorpackage-versions"><span class="std std-ref">zeromq notes.</span></a></p>
</div>
</section>
<section id="gui">
<h2>GUI<a class="headerlink" href="#gui" title="Permalink to this heading"></a></h2>
<blockquote>
<div><ul class="simple">
<li><p>Qt 5.9</p></li>
<li><p>Qwt 6.1.5 (packaged in libs)</p></li>
</ul>
</div></blockquote>
</section>
Expand Down Expand Up @@ -200,6 +216,8 @@ <h2>Packaged in libs/<a class="headerlink" href="#packaged-in-libs" title="Perma
<li><p>catch2 (unit testing)</p></li>
<li><p>rapidjson (streaming from receiver)</p></li>
<li><p>pybind11 (python bindings)</p></li>
<li><p>qwt (gui plotting)</p></li>
<li><p>libzmq (streaming to/from receiver)</p></li>
</ul>
</div></blockquote>
</section>
Expand Down
Loading

0 comments on commit 34f2301

Please sign in to comment.