Install MacOSX Problem

I am attempting to install root v5.34.04 on my Macbook Pro which has OSX 10.6.8. I would like to install it such that it is pyROOT enabled. On the root building site … oot-source it says that to do this you must run:


However, when I run make, many things compile and but an error is thrown giving:
ld: in /usr/bin/python, can’t link with a main executable
collect2: ld returned 1 exit status
make: *** [lib/] Error 1
make: *** Waiting for unfinished jobs…
==> lib/ done

This allows me to run root as version 5.34.04 but when I try to run python and import ROOT I find:

pb-d-128-141-137-115:root_5.34.04 meehan$ python
Python 2.7.1 (r271:86882M, Nov 30 2010, 09:39:13)
[GCC 4.0.1 (Apple Inc. build 5494)] on darwin
Type “help”, “copyright”, “credits” or “license” for more information.

import ROOT
Traceback (most recent call last):
File “”, line 1, in
File “/Users/meehan/bin/root_5.34.04/lib/”, line 85, in
import libPyROOT as _root
ImportError: No module named libPyROOT

So it seems that this originates from the lib/ not being imported properly. Can someone who has successfully installed root with pyROOT enabled on a mac please give me some notes or where this may come from? Thankyou


so it looks like was never build and thus is can also not be found (unless it is in $ROOTSYS/lib after all, but that directory is not part of the PYTHONPATH search path envar).

On Mac, the linker should be fed Python, which is a Mac bundle, not “python”, the executable. Can you show the output of ./configure?


Hi wlav,

I am attaching a file which is the terminal output showing the PYTHONPATH and ROOTSYS/lib contents, in addition to the output of the “./configure” command, and the subsequent “make -j2” command.

Is it possible that I need to set up some more paths that ROOTSYS and PYTHONPATH, or they are set up incorrectly?
MaxOSX1068_InstallProblem_TerminalOutput.txt (32.6 KB)


on my Mac, the two selections are:[quote]Checking for Python.h … /System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
Checking for python2.7, libpython2.7, libpython, python, or Python … /System/Library/Frameworks/Python.framework/Versions/2.7/lib[/quote]
which compares to your case of:[quote]Checking for Python.h … /Library/Frameworks/Python.framework/Versions/2.7/include/python2.7
Checking for python2.7, libpython2.7, libpython, python, or Python … /usr/bin[/quote]
It looks like you have a custom install of python (given that it is not under /System)? Did you use --enable-framework when configuring (and installing) python?