PyInstaller Manual
******************

Version:
   PyInstaller 3.5

Homepage:
   http://www.pyinstaller.org

Contact:
   pyinstaller@googlegroups.com

Authors:
   David Cortesi, based on structure by Giovanni Bajo & William Caban,
   based on Gordon McMillan's manual

Copyright:
   This document has been placed in the public domain.

*PyInstaller* bundles a Python application and all its dependencies
into a single package. The user can run the packaged app without
installing a Python interpreter or any modules. *PyInstaller* supports
Python 2.7 and Python 3.4+, and correctly bundles the major Python
packages such as numpy, PyQt, Django, wxPython, and others.

*PyInstaller* is tested against Windows, Mac OS X, and GNU/Linux.
However, it is not a cross-compiler: to make a Windows app you run
*PyInstaller* in Windows; to make a GNU/Linux app you run it in
GNU/Linux, etc. *PyInstaller* has been used successfully with AIX,
Solaris, and FreeBSD, but is not tested against them.


What's New This Release
=======================

Release 3.0 is a major rewrite that adds Python 3 support, better code
quality through use of automated testing, and resolutions for many old
issues.

Functional changes include removal of support for Python prior to 2.7,
an easier way to include data files in the bundle (Adding Files to the
Bundle), and changes to the "hook" API (Understanding PyInstaller
Hooks).

Contents:

* Requirements

  * Windows

  * Mac OS X

  * GNU/Linux

  * AIX, Solaris, and FreeBSD

* License

* How To Contribute

  * Some ideas how you can help

* How to Install *PyInstaller*

  * Installing in Windows

  * Installing in Mac OS X

  * Installing from the archive

  * Verifying the installation

  * Installed commands

* What *PyInstaller* Does and How It Does It

  * Analysis: Finding the Files Your Program Needs

  * Bundling to One Folder

  * How the One-Folder Program Works

  * Bundling to One File

  * How the One-File Program Works

  * Using a Console Window

  * Hiding the Source Code

* Using PyInstaller

  * Options

  * Shortening the Command

  * Running *PyInstaller* from Python code

  * Running *PyInstaller* with Python optimizations

  * Using UPX

  * Encrypting Python Bytecode

  * Defining the Extraction Location

  * Supporting Multiple Platforms

  * Capturing Windows Version Data

  * Building Mac OS X App Bundles

  * Platform-specific Notes

* Run-time Information

  * Using "__file__"

  * Using "sys.executable" and "sys.argv[0]"

  * LD_LIBRARY_PATH / LIBPATH considerations

* Using Spec Files

  * Spec File Operation

  * Adding Files to the Bundle

  * Giving Run-time Python Options

  * Spec File Options for a Mac OS X Bundle

  * Multipackage Bundles

  * Globals Available to the Spec File

* Notes about specific Features

  * Ctypes Dependencies

  * SWIG support

  * Cython support

* When Things Go Wrong

  * Recipes and Examples for Specific Problems

  * Finding out What Went Wrong

  * Helping PyInstaller Find Modules

  * Getting the Latest Version

  * Asking for Help

* Advanced Topics

  * The Bootstrap Process in Detail

  * The TOC and Tree Classes

  * Inspecting Archives

  * Inspecting Executables

  * Creating a Reproducible Build

* Understanding PyInstaller Hooks

  * How a Hook Is Loaded

  * Hook Global Variables

  * Useful Items in "PyInstaller.compat"

  * Useful Items in "PyInstaller.utils.hooks"

  * The "hook(hook_api)" Function

  * The "pre_find_module_path( pfmp_api )" Method

  * The "pre_safe_import_module( psim_api )" Method

* Building the Bootloader

  * Building for GNU/Linux

  * Building for Mac OS X

  * Building for Windows

  * Vagrantfile Virtual Machines

* Changelog for PyInstaller

  * 3.5 (2019-07-09)

  * 3.4 (2018-09-09)

  * 3.3.1 (2017-12-13)

  * 3.3 (2017-09-21)

  * Older Versions

* Credits

  * Contributions to PyInstaller 3.5

  * Contributions to PyInstaller 3.4

  * Contributions to PyInstaller 3.3.1

  * Contributions to PyInstaller 3.3

  * Contributions to PyInstaller 3.2.1

  * Contributions to PyInstaller 3.2

  * Contributions to PyInstaller 3.1.1

  * Contributions to PyInstaller 3.1

  * Contributions to PyInstaller 3.0

  * Contributions to PyInstaller 2.1 and older

* Man Pages

  * pyinstaller

  * pyi-makespec

* Development Guide

  * Quick-start


Indices and tables
------------------

* Index

* Module Index

* Search Page
