When running a cxfreeze binary from a python3.2 project I am getting the following runtime error:
/project/dist/project/distutils/__init__.py:13: UserWarning: The virtualenv distutils package at %s appears to be in the same location as the system distutils?
Traceback (most recent call last):File "/home/chrish/.virtualenvs/project/lib/python3.2/distutils/__init__.py", line 19, in <module>import dist
ImportError: No module named dist
Correspondingly there are several distutils
entries in the missing modules section of the cxfreeze output:
? dist imported from distutils
? distutils.ccompiler imported from numpy.distutils.ccompiler
? distutils.cmd imported from setuptools.dist
? distutils.command.build_ext imported from distutils
? distutils.core imported from numpy.distutils.core
...
I've tried forcing distutils to be included as a module, by both importing it in my main python file and by adding it to a cxfreeze setup.py
as:
options = {"build_exe": {"packages" : ["distutils"]} },
Neither approach worked. It seems likely that I've somehow broken the virtualenv [as distutils seems fundamental and the warning regarding the location of distutils], repeating with a clean virtualenv replicated the problem.
It may be worth noting that I installed cx-freeze by running $VIRTUAL_ENV/build/cx-freeze/setup.py install
as it doesn't install cleanly in pip.