Sitemap

Getting Started
Utilities
Spec Files
When Things Go Wrong
Standalone Executables
Python Archives
Analyzing Python Modules
An Import Framework

Bug Tracker

The Utilities

ArchiveViewer

      >python ArchiveViewer.py archivefile
      

ArchiveViewer lets you examine the contents of any Installer-built archive or executable (PYZ, PKG or exe). Invoke it with the target as the first arg (I have it set up as a Send-To so it shows on my context menu in Explorer). You can navigate through the archive with these commands:

O <nm>
Open the embedded archive <nm> (will prompt if omitted).
U
Go up one level (go back to viewing the embedding archive).
X <nm>
Extract nm (will prompt if omitted). Prompts for output filename. If none given, extracted to stdout.
Q
Quit.

GrabVersion (Windows)

      >python GrabVersion.py executable_with_version_resource
      

GrabVersion outputs text which can be eval'ed by versionInfo to reproduce a version resource. Invoke it with the full path name of a Windows executable (with a version resource) as the first argument. If you cut & paste (or redirect to a file), you can then edit the version information. The edited text file can be used in a version = myversion.txt option on any executable in an Installer spec file.

I did it this way because version resources are rather strange beasts, and fully understanding them is probably impossible. Some elements are optional, others required, but you could spend unbounded amounts of time figuring this out, because it's not well documented. When you view the version tab on a properties dialog, there's no straightforward relationship between how the data is displayed and the structure of the resource itself. So the easiest thing to do is find an executable that displays the kind of information you want, grab it's resource and edit it. Certainly easier than the Version resource wizard in VC++.

Others

Analyzing Dependencies

You can interactively track down dependencies, including getting cross-references by using mf.py, documented here.

copyright 1999-2002
McMillan Enterprises, Inc.