Questions tagged [pyinstaller]

PyInstaller is a multi-platform tool designed to convert Python (.py) files into stand-alone executable files on Windows, Linux, macOS, Solaris, and AIX.

PyInstaller is a multi-platform tool designed to convert Python (.py) files into standalone executable files on Windows, macOS, Linux, FreeBSD, Solaris, and AIX. These executable files can run on a system without Python installed, but are OS-dependent, meaning that the executable has to be generated from a machine with the same operating system than the machine in which it will run (for instance, it is not possible to generate an executable from macOS and then run it on Windows).

It is designed to be compatible with many third-party modules such as PyQt, Django or matplotlib without requiring configuration or plugins.

PyInstaller is open source software, distributed under the GPL. It works out of the box with any Python version 2.7 / 3.5-3.7.

The latest version of Pyinstaller is available on GitHub http://www.pyinstaller.org/

Usage

Install PyInstaller from PyPI:

pip install pyinstaller

Go to your program’s directory and run:

pyinstaller yourprogram.py

This will generate the bundle in a subdirectory called dist.

6448 questions
2
votes
1 answer

pyinstaller exclude-module causes "failed to execute script"

I'm creating an exe out of my simple script in command prompt with: pyinstaller --onefile --exclude-module scipy myscript.py and when I open the .exe I get a message that says "failed to run myscript.exe script" but the thing is the program works…
jaredmt
  • 196
  • 2
  • 9
2
votes
0 answers

Pyinstaller DLL Load Failed: The specified procedure could not be found

Hello, everyone. I am trying to make an .exe package for a small desktop app. I am using python 35, PyQt5 and Pyinstaller 3.4.dev0+97ce49bad. When I run Pyinstaller, it shows this: D:\SlowControl>pyinstaller --onefile --paths…
2
votes
1 answer

pyinstaller QSqlDatabase: QSQLITE driver not loaded QSqlDatabase: available drivers:

I have witten a GUI app using pyqt5 and includes a QtSql database QSQLITE. The app works perfectly. However when I run pyinstaller to a package my app, the app runs until the time where it has to invoke QtSQL DATABASE QSQLITE. This is the error I…
2
votes
1 answer

Anaconda python pyinstaller Can not find path ./libtbb.dylib

Mac OS X 10.13 Anaconda python 2.7.12 pyintaller error When compiling a script that includes: from __future__ import division from __future__ import print_function import sys import os import math import matplotlib.pyplot as plt I get the…
Barry
  • 903
  • 1
  • 7
  • 11
2
votes
1 answer

Capturing RTSP stream fails when the script is turned into a standalone executable using pyinstaller

Code: from imutils.video import VideoStream import cv2 # Read rtsp stream rtsp = u"rtsp://admin:admin@10.64.1.31:554/1/h264major" #vs = VideoStream(src=0).start() # for capturing from webcam vs = VideoStream(src=rtsp).start() while True: frame…
2
votes
0 answers

Pyinstaller on windows fills up limited home dir space and crashes with No space left on device

I am trying to use Pyinstaller on windows. Pyinstaller uses a bin cache that's located at %appdata%/pyinstaller on Windows. In my corporate environment, the space for the home dir is very limited, so pyinstaller quickly fills it up and then fails…
Sanguis
  • 21
  • 2
2
votes
1 answer

Pyminifier (obfuscation) does not appear to change anything other than in command line

I am attempting to obfuscate my python code with pyminifier. Generally I would use SAAS, however it is not within the budget of this small project nor is it feasible to host this as a server application. I have tried the following code: pyminifier…
user8900239
2
votes
0 answers

pyinstaller on UBuntu , giving error "pyconfig.h not found"

I am trying to convert my python script to executable file on ubuntu in virtual environmentn using pyinstaller. But its giving error saying "/python2.7/pyconfig.h" when adding binary and data files".... I have attached the screenshot here. So far…
luckypanda
  • 55
  • 8
2
votes
0 answers

bundle nltk_data with pyinstaller

This is somewhat of a similar question that I've previously had. Trying to figure out a way to publish an executable without the client needing nltk_data libraries. Current directory tree looks like this: . +-- Include +-- Lib +-- Scripts +-- Src | …
jc43
  • 71
  • 8
2
votes
0 answers

Pyinstaller and cython application files way too huge

I am creating executables that can run on my laptop without having Python installed. The below works perfectly... pyinstaller -r file_a.so,dll,file_a.so -r file_b.so,dll,file_b.so -F ./bin/hello However each executable is 181,177kb+. When before…
Tetora
  • 433
  • 8
  • 25
2
votes
1 answer

Python 3.5.2 + PyQt5 to standalone exe

I want to create a standalone exe containing PyQt5. I used PyInstaller and identified the folder where to find the .dll as follow: pyinstaller --paths C:\...\Anaconda3\Library\bin --onefile --windowed test.py The exe was created successfully and…
H. Dave
  • 549
  • 3
  • 9
  • 26
2
votes
0 answers

Make executable (.exe) from Python that includes MySQL database

I am making a Python program that uses a MySQL database. Now, I need a setup.exe file to set up the dependencies of the script and install it to windows computers. Googling turned up PyInstaller, which mentions nothing about databases in its…
George Sp
  • 553
  • 5
  • 20
2
votes
1 answer

Pyinstaller + driver

i did this script to download music from youtube, and it works in my IDLE and after compilated in .exe still works from tkinter import * from tkinter import ttk from tkinter import messagebox from tkinter import filedialog import youtube_dl import…
tascio
  • 21
  • 4
2
votes
1 answer

pyinstaller import error with runpy

I have file import1.py: import os import runpy filename = r'C:\pyinstallerTest\test.py' runpy.run_path(filename) File test.py is: import matplotlib.pyplot as plt import numpy as np from astroML import * from tkinter import * t = np.arange(0.0,…
Zanam
  • 4,607
  • 13
  • 67
  • 143
2
votes
0 answers

Python library not found in pyinstaller on Linux

I have python installed in Linux $ which python /grid/common/pkgs/python/v2.7.6/bin/python and also have pyinstaller $ which pyinstaller /grid/common/pkgs/python/v2.7.6/bin/pyinstaller Now I have created a sample python file hello.py in…
Anirudh Gupta
  • 201
  • 2
  • 6