Last active
April 1, 2021 03:04
-
-
Save petrstepanov/009a970bcdb031e27b72a7e31968c5d7 to your computer and use it in GitHub Desktop.
Install CERN ROOT v.6.22.08 on Fedora with Debug symbols
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Install dependencies | |
sudo dnf -y groupinstall "Development Tools" "Development Libraries" | |
sudo dnf -y install git cmake3 gcc-c++ gcc binutils libX11-devel libXpm-devel libXft-devel libXext-devel python-devel openssl-devel | |
sudo dnf -y install libuuid-devel redhat-lsb-core gcc-gfortran pcre-devel mesa-libGL-devel mesa-libGLU-devel glew-devel ftgl-devel mysql-devel fftw-devel cfitsio-devel graphviz-devel avahi-compat-libdns_sd-devel openldap-devel python-devel python3-numpy libxml2-devel gsl-devel R-devel R-Rcpp-devel R-RInside-devel | |
# Download ROOT v6.22.08 (-O overwrite existing file) | |
cd ~/Downloads | |
wget -O root_v6.22.08.source.tar.gz https://root.cern/download/root_v6.22.08.source.tar.gz | |
# Unpack ROOT archive | |
mkdir -p ~/Source && cd ~/Source | |
tar -xvf ~/Downloads/root_v6.22.08.source.tar.gz | |
# Create install and build directories | |
rm -rf ~/Applications/root-6.22.08 && mkdir -p ~/Applications/root-6.22.08 | |
rm -rf ~/Source/root-6.22.08-build && mkdir -p ~/Source/root-6.22.08-build && cd ~/Source/root-6.22.08-build | |
# Unset environment libraries (if previously installed ROOT) | |
unset ROOTSYS | |
unset LD_LIBRARY_PATH | |
# Compile ROOT | |
cmake -Dall=ON -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=~/Applications/root-6.22.08 ~/Source/root-6.22.08 | |
cmake --build . --target install -- -j$(nproc) | |
# Source ROOT | |
cd ~/Applications/root-6.22.08 | |
echo source `find $(pwd) -name "thisroot.sh"` >> ~/.bashrc | |
source ~/.bashrc |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
How to install: