[MacPorts] #16593: py25-setuptools 0.6c8 broken in a way I don't fully comprehend
MacPorts
noreply at macports.org
Fri Sep 19 04:52:48 PDT 2008
#16593: py25-setuptools 0.6c8 broken in a way I don't fully comprehend
--------------------------------------+-------------------------------------
Reporter: macports at mail.taugt.net | Owner: macports-tickets at lists.macosforge.org
Type: defect | Status: new
Priority: Normal | Milestone: Port Bugs
Component: ports | Version: 1.6.0
Resolution: | Keywords:
Port: |
--------------------------------------+-------------------------------------
Comment(by macports at mail.taugt.net):
oops, markup got me. Let's try that again:
Sorry for being kind of verbose, I tried to trim the problem down in irc
but nobody could help me... so here goes:
after installing py25-setuptools, easy_install does not work out of the
box:
{{{
$ echo $PYTHONPATH
/Users/ace/lib/python2.5/site-packages # this directory exists
$ easy_install-2.5 --install-dir /Users/ace/lib/python2.5/site-packages
pyamf
error: /opt/local/lib/python2.5/site-packages/site.py: No such file or
directory
}}}
this can be fixed:
{{{
cd /opt/local/lib/python2.5/site-packages; sudo ln -s ../site.py
}}}
but then, after re-running said easy_install command, I cannot import
pyamf - I have to do a
{{{
$ cd /Users/ace/lib/python2.5/site-packages
$ unzip PyAMF-0.3.1-py2.5.egg
}}}
easy_install creates a suspicious pth file in /Users/ace/lib/python2.5
/site-packages:
{{{
$ cat easy-install.pth
import sys; sys.__plen = len(sys.path)
./PyAMF-0.3.1-py2.5.egg
import sys; new=sys.path[sys.__plen:]; del sys.path[sys.__plen:];
p=getattr(sys,'__egginsert',0); sys.path[p:p]=new; sys.__egginsert =
p+len(new)
}}}
... from what I gather by reading site.py, a pth file should contain only
path names, not python code.
also, it seems to copy site.py to that directory and then trip on it - if
I re-run easy_install, I get:
{{{
$ easy_install-2.5 --install-dir /Users/ace/lib/python2.5/site-packages
pyamf
error: /Users/ace/lib/python2.5/site-packages/site.py is not a
setuptools-
generated site.py; please remove it.
}}}
--
Ticket URL: <http://trac.macports.org/ticket/16593#comment:1>
MacPorts <http://www.macports.org/>
Ports system for Mac OS
More information about the macports-tickets
mailing list