staticx icon indicating copy to clipboard operation
staticx copied to clipboard

Failed to load Python shared library

Open JonathonReinhart opened this issue 7 months ago • 1 comments

In Test StaticX against PyInstalled application, under Run integration tests (w/ strip):

--------------------------------------------------------------------------------
Test StaticX against PyInstalled application

Python app run normally:
Hello runner!
Resource dir: /home/runner/work/staticx/staticx/test/pyinstall

Building PyInstaller 'onfile' application:
116 INFO: PyInstaller: 6.15.0, contrib hooks: 2025.8
116 INFO: Python: 3.10.12
117 INFO: Platform: Linux-6.8.0-1031-azure-x86_64-with-glibc2.35
117 INFO: Python environment: /usr
118 INFO: wrote /home/runner/work/staticx/staticx/test/pyinstall/app.spec
120 INFO: UPX is available but is disabled on non-Windows due to known compatibility problems.
120 INFO: Module search paths (PYTHONPATH):
['/usr/lib/python310.zip',
 '/usr/lib/python3.10',
 '/usr/lib/python3.10/lib-dynload',
 '/home/runner/.local/lib/python3.10/site-packages',
 '/usr/local/lib/python3.10/dist-packages',
 '/usr/lib/python3/dist-packages',
 '/home/runner/work/staticx/staticx/test/pyinstall']
307 INFO: checking Analysis
314 INFO: checking PYZ
326 INFO: checking PKG
326 INFO: Building because python_lib_name changed
326 INFO: Building PKG (CArchive) app.pkg
2397 INFO: Building PKG (CArchive) app.pkg completed successfully.
2398 INFO: Bootloader /home/runner/.local/lib/python3.10/site-packages/PyInstaller/bootloader/Linux-64bit-intel/run
2398 INFO: checking EXE
2399 INFO: Building because python_lib changed
2399 INFO: Building EXE from EXE-00.toc
2400 INFO: Copying bootloader EXE to /home/runner/work/staticx/staticx/test/pyinstall/dist/app
2400 INFO: Appending PKG archive to custom ELF section in EXE
2418 INFO: Building EXE from EXE-00.toc completed successfully.
2419 INFO: Build complete! The results are available in: /home/runner/work/staticx/staticx/test/pyinstall/dist

PyInstalled application run:
[PYI-15639:ERROR] Failed to load Python shared library '/tmp/_MEIn9h2g3/libpython3.10.so': /tmp/_MEIn9h2g3/libpython3.10.so: cannot open shared object file: No such file or directory
Error: Process completed with exit code 255.

JonathonReinhart avatar Aug 22 '25 05:08 JonathonReinhart