-
Notifications
You must be signed in to change notification settings - Fork 37
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
Getting SIGSEGV segmentation fault on staticx generated executable #232
Comments
For reference and the particulars, (maybe someone can see something wrong I'm doing) this is the pyinstaller call:
As mentioned above, the dynamically linked executable produced from this pyinstaller call runs fine on Debian Linux x86_64. Then my staticx call is as follows:
Then, when executing the resultant statically linked executable, python_script.exe on Debian Linux x86_64, I get the segmentation fault. When I run it with gdb, I see the segmentation fault is due to SIGSEGV. |
Please see https://staticx.readthedocs.io/en/latest/troubleshooting.html and include all of the referenced debug output. |
Thanks for those pointers; as suggested I have pasted in the debug output. Please see below: Below is the
Below is the gdb output::
|
I haven't looked closely yet, but there are a few things that I don't understand:
AFAIK none of this should be necessary, and could potentially be harmful. What version of Debian? What version of pyinstaller and how was it installed? |
(1) I passed the --add-binary option to pyinstaller hoping it might help me get over the segmentation fault issue but it did not. Given this, I reran pyinstaller without the --add-binary option and then ran staticx without any of the -l. options. But am still getting the segmentation fault. Debian version: Pyinstaller: |
I wonder if this is the same(ish) issue as #243. I see you're using a fairly new version of patchelf: Please try upgrading your version of patchelf to 0.17.2. Or downgrading it to something older, in the 0.16.x line. Or install your Linux distro's version. |
(1) Generated a dynamically linked executable using pyinstaller on a Python script on a Linux Debian x86_64 machine
(2) This dynamically linked executable is running ok on the x86_64 machine
(3) But, want to generate a statically linked executable that I will be able to run on a mobile device
(4) Ran staticx (v0.13.8) on the dynamically linked executable. The resulting statically linked executable is generating the error seen in the title.
(5) Tried adding "-l lib..." in the staticx call, i.e., the libs I see when I do "ldd" on the dynamically linked executable.
(6) But still getting the seg fault.
The text was updated successfully, but these errors were encountered: