New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ubuntu 20.04 - onefile produces a shared object instead of executable #5361
Comments
Yes, the pre-built bootloaders are built with PIE. And it seems in 20.04, You can pass
|
It doesn't work, test_application is LSB shared object, output with file:
Bootloader compiled with these step:
Output with file on run:
|
So the bootloader is non-pie executable now. If test_application remains a PIE executable, that means that the new bootloader is not used. Do you have another installation of pyinstaller (e.g., user's site-packages, venv, etc) that is shadowing the newly-installed one? |
Ok, you hit the problem, there was PyInstaller 4.1 that was overriding git version. Maybe it is better to add this problem (gcc has PIE enabled by default) on documentation, isn't it? |
Perhaps, but we (or at least I) only became aware of it once people started to ask about it, following the 4.1 release. I think the pre-compiled bootloaders that are shipped with 4.1 were not intentionally built as PIE executables (but rather, that was the default on the build machine)... Also, the problem is not directly related to pyinstaller. The PIE executables seem to be the modern executable format, which is probably why the new Ubuntu defaults to it (as a side note, the latest Fedora seems to be still using the old executable format by default). So the issue with PIE executables being recognized as shared libraries / user not being able to run them via double-click from the desktop environment is something that needs to be addressed by the desktop environment (or the component used for identification), as it affects all executables built with default parameters on distributions that enable PIE by default... |
I understand the point |
Hi! |
There is nothing to "fix" really, but yes, if you want non-PIE bootloader, you need to rebuild it yourself. |
As far as I understand it is also environment depended so probably on other distros there is no such issue. |
Closing this as bootloader and consequently frozen applications being PIE is not an issue per-se. The side effects (mis-identification of executable as a shared library, not being able to run it via double-click in DE, etc.) should be resolved elsewhere as they are not specific to PyInstaller but to all PIE executables. |
On Ubuntu 20.04 it's impossible to launch an application with double click, only from terminal the program starts. Operating system informs that there is no application for launching shared object.
Is there a way to avoid this? Is it related with bootloader? Is there a way to pass -no-pie when bootloader is being build?
PyInstaller 4.1, Python 3.8.5
The text was updated successfully, but these errors were encountered: