question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How to create a single binary without dependencies

See original GitHub issue
0.6.5
Python: 3.7.4 (default, Aug 13 2019, 20:35:49) 
Executable: /home/ryan/.miniconda/bin/python
OS: Linux
Arch: x86_64

Conda environment for Python, Nuitka installed via pip.

I’ve been looking through the documentation, but I don’t quite see the options I am looking for. I have a source tree with a single entry point (main.py) and a bunch of other Python modules nested below it. I want to produce a single binary with all of the Python files included, but I don’t want to include any conda/pip dependencies or the Python interpreter itself.

How can this be done?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:3
  • Comments:11 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
ryan-clancycommented, Jun 30, 2022

@kayhayen Any ideas? Nuitka only seems to produce .so files for the top-level package instead of all of the children packages below the top-level.

0reactions
kayhayencommented, Jun 30, 2022

There is plenty of documentation in the user manual about modes, standalone and distutils integration. This is not for helping people who struggle with reading. Should something be missing in the docs, then raise an issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Basics of compiling binary with no dependencies using gnu ...
The most important thing you need to generate executables without dependencies is the static version of all libraries this executable will ...
Read more >
How to compile binaries without dependencies on Windows?
Is there a way to build Rust binaries with no dependencies like Go? A single binary that is easy to deploy without having...
Read more >
Create a single file for application deployment - .NET
Bundling all application-dependent files into a single binary provides an application developer with the attractive option to deploy and ...
Read more >
Single binary executable packages - Volution Notes
In support of software packages that come in the form of a single binary ... or downloading half the distribution's packages as dependencies....
Read more >
A Story of a Big Go Binary | by Dotan Nahum - Medium
There's one last trick that will work. When you compile your Go binary, Go will generate interim binaries for each dependency, before statically ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found