win32 pyserial requires javax.comm for py2exe?

Grant Edwards grante at visi.com
Tue Jun 29 18:40:07 CEST 2004


I'm trying to package a small Python program using py2exe.

Everything works fine until I add an "include serial", then 
py2exe fails because

  The following modules appear to be missing
  ['javax.comm']

Apparently serial.py imports a both the posix and java versions
of things even on a win32 platform?



------------------------------setup.py------------------------------
# setup.py
from distutils.core import setup
import py2exe
setup(console=["testit.py"])
--------------------------------------------------------------------

------------------------------testit.py------------------------------
import serial
print "hello"
---------------------------------------------------------------------

----------------------python setup.py py2exe-------------------------
running py2exe
*** searching for required modules ***
*** parsing results ***
creating python loader for extension '_sre'
creating python loader for extension 'datetime'
creating python loader for extension 'win32file'
creating python loader for extension 'select'
creating python loader for extension 'win32event'
*** finding dlls needed ***
*** create binaries ***
*** byte compile python files ***
skipping byte-compilation of C:\PYTHON23\lib\copy_reg.py to copy_reg.pyc
skipping byte-compilation of C:\PYTHON23\lib\sre_compile.py to sre_compile.pyc
skipping byte-compilation of C:\PYTHON23\lib\locale.py to locale.pyc
byte-compiling C:\cygwin\home\admin\othertools\build\bdist.win32\winexe\temp\_sre.py to _sre.pyc
skipping byte-compilation of C:\PYTHON23\lib\macpath.py to macpath.pyc
skipping byte-compilation of C:\PYTHON23\lib\popen2.py to popen2.pyc
byte-compiling C:\cygwin\home\admin\othertools\build\bdist.win32\winexe\temp\datetime.py to datetime.pyc
skipping byte-compilation of C:\PYTHON23\lib\atexit.py to atexit.pyc
byte-compiling C:\cygwin\home\admin\othertools\build\bdist.win32\winexe\temp\win32file.py to win32file.pyc
skipping byte-compilation of C:\Python23\Lib\site-packages\serial\serialwin32.py to serial\serialwin32.pyc
skipping byte-compilation of C:\Python23\Lib\site-packages\serial\__init__.py to serial\__init__.pyc
skipping byte-compilation of C:\Python23\Lib\site-packages\serial\serialjava.py to serial\serialjava.pyc
byte-compiling C:\cygwin\home\admin\othertools\build\bdist.win32\winexe\temp\select.py to select.pyc
byte-compiling C:\cygwin\home\admin\othertools\build\bdist.win32\winexe\temp\win32event.py to win32event.pyc
skipping byte-compilation of C:\PYTHON23\lib\linecache.py to linecache.pyc
skipping byte-compilation of C:\PYTHON23\lib\sre_constants.py to sre_constants.pyc
skipping byte-compilation of C:\PYTHON23\lib\re.py to re.pyc
skipping byte-compilation of C:\PYTHON23\lib\ntpath.py to ntpath.pyc
skipping byte-compilation of C:\Python23\Lib\site-packages\serial\serialposix.py to serial\serialposix.pyc
skipping byte-compilation of C:\PYTHON23\lib\stat.py to stat.pyc
skipping byte-compilation of C:\PYTHON23\lib\string.py to string.pyc
skipping byte-compilation of C:\PYTHON23\lib\warnings.py to warnings.pyc
skipping byte-compilation of C:\PYTHON23\lib\UserDict.py to UserDict.pyc
skipping byte-compilation of C:\PYTHON23\lib\repr.py to repr.pyc
skipping byte-compilation of C:\PYTHON23\lib\copy.py to copy.pyc
skipping byte-compilation of C:\PYTHON23\lib\types.py to types.pyc
skipping byte-compilation of C:\PYTHON23\lib\posixpath.py to posixpath.pyc
skipping byte-compilation of C:\PYTHON23\lib\FCNTL.py to FCNTL.pyc
skipping byte-compilation of C:\Python23\Lib\site-packages\serial\serialutil.py to serial\serialutil.pyc
skipping byte-compilation of C:\PYTHON23\lib\sre.py to sre.pyc
skipping byte-compilation of C:\PYTHON23\lib\TERMIOS.py to TERMIOS.pyc
skipping byte-compilation of C:\PYTHON23\lib\os2emxpath.py to os2emxpath.pyc
skipping byte-compilation of C:\PYTHON23\lib\_strptime.py to _strptime.pyc
skipping byte-compilation of C:\PYTHON23\lib\calendar.py to calendar.pyc
skipping byte-compilation of C:\Python23\Lib\site-packages\win32\lib\win32con.py to win32con.pyc
skipping byte-compilation of C:\PYTHON23\lib\sre_parse.py to sre_parse.pyc
skipping byte-compilation of C:\PYTHON23\lib\os.py to os.pyc
*** copy extensions ***
*** copy dlls ***
copying C:\Python23\Lib\site-packages\py2exe\run.exe -> C:\cygwin\home\admin\othertools\dist\testit.exe
The following modules appear to be missing
['javax.comm']
---------------------------------------------------------------------

-- 
Grant Edwards                   grante             Yow!  We just joined the
                                  at               civil hair patrol!
                               visi.com            



More information about the Python-list mailing list