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/libtiff.so: 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.

Cheers!

Is libtiff.so 32 or 64 bits then?

Cheers,
D

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.

Hi,

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

Cheers,
D

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

$ file /usr/lib/libtiff.so
/usr/lib/libtiff.so: symbolic link to libtiff.so.5.2.6
$ file /usr/lib/libtiff.so.5.2.6
/usr/lib/libtiff.so.5.2.6: 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.

Sure!


$ file /usr/lib/libtiff.so
/usr/lib/libtiff.so: symbolic link to libtiff.so.5.2.0
$ file /usr/lib/libtiff.so.5.2.0
/usr/lib/libtiff.so.5.2.0: 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/liblzma.so
-- 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.
-- Could NOT find OCaml (missing:  OCAMLFIND OCAML_VERSION OCAML_STDLIB_PATH) 
-- Could NOT find OCaml (missing:  OCAMLFIND OCAML_VERSION OCAML_STDLIB_PATH) 
-- 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/libtiff.so’, needed by lib/libASImage.so'. 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

/usr/lib/libtiff.so

to

/usr/lib64/libtiff.so.5

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.