Hi @uzair90,
can you please share the full output of the cmake configuration (including the command you use to configure the build) and also possibly some lines around/before the error message appears?
Also note that unless you have specific needs you don’t need to compile ROOT from source, there are several more painless installation methods listed at https://root.cern/install , e.g. you could install ROOT as a conda package.
And I use this to run the installation by the second command:
cmake --build . -- install -j4
I have attached the output of the two commands for your reference.
I saw the conda install option recently. I am not a python use so I was not aware of that. I use ROOT in conjunction with some other softwares/simulations. If I install ROOT from conda would I still have access to this environment variable: export ROOTSYS=/usr/local/build_root command2_output.txt (960.1 KB) command1_output.txt (11.9 KB)
Traditionally, /usr/local/ isn’t a user-writable directory, this should only be written to by the superuser (user root); as such you might want to build in your home directory as a regular user and then run sudo cmake --build . install -j4aftercmake --build . -j4 (without sudo).
That said: do you have /usr/local/build_root/lib/libvectorDict.so? Your log says [ 77%] Linking CXX shared library ../../lib/libvectorDict.so which should have created it. What does ls -l /usr/local/build_root/lib/libvectorDict.so show?
That is true. Traditionally /usr/local is not a user-writable directory. However, in my case I have made it as such so that I have full permissions to write in it as a user so that I do not have use sudo or su.
If I do ls -l /usr/local/build_root/lib/libvectorDict.so there is no such file. However, I do find this file:
ls -l /usr/local/build_root/lib/libvectorDict.rootmap -rw-rw-r-- 1 uzairlatif uzairlatif 427 Nov 10 12:49 /usr/local/build_root/lib/libvectorDict.rootmap
I would like to add that I did find this other post for a user who had a similar problem: Error with libvectorDict.so
However, the binary pointed out there was for GCC 9.2 and I have GCC 9.3.
Super weird - CMake tells us that it built libvectorDict.so yet now it’s gone. What happens if you re-run cmake --build . -- install -j4? Say a couple of times? Does it state Linking CXX shared library ../../lib/libvectorDict.so all the time? Do you ever see /usr/local/build_root/lib/libvectorDict.so being generated?
So when I re-ran the command: cmake --build . -- install -j4 three times and each time I got the same error with this message: [ 77%] Linking CXX shared library ../../lib/libvectorDict.so .
libvectorDict.so is never generated. Let me know what else I can try.
I also made a mistake earlier in reporting what OS I have. I Ubuntu 20.04 LTS not 19.10.
Hmm, well, that solves it for you but not for me - I still don’t understand why the file was removed after it got created. But okay, solve for you, and we will debug this once we see this on our machines!