Python中py2exe打包工具的用法详解


当前第2页 返回上一页

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

# _*_ coding: utf-8 _*_

import py2exe

from distutils.core import setup

 

includes = ['encoding', 'encodings.*']

options = {'py2exe':

        {'compressed': 1,

        'optimize': 2,

        'ascii': 1,

        'includes': includes,

        'bundle_files': 1,

        'dll_excludes': ['MSVCP90.dll'],

        }

      }

 

setup(version='1.0.0',

   description='search file',

   name='search file',

   options=options,

   zipfile=None,

   windows=[{'script': 'core\\tool.py', # 需要打包的程序的主文件路径

        'icon_resources': [(1, 'resource\\icon.ico')], # 程序的图标的图片路径

        }],

   )

以上就是Python中py2exe打包工具的用法详解的详细内容,更多文章请关注木庄网络博客!!

返回前面的内容

相关阅读 >>

Python中根据字符串导入模块module的方法介绍(附代码)

关于Python中如何使用selenium模拟jquery滑动解锁的实例分析

perl和Python之间有什么区别?perl与Python的简单比较

阶乘Python怎么打

mac版Python如何安装模块

matplotlib中对图形颜色和线条的填充

Python内置模块

Python调试方法有哪些,3分钟告诉你Python调试命令怎么用

Python能做什么?是什么意思?

Python实现获取外网ip并发邮件的方法

更多相关阅读请进入《Python》频道 >>




打赏

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码打赏,您说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦

分享从这里开始,精彩与您同在

评论

管理员已关闭评论功能...