惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

S
Schneier on Security
Security Archives - TechRepublic
Security Archives - TechRepublic
T
Threat Research - Cisco Blogs
G
GRAHAM CLULEY
P
Privacy & Cybersecurity Law Blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
Cisco Talos Blog
Cisco Talos Blog
The Hacker News
The Hacker News
L
Lohrmann on Cybersecurity
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
C
Cyber Attacks, Cyber Crime and Cyber Security
Security Latest
Security Latest
Know Your Adversary
Know Your Adversary
P
Palo Alto Networks Blog
C
Cisco Blogs
AWS News Blog
AWS News Blog
T
Threatpost
L
LINUX DO - 热门话题
Simon Willison's Weblog
Simon Willison's Weblog
Scott Helme
Scott Helme
C
Cybersecurity and Infrastructure Security Agency CISA
T
Tor Project blog
Cyberwarzone
Cyberwarzone
P
Proofpoint News Feed
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
T
The Exploit Database - CXSecurity.com
The Register - Security
The Register - Security
D
Darknet – Hacking Tools, Hacker News & Cyber Security
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
罗磊的独立博客
云风的 BLOG
云风的 BLOG
V
Vulnerabilities – Threatpost
N
News | PayPal Newsroom
Project Zero
Project Zero
NISL@THU
NISL@THU
博客园_首页
MyScale Blog
MyScale Blog
V2EX - 技术
V2EX - 技术
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
F
Full Disclosure
T
Troy Hunt's Blog
Recorded Future
Recorded Future
N
Netflix TechBlog - Medium
P
Privacy International News Feed
H
Hackread – Cybersecurity News, Data Breaches, AI and More
A
Arctic Wolf
C
Check Point Blog
W
WeLiveSecurity
Apple Machine Learning Research
Apple Machine Learning Research
C
CERT Recently Published Vulnerability Notes

博客园 - 毕海

golang的cgo支持调用C++的方法 [原]zeromq框架测试报告 [转]linux下查看进程内存使用情况 程序员必读系列 python 不同版本下载资源 提示“load System.Core failed” phpwind主要表结构的研究随笔[1] [转]Python快速教程 [转]80个Python经典资料(教程+源码+工具)汇总——下载目录 [转]一位大牛整理的python资源 [转]使用PyInstaller2将Python脚本转化为可执行文件(下-进阶使用) [转]使用PyInstaller2将Python脚本转化为可执行文件(上-安装部分) [转]使用PyInstaller2将Python脚本转化为可执行文件(中-使用部分) [转]Nginx安装 [转]Centos 5.5 卸载与安装java1.7环境 在win8 x64上安装Scrapy mongodb协议透传 mongodb的监控与性能优化 记一次MongoDB性能问题
[转]PyInstaller2的信息文件Version的生成
毕海 · 2013-05-28 · via 博客园 - 毕海

上一篇博文 
使用PyInstaller2将Python脚本转化为可执行文件(下-进阶使用) 
http://www.cnblogs.com/balian/archive/2013/02/17/2915077.html

提到了version.txt文件。大家可能想知道version.txt文件(或者至少格式)是怎么得来的。PyInstaller2提供了一个组件(GrabVersion.py)来分析Windows系统中某个可执行文件,从而生成version.txt文件。不过,要使这个组件能正常工作,需要做些工作。本文博客园balian原创,欢迎转载,转载请说明原作者。

假设PyInstaller2文件夹是在C盘根目录。文件GrabVersion.py就在C:\pyinstaller2\utils文件夹中。但却是无法直接执行的,请看下图。这里假设是来分析文件C:\Windows\System32\cmd.exe的版本和版权信息。

image

系统提示错误“No module named PyInstaller”。

将文件GrabVersion.py拷贝到C:\pyinstaller2\文件夹可以修复这个问题,但又有了新问题。如下图:

image

系统提示C:\pyinstaller2\PyInstaller\utils\versioninfo.py需要修改。修改这个文件并不复杂。如下图,添加一系列str()在相应位置。

image

重新运行命令

C:\pyinstaller2>python GrabVersion.py "C:\Windows\System32\cmd.exe"


就能得到我们需要的version信息了。

image

*** *** ***

安装PyInstaller2步骤请见: 
使用PyInstaller2将Python脚本转化为可执行文件(上-安装部分) 
http://www.cnblogs.com/balian/archive/2012/11/21/2780503.html

一些基本的使用步骤请见: 
使用PyInstaller2将Python脚本转化为可执行文件(中-使用部分) 
http://www.cnblogs.com/balian/archive/2012/11/22/2782308.html

自定义图标和版本信息请见: 
使用PyInstaller2将Python脚本转化为可执行文件(下-进阶使用) 
http://www.cnblogs.com/balian/archive/2013/02/17/2915077.html

转自:http://www.cnblogs.com/balian/archive/2013/02/18/2915105.html