[MacPorts] #37673: root @5.34.04 +python27 pyROOT doesn't work
#37673: root @5.34.04 +python27 pyROOT doesn't work --------------------------+-------------------------------- Reporter: jd.mansour@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.1.2 Keywords: | Port: root --------------------------+-------------------------------- If I install root with +python27, it is supposed to install pyROOT support. However, I get the following error message when I `import ROOT` from python: {{{ $ python2.7 -c "import ROOT" Traceback (most recent call last): File "<string>", line 1, in <module> File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7 /site-packages/ROOT.py", line 85, in <module> import libPyROOT as _root ImportError: No module named libPyROOT }}} This is because libPyROOT.so (which is fine) is not found. One solution is to put it on the PYTHONPATH, but a cleaner solution would be to make the port create a link to it somewhere on sys.path, for example: {{{ $ sudo ln -s /opt/local/lib/root/libPyROOT.so /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7 }}} After creating the link, the ROOT python module works as expected. -- Ticket URL: <https://trac.macports.org/ticket/37673> MacPorts <http://www.macports.org/> Ports system for Mac OS
#37673: root @5.34.04 +python27 pyROOT doesn't work ---------------------------+-------------------------------- Reporter: jd.mansour@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.1.2 Resolution: | Keywords: Port: root | ---------------------------+-------------------------------- Changes (by jmr@…): * cc: mattiafrancescomoro@…, jonesc@… (added) Comment: Please remember to Cc the maintainers. -- Ticket URL: <https://trac.macports.org/ticket/37673#comment:1> MacPorts <http://www.macports.org/> Ports system for Mac OS
#37673: root @5.34.04 +python27 pyROOT doesn't work ---------------------------+-------------------------------- Reporter: jd.mansour@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.1.2 Resolution: | Keywords: Port: root | ---------------------------+-------------------------------- Comment (by jonesc@…): Thats for the report. I use PyRoot myself a lot and it works for me, but then I have {{{ # ROOT export ROOTSYS=/opt/local if [ -n "${PYTHONPATH+x}" ]; then export PYTHONPATH=${ROOTSYS}"/lib/root:"${PYTHONPATH} else export PYTHONPATH=${ROOTSYS}"/lib/root" fi }}} in my ~/.profle ... ;) You point is well taken though. I'll see if I can come up with something that works without needing this... Chris -- Ticket URL: <https://trac.macports.org/ticket/37673#comment:2> MacPorts <http://www.macports.org/> Ports system for Mac OS
#37673: root @5.34.04 +python27 pyROOT doesn't work ---------------------------+-------------------------------- Reporter: jd.mansour@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.1.2 Resolution: | Keywords: Port: root | ---------------------------+-------------------------------- Comment (by jonesc@…): I have just submitted ticket #37687 which contains a patch to fix this. cheers Chris -- Ticket URL: <https://trac.macports.org/ticket/37673#comment:3> MacPorts <http://www.macports.org/> Ports system for Mac OS
#37673: root @5.34.04 +python27 pyROOT doesn't work ---------------------------+-------------------------------- Reporter: jd.mansour@… | Owner: macports-tickets@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.1.2 Resolution: fixed | Keywords: Port: root | ---------------------------+-------------------------------- Changes (by macsforever2000@…): * status: new => closed * resolution: => fixed -- Ticket URL: <https://trac.macports.org/ticket/37673#comment:4> MacPorts <http://www.macports.org/> Ports system for Mac OS
participants (1)
-
MacPorts