PDA

View Full Version : [Solved] Porting a python easy_install based module


sahne
February 26th, 2010, 23:46
hi all,

I have a small problem while porting a python easy_install based python tool.
Fetching, installing work fine, and I have created the pkg-plist file to match all files and directories.
make deinstall PREFIX=/var/tmp/pycontrole
gives me following

No local packages or download links found for pycontrole==1.5.3
Traceback (most recent call last):
File "/usr/local/bin/easy_install-2.6", line 8, in <module>
load_entry_point('setuptools==0.6c11', 'console_scripts', 'easy_install-2.6')()
File "build/bdist.freebsd-8.0-RELEASE-amd64/egg/setuptools/command/easy_install.py", line 1712, in main
File "build/bdist.freebsd-8.0-RELEASE-amd64/egg/setuptools/command/easy_install.py", line 1700, in with_ei_usage
File "build/bdist.freebsd-8.0-RELEASE-amd64/egg/setuptools/command/easy_install.py", line 1716, in <lambda>
File "/usr/local/lib/python2.6/distutils/core.py", line 152, in setup
dist.run_commands()
File "/usr/local/lib/python2.6/distutils/dist.py", line 975, in run_commands
self.run_command(cmd)
File "/usr/local/lib/python2.6/distutils/dist.py", line 995, in run_command
cmd_obj.run()
File "build/bdist.freebsd-8.0-RELEASE-amd64/egg/setuptools/command/easy_install.py", line 211, in run
File "build/bdist.freebsd-8.0-RELEASE-amd64/egg/setuptools/command/easy_install.py", line 434, in easy_install
File "build/bdist.freebsd-8.0-RELEASE-amd64/egg/setuptools/package_index.py", line 475, in fetch_distribution
AttributeError: 'NoneType' object has no attribute 'clone'
pkg_delete: unexec command for '/usr/local/bin/easy_install-2.6 -q -m -S /usr/local/lib/python2.6/site-packages -d /var/tmp/pycontrole
/lib/python2.6/site-packages -s /var/tmp/pycontrole/bin pycontrole==1.5.3' failed
pkg_delete: couldn't entirely delete package (perhaps the packing list is
incorrectly specified?)

but all port specific files are removed from the directory.

To install the port I had to add

PYEASYINSTALL_EGG=pycontrole-0.1dev-py2.6.egg

to the Makefile.

Has anybody hints or solutions to this problem (if needed I'll provide the whole Makefile, but I think it isn't needed since there is nothing else configured)

regards
Daniel

sahne
February 27th, 2010, 02:39
hate to reply to myself, but I fixed it.
Instead of using PYEASYINSTALL_EGG you have to override PYDISTUTILS_PKGVERSION to fix the problem.