I don’t know whether there is a “cluster version root”, so I just install ROOT6 using the same way in cluster (local path without root) as I did in laptop. Using commands,
cmake -all=ON ~/tools/root-source
make -j4
But there is a error,
[ 49%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetLoweringBase.cpp.o
[ 49%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetOptionsImpl.cpp.o
[ 49%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetPassConfig.cpp.o
[ 49%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetRegisterInfo.cpp.o
[ 49%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TargetSchedule.cpp.o
[ 50%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/TwoAddressInstructionPass.cpp.o
[ 50%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/UnreachableBlockElim.cpp.o
[ 50%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/VirtRegMap.cpp.o
[ 50%] Building CXX object interpreter/llvm/src/lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/WinEHPrepare.cpp.o
[ 50%] Linking CXX static library ../../../../lib/libclangSema.a
[ 50%] Linking CXX static library ../libLLVMCodeGen.a
[ 50%] Built target clangSema
[ 50%] Built target LLVMCodeGen
make: *** [all] Error 2
I don’t know why. I use “linuxbrew” for installing packages locally. Here is my gcc and clang,
The ‘root’ executable is not built with ‘minimal’ (it requires graphics, which is switched off with minimal).
The supported way of building is CMake. Can you provide the complete output of your first attempt? The few lines you pasted do not include the actual error.
I think in cluster, I have to disable x11, so that there is no graphics and I should use root.exe instead using root ?
And how can I disable x11 using CMake?
And, I tried CMake with clang and gcc both. let me provide clang out put first. The screen out put is “clang_result.log” and the other two files may help. ( I find I can not upload file with extension “.log” so I instead them with extension “.txt”) CMakeOutput.txt (17.5 KB) CMakeError.txt (1.94 KB) clang_result.txt (714 Bytes)
And these are output of gcc compile. the “gcc_result” is the screen output of “cmake” and the “gcc_result2” is the screen output of “make”.
I guess there are three possibilities of error:
Lack of some optional packages like libldap-dev but I can’t install them. ( I didn’t find the source so I can’t install them locally).
But I think the installation should ignore them (when they are missed) since they are optional.
I still do not see the actual build error. The file gcc_result2 is truncated at [ 54%].
I do not understand what compiler are you using? gcc or clang? Some logs are for gcc and some for clang.
I do not see the problem with X11. The library is found in /usr/lib64/libX11.so. Why you want to disable it? To disable it you you can add into the cmake command ‘-Dx11=OFF’.
I am probably as confused as you are. It would be nice if we tackle one problem at the time. What you want to achieve, how you do it (all the commands), and what errors you get.
Sorry for late reply. I just find iTerm2 provide a better output so I tried again.
Let me answer your questions one by one,
The problem is just that the installation stop. I will show you a full screen output result.
I tried both clang and gcc and neither work. The first reply is clang result and the second is gcc result.
I am not sure. Maybe you are right.
Ok, let’s deal with installation with gcc first. I will provide a full commands inputed and result.
I want to install root 6 with pyroot, and the commands and output is too long, so I put them in the attachment. Makefile.txt (202 KB) gcc.txt (210 KB)
This is much better, thanks. The error has to do with a bad or incomplete installation of X11.
/home/huangli/.linuxbrew/bin/ld: warning: libxcb.so.1, needed by /usr/lib64/libX11.so, not found (try using -rpath or -rpath-link)
/home/huangli/.linuxbrew/bin/ld: warning: libfontconfig.so.1, needed by /usr/lib64/libXft.so, not found (try using -rpath or -rpath-link)
/home/huangli/.linuxbrew/bin/ld: warning: libXrender.so.1, needed by /usr/lib64/libXft.so, not found (try using -rpath or -rpath-link)
/usr/lib64/libXft.so: undefined reference to `FcFreeTypeCharIndex'
/usr/lib64/libXft.so: undefined reference to `FcPatternAddString'
/usr/lib64/libXft.so: undefined reference to `XRenderCompositeString8'
/usr/lib64/libXft.so: undefined reference to `XRenderFreeGlyphs'
/usr/lib64/libXft.so: undefined reference to `XRenderChangePicture'
/usr/lib64/libX11.so: undefined reference to `xcb_get_maximum_request_length'
/usr/lib64/libXft.so: undefined reference to `FcNameParse'
...
You can either:
switch off the use of X11 (with -Dx11=OFF), but then ROOT will not have any graphics
fix the installation of X11. Since you are using a mix of system and linuxbrew installation I have not the experience. You need to install properly all these packages:
libx11-dev: for usr/include/X11/Xlib.h and for /usr/lib/libX11.so
libxpm-dev: for /usr/include/X11/xpm.h and for /usr/lib/libXpm.so
libxft-dev: for /usr/include/X11/Xft/Xft.h and for /usr/lib/libXft.so
libxext-dev: for /usr/include/X11/extensions/shape.h and for /usr/lib/libXext.so
See the prerequisite page root.cern.ch/build-prerequisites
/home/huangli/.linuxbrew/bin/ld: warning: libpcre.so.0, needed by ../lib/libCore.so, not found (try using -rpath or -rpath-link)
/home/huangli/.linuxbrew/bin/ld: warning: liblzma.so.0, needed by ../lib/libCore.so, not found (try using -rpath or -rpath-link)
said a lack of “pcre” and “lzma”, but I have installed them.
Can you make a test for me. You could define the environment CMAKE_PREFIX_PATH=/home/huangli/.linuxbrew before invoking cmake in a clean build area. In this case all packages will be search in /home/huangli/.linuxbrew
But after I add DYLD_LIBRARY_PATH and LD_LIBRARY_PATH with /home/huangli/.linuxbrew/lib and /home/huangli/.linuxbrew/lib64 in the .bash_profile and source the .bash_profile, most of the commands like ls, vim lead to Segmentation fault
This is somehow expected. Mixing executables from /usr/bin with the libraries installed with libuxbrew is perhaps not a good idea. Did you also prefix PATH with /home/huangli/.linuxbrew/bin ?