【发布时间】:2011-02-02 23:27:06
【问题描述】:
我在 Windows 系统上使用 Python 2.6 和 cx_Freeze 4.1.2。我创建了 setup.py 来构建我的可执行文件,一切正常。
当 cx_Freeze 运行时,它会将所有内容移动到 build 目录。我有一些其他文件,我想将它们包含在我的build 目录中。我怎样才能做到这一点?这是我的结构:
src\
setup.py
janitor.py
README.txt
CHNAGELOG.txt
helpers\
uncompress\
unRAR.exe
unzip.exe
这是我的 sn-p:
设置
( name='Janitor', version='1.0', description='Janitor', author='John Doe', author_email='john.doe@gmail.com', url='http://www.this-page-intentionally-left-blank.org/', data_files = [ ('helpers\uncompress', ['helpers\uncompress\unzip.exe']), ('helpers\uncompress', ['helpers\uncompress\unRAR.exe']), ('', ['README.txt']) ], executables = [ Executable\ ( 'janitor.py', #initScript ) ] )
我似乎无法让它工作。我需要MANIFEST.in 文件吗?
【问题讨论】:
标签: python distutils cx-freeze