_ROOT Version:6.12.04
_Platform:MacOS Sierra 10.12.6
_Compiler: gcc 4.2.1
I have been trying to install pyroot with python 3.6.5 installed from Anaconda on MacOS Sierra. Every time
, in python, I got the error message attached in the end. This is an identical problem in PyRoot crashes with ROOT 6.11/02 and Python3 The original author didn’t comment on whether he/she fixed the problem. However, the discussion ended where another person having the same issue.
I did try all the suggestions mentioned there. I install via
cmake -DPYTHON_EXECUTABLE=/Users/myusername/anaconda3/bin/python3.6 ~/Downloads/root-6.12.04/
and I also tried
cmake -Dall=On -DPYTHON_EXECUTABLE=/Users/myusername/anaconda3/bin/python -DPYTHON_INCLUDE_DIR=/Users/myusername/anaconda3/include/python3.6m -DPYTHON_LIBRARY=/Users/myusername/anaconda3/lib/libpython3.6m.dylib -Dpython3=ON ~/Downloads/root-6.12.04/
To make sure I have the same python/compiler version. This is the output from python:
$python Python 3.6.5 |Anaconda, Inc.| (default, Apr 26 2018, 08:42:37) [GCC 4.2.1 Compatible Clang 4.0.1 (tags/RELEASE_401/final)] on darwin
while gcc --version
gave me
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1 Apple LLVM version 9.0.0 (clang-900.0.39.2) Target: x86_64-apple-darwin16.7.0 Thread model: posix InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
For python related path in CMakeCache.txt
are:
PYTHON_EXECUTABLE:FILEPATH=/Users/myusername/anaconda3/bin/python PYTHON_EXECUTABLE-CACHED:STRING=/Users/myusername/anaconda3/bin/python PYTHON_INCLUDE_DIR:PATH=/Users/myusername/anaconda3/include/python3.6m PYTHON_INCLUDE_DIR-CACHED:STRING=/Users/myusername/anaconda3/include/python3.6m PYTHON_LIBRARY:FILEPATH=/Users/myusername/anaconda3/lib/libpython3.6m.dylib PYTHON_LIBRARY-CACHED:STRING=/Users/myusername/anaconda3/lib/libpython3.6m.dylib PYTHON_LIBRARY_DEBUG:FILEPATH=PYTHON_LIBRARY_DEBUG-NOTFOUND
All of them correctly point to anaconda python 3.6. Did I do anything wrong?
The same issue also appeared in here. One person suggested to check the compiler. However, the original author solved the problem by abandoning anaconda.
Below is the error message from import ROOT
*** Break *** segmentation violation
[/usr/lib/system/libsystem_platform.dylib] _sigtramp (no debug info)
[<unknown binary>] (no debug info)
[/Users/myusername/anaconda3/lib/libpython3.6m.dylib] PyUnicode_InternFromString (no debug info)
[/Users/myusername/local/root-6.12.04/lib/libPyROOT.so] PyROOT::CreatePyStrings() /Users/myusername/Downloads/root-6.12.04/bindings/pyroot/src/PyStrings.cxx:64
[/Users/myusername/local/root-6.12.04/lib/libPyROOT.so] PyInit_libPyROOT /Users/myusername/Downloads/root-6.12.04/bindings/pyroot/src/RootModule.cxx:848
[/Users/myusername/anaconda3/bin/python] _PyImport_LoadDynamicModuleWithSpec (no debug info)
[/Users/myusername/anaconda3/bin/python] _imp_create_dynamic (no debug info)
[/Users/myusername/anaconda3/bin/python] PyCFunction_Call (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalCodeWithName (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyFunction_FastCallDict (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyObject_FastCallDict (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyObject_CallMethodIdObjArgs (no debug info)
[/Users/myusername/anaconda3/bin/python] PyImport_ImportModuleLevelObject (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalCodeWithName (no debug info)
[/Users/myusername/anaconda3/bin/python] builtin_exec (no debug info)
[/Users/myusername/anaconda3/bin/python] PyCFunction_Call (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalCodeWithName (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyFunction_FastCallDict (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyObject_FastCallDict (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyObject_CallMethodIdObjArgs (no debug info)
[/Users/myusername/anaconda3/bin/python] PyImport_ImportModuleLevelObject (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalCodeWithName (no debug info)
[/Users/myusername/anaconda3/bin/python] builtin_exec (no debug info)
[/Users/myusername/anaconda3/bin/python] PyCFunction_Call (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalCodeWithName (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] fast_function (no debug info)
[/Users/myusername/anaconda3/bin/python] call_function (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyFunction_FastCallDict (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyObject_FastCallDict (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyObject_CallMethodIdObjArgs (no debug info)
[/Users/myusername/anaconda3/bin/python] PyImport_ImportModuleLevelObject (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalFrameDefault (no debug info)
[/Users/myusername/anaconda3/bin/python] _PyEval_EvalCodeWithName (no debug info)
[/Users/myusername/anaconda3/bin/python] PyRun_InteractiveOneObjectEx (no debug info)
[/Users/myusername/anaconda3/bin/python] PyRun_InteractiveLoopFlags (no debug info)
[/Users/myusername/anaconda3/bin/python] PyRun_AnyFileExFlags (no debug info)
[/Users/myusername/anaconda3/bin/python] Py_Main (no debug info)
[/Users/myusername/anaconda3/bin/python] main (no debug info)
[/usr/lib/system/libdyld.dylib] start (no debug info)
[<unknown binary>] (no debug info)