Building ROOT: Difference between revisions

From pCT
Mri083 (talk | contribs)
Created page with "In the pCT project we need to use a version of ROOT which is compiled with c++17 in order to build packages with ROOT dependencies with c++17 standard. . ROOT implements a c..."
 
Mri083 (talk | contribs)
mNo edit summary
Line 1: Line 1:
[[Main Page]] -> [[Control & Readout Software Documentation and Howto's]] -> [[Building ROOT]]
In the pCT project we need to use a version of ROOT which is compiled with c++17 in order to build packages with ROOT dependencies with c++17 standard. .  
In the pCT project we need to use a version of ROOT which is compiled with c++17 in order to build packages with ROOT dependencies with c++17 standard. .  



Revision as of 16:49, 30 January 2020

Main Page -> Control & Readout Software Documentation and Howto's -> Building ROOT


In the pCT project we need to use a version of ROOT which is compiled with c++17 in order to build packages with ROOT dependencies with c++17 standard. .

ROOT implements a custom adaptor to std::string_view if not compiled with c++17 and this conflicts with the real one if a packages uses c++17 standard and ROOT libraries/includes.

<syntaxhighlight lang="bash">

  1. clone the repository

git clone http://github.com/root-project/root.git

  1. choose a build directory

mkdir build_root; cd build_root

  1. configure: choose install target, on the lab machine we need to disable asimage for some reason
  2. the important flag is the C++ standard

cmake -D CMAKE_INSTALL_PREFIX=/opt/root -D asimage=OFF -D CMAKE_CXX_STANDARD=17 ../root

  1. build

make -j

  1. install (eventually using sudo)

make install </syntaxhighlight>