Error installing ROOT 6.10.00

I recently compiled and installed the latest ROOT v6-10-00.

During the installation step I encountered these errors:

...
-- Installing: /cern/root-6.10.00/lib/cmdLineUtils.py
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/lib/python2.7/py_compile.py", line 181, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/py_compile.py", line 173, in main
    compile(filename, doraise=True)
  File "/usr/lib/python2.7/py_compile.py", line 106, in compile
    with open(file, 'U') as f:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/cmdLineUtils.py'
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/lib/python2.7/py_compile.py", line 181, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/py_compile.py", line 173, in main
    compile(filename, doraise=True)
  File "/usr/lib/python2.7/py_compile.py", line 106, in compile
    with open(file, 'U') as f:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/cmdLineUtils.py'
-- Installing: /cern/root-6.10.00/bin/rootcling
-- Set runtime path of "/cern/root-6.10.00/bin/rootcling" to ""
-- Installing: /cern/root-6.10.00/lib/libPyROOT_rdict.pcm
-- Installing: /cern/root-6.10.00/lib/libPyROOT.rootmap
-- Installing: /cern/root-6.10.00/lib/libPyROOT.so
-- Set runtime path of "/cern/root-6.10.00/lib/libPyROOT.so" to ""
-- Installing: /cern/root-6.10.00/lib/libJupyROOT.so
-- Set runtime path of "/cern/root-6.10.00/lib/libJupyROOT.so" to ""
-- Installing: /cern/root-6.10.00/lib/ROOT.py
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/lib/python2.7/py_compile.py", line 181, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/py_compile.py", line 173, in main
    compile(filename, doraise=True)
  File "/usr/lib/python2.7/py_compile.py", line 106, in compile
    with open(file, 'U') as f:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/ROOT.py'
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/lib/python2.7/py_compile.py", line 181, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/py_compile.py", line 173, in main
    compile(filename, doraise=True)
  File "/usr/lib/python2.7/py_compile.py", line 106, in compile
    with open(file, 'U') as f:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/ROOT.py'
-- Installing: /cern/root-6.10.00/lib/_pythonization.py
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/lib/python2.7/py_compile.py", line 181, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/py_compile.py", line 173, in main
    compile(filename, doraise=True)
  File "/usr/lib/python2.7/py_compile.py", line 106, in compile
    with open(file, 'U') as f:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/_pythonization.py'
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/lib/python2.7/py_compile.py", line 181, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/py_compile.py", line 173, in main
    compile(filename, doraise=True)
  File "/usr/lib/python2.7/py_compile.py", line 106, in compile
    with open(file, 'U') as f:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/_pythonization.py'
-- Installing: /cern/root-6.10.00/lib/cppyy.py
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/lib/python2.7/py_compile.py", line 181, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/py_compile.py", line 173, in main
    compile(filename, doraise=True)
  File "/usr/lib/python2.7/py_compile.py", line 106, in compile
    with open(file, 'U') as f:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/cppyy.py'
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/lib/python2.7/py_compile.py", line 181, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/py_compile.py", line 173, in main
    compile(filename, doraise=True)
  File "/usr/lib/python2.7/py_compile.py", line 106, in compile
    with open(file, 'U') as f:
IOError: [Errno 2] No such file or directory: '/usr/local/lib/cppyy.py'
...

When starting root, the right version is displayed:

   ------------------------------------------------------------
  | Welcome to ROOT 6.10/00                http://root.cern.ch |
  |                               (c) 1995-2017, The ROOT Team |
  | Built for linuxx8664gcc                                    |
  | From tag v6-10-00, 13 June 2017                            |
  | Try '.help', '.demo', '.license', '.credits', '.quit'/'.q' |
   ------------------------------------------------------------

Surprisingly enough PyROOT seems to work:

>>> import ROOT
>>> ROOT.ROOT.Experimental
>>> ROOT.ROOT.Experimental.TDataFrame
<class 'ROOT.ROOT.Experimental.TDataFrame'>

Hi,

thanks for reporting this issue. That module is common to several root command line utils such as rootls, rootcp and so on. It is not used anywhere else: the rest of the ROOT installation will work perfectly, including PyROOT, as you could verify.
I opened ROOT-8836 to follow this up. Could you share the commands you used to build and install as well as the details of your platform?

Cheers,
D

Was corrected on Wednesday on the master and 6.10 branches. The consequence without the correction is very minor. It means that python needs to compiler to byte code the first time you use cmdLineUtils.py.

1 Like

These are the commands I used to build and install it, just to assure this is the same bug and I’m not doing anything else I shouldn’t:

cmake -D all=ON -Dmathmore=ON -D roofit=ON -D minuit2=ON -D cxx14=ON -D r=ON -D imt=ON $GIT_DIR
cmake --build . -- -j7
cmake -D CMAKE_INSTALL_PREFIX=$INSTALL_DIR -P cmake_install.cmake

Thanks, this is exactly what has been fixed. The problem was that the initial (default) ${CMAKE_INSTALL_PREFIX} was used in the Python compilation command at configuration, while what is needed is to resolve ${CMAKE_INSTALL_PREFIX} at the installation since to provide a different one.

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