- 论坛徽章:
- 0
|
使用python2.4 py2exe 0.6.5
\site-packages\pymssql.py 需要 ntwdblib.dll
setup.py
- from distutils.core import setup
- import py2exe
- import sys
- if len(sys.argv) == 1:
- sys.argv.append("py2exe")
- sys.argv.append("-q")
- setup(options = {"py2exe": {
- "compressed": 1,
- "optimize": 2}},
- console=["DB.py"])
复制代码
运行 python setup.py
running py2exe
*** searching for required modules ***
*** parsing results ***
*** finding dlls needed ***
*** create binaries ***
*** byte compile python files ***
E:\Python24\python.exe -OO e:\docume~1\admini~1\locals~1\temp\tmptnvdaw.py
removing e:\docume~1\admini~1\locals~1\temp\tmptnvdaw.py
*** copy extensions ***
*** copy dlls ***
copying E:\Python24\Lib\site-packages\py2exe\run.exe -> C:\netgame\src\dist\DB.exe
Adding zlib.pyd to C:\netgame\src\dist\library.zip
*** binary dependencies ***
Your executable(s) also depend on these dlls which are not included,
you may or may not need to distribute them.
Make sure you have the license if you distribute any of them, and
make sure you don't distribute files belonging to the operating system.
USER32.dll - E:\WINDOWS\system32\USER32.dll
ADVAPI32.dll - E:\WINDOWS\system32\ADVAPI32.dll
KERNEL32.dll - E:\WINDOWS\system32\KERNEL32.dll
ntwdblib.dll - E:\Python24\Lib\site-packages\ntwdblib.dll
SHELL32.dll - E:\WINDOWS\system32\SHELL32.dll
然后运行DB.EXE
Traceback (most recent call last):
File "DB.py", line 1, in ?
File "pymssql.pyo", line 24, in ?
ImportError: No module named decimal
这是啥问题?在SHELL里运行OK的 |
|