Issue Compiling ROOT v6.10.02 on CENTOS7

Hi All,

I am attempting to update my ROOT install to the newest production version and receive the error:

/usr/lib/ error adding symbols: File in wrong format

This is the only error in the compilation as all other pieces compile correctly. I have been digging online and guess it might be a 32-bit vs 64-bit issue, but am not sure. Any help you can offer would be greatly appreciated.


Is 32 or 64 bits then?


I believe it is 32 because there is an alternate libtiff in /usr/lib64/, however I do not know where/how to tell ROOT to compile with that library.


can you install the 64bits version of that library?
Did you use CMake to configure ROOT, right?


Can you please provide more precise information? For example, this is what is on my own system:

$ file /usr/lib/
/usr/lib/ symbolic link to
$ file /usr/lib/
/usr/lib/ ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, stripped

Please paste here the equivalent for your system, as well as the configuration you have for ROOT (output of CMake configure phase). Without this information, there is very little we can do to help you.


$ file /usr/lib/
/usr/lib/ symbolic link to
$ file /usr/lib/
/usr/lib/ ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), dynamically linked, BuildID[sha1]=a1302aa0f59eeaf014d5f09055411e9e4f8caeaa, stripped

I use cmake3 and the output is:

$ cmake3 ../root
-- Found GCC. Major version 4, minor version 8
-- Found a 64bit system
-- Found GNU compiler collection
-- ROOT Platform: linux
-- ROOT Architecture: linuxx8664gcc
-- Build Type: RelWithDebInfo
-- Compiler Flags:  -pipe -m64  -Wshadow -Wall -W -Woverloaded-virtual -fsigned-char -fPIC -pthread -std=c++11 -O2 -g -DNDEBUG
-- Looking for ZLib
-- Looking for Freetype
-- Looking for PCRE
-- Looking for LZMA
-- Found LZMA includes at /usr/include
-- Found LZMA library at /usr/lib64/
-- Looking for X11
-- Building AfterImage library included in ROOT itself
-- Looking for GSL
-- Looking for Python
-- Found Python interpreter version 2.7
-- Looking for OpenGL
-- Looking for Graphviz
-- Looking for Bonjour
-- Checking whether Bonjour/Avahi is supported
-- Looking for Kerberos 5
-- Looking for LibXml2
-- Looking for OpenSSL
-- Looking for MySQL
-- Looking for ODBC
-- Looking for PostgreSQL
-- Looking for SQLite
-- Looking for FFTW3
-- Looking for CFITSIO
-- Found CFITSIO version: 3.37
-- Looking for BLAS for optional parts of TMVA
-- A library with BLAS API found.
-- Enabled support for:  asimage astiff bonjour builtin_afterimage builtin_ftgl builtin_gl2ps builtin_glew builtin_llvm builtin_tbb builtin_unuran cling cxx11 exceptions explicitlink fftw3 fitsio fortran genvector gviz imt krb5 ldap mathmore memstat mysql odbc opengl pch pgsql python shadowpw shared sqlite ssl thread tmva x11 xft xml
-- Target triple: x86_64-unknown-linux-gnu
-- Native target architecture is X86
-- Threads disabled.
-- Doxygen disabled.
-- Sphinx disabled.
-- Go bindings disabled.
-- OCaml bindings disabled.
-- Building with -fPIC
-- Constructing LLVMBuild project information
-- Targeting X86
-- Clang version: 3.9.0
-- Cling version (from VERSION file): ROOT_0.4~dev
-- Cling will look for C++ headers in '/usr/lib/gcc/x86_64-redhat-linux/4.8.5/../../../../include/c++/4.8.5:/usr/lib/gcc/x86_64-redhat-linux/4.8.5/../../../../include/c++/4.8.5/x86_64-redhat-linux:/usr/lib/gcc/x86_64-redhat-linux/4.8.5/../../../../include/c++/4.8.5/backward' at runtime.
-- And if not found, will invoke: 'c++' for them.
-- Configuring done
-- Generating done
-- Build files have been written to: /home/cnatzke/Programs/root-build

As you can see from your CMake output and libtiff you have, you are buiding ROOT for a 64bit system, but trying to link to a 32bit libtiff. That is why it is not working. You may be able to get things working by disabling libtiff support if you don’t care about it with -Dastiff=OFF. If you do care, you have to make CMake see your 64bit version of libtiff somewhere, presumably /usr/lib64. Let us know if you still have problems after trying the options above.

I’ve changed the file location in CMakeCache.text to lib64 and a new error occured:

No rule to make target/usr/lib64/’, needed by lib/'. Stop.

any suggestions?

Well, it seems that do not have it installed in /usr/lib64, so changing the CMakeCache is of no help. You have to have a 64bit version of libtiff installed. I would recommend turning off the tiff part with -Dastiff=OFF for now, then you’ll have a working ROOT while you try to understand what is the problem with your setup.

I figured it out. I had to change a line in CMakeCache.txt from




Everything seems to compile fine now. Thanks for all of the help!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.