Back to home page

EIC code displayed by LXR

 
 

    


Warning, /snippets/RootExamples/helloroot/README.md is written in an unsupported language. File is not indexed.

0001 ### Helloroot
0002 
0003 A small skeleton to demonstrate how to link standalone C++ code to ROOT libraries. To use, rename and adapt the source files and `CMakeLists.txt` to your project.
0004 
0005 To build using cmake, create a build directory, navigate to it and run cmake. e.g.:
0006 
0007 ```
0008 mkdir build
0009 cd build
0010 cmake .. 
0011 make 
0012 ```
0013 You can specify a number of parallel build threads with the -j flag, e.g.
0014 ```
0015 make -j4
0016 ```
0017 
0018 You can specify an install directory to cmake with
0019 -DCMAKE_INSTALL_PREFIX=<path>
0020 then, after building, 
0021 ```
0022 make install
0023 ```
0024 to install the headers and libraries under that location.
0025 There is no "make uninstall" but (on Unix-like systems)
0026 you can do
0027 ```
0028 xargs rm < install_manifest.txt
0029 ```
0030 from the cmake build directory.
0031 
0032 Note: The particular cmake configuration is designed to automatically use all the compile options needed for root, e.g. the c++ std version. On some systems this mechanism fails and you may have to uncomment l. 30 or l. 31 in `CMakeLists.txt`.
0033 
0034