Skip to content

centos7 Python3.10.13 ERROR Uses system libs #32

Open

Description

@borays

/usr/bin/python3 [3.10.13]
prefix /usr/local/python3
_bz2 _bz2*.so bz2:1
_ctypes 1.1.0 _ctypes*.so ffi:6
_curses 2.2 _curses*.so ncursesw:5 tinfo:5
_dbm _dbm*.so gdbm_compat:4 gdbm:4
_decimal 1.70 _decimal*.so
_gdbm 1.10.0 _gdbm*.so gdbm:4
_lzma _lzma*.so lzma:5
_sqlite3 3.7.17 _sqlite3*.so sqlite3:0
_ssl OpenSSL 1.1.1w 11 Sep 2023 None
_tkinter 8.5 _tkinter*.so tk8:8.5 tcl8:8.5 X11:6 Xft:2 freetype:6 xcb:1 fontconfig:1 Xrender:1 z:1 bz2:1 png15:15 Xau:6 uuid:1
_uuid _uuid*.so uuid:1
pip 23.0.1 lib/python3.10/site-packages/pip
pyexpat 2.5.0 pyexpat*.so
readline 6.2 readline*.so readline:6 tinfo:5
setuptools 65.5.0 lib/python3.10/site-packages/setuptools
zlib 1.2.7 zlib*.so z:1
libpython*.a 72 MB lib/libpython3.10.a lib/python3.10/config-3.10-x86_64-linux-gnu/libpython3.10.a
libpython*.so -not used-
install size 230 MB
ERROR Uses system libs: /lib64/libreadline.so.6 /lib64/libtinfo.so.5 /lib64/libncursesw.so.5 /lib64/libpanelw.so.5 /lib64/libfreebl3.so /lib64/libgdbm_compat.so.4 /usr/lib64/libgdbm.so.4 /lib64/libsqlite3.so.0 /lib64/libz.so.1 /lib64/libbz2.so.1 /lib64/liblzma.so.5 /lib64/libtk8.5.so /lib64/libtcl8.5.so /lib64/libX11.so.6 /lib64/libXft.so.2 /lib64/libfreetype.so.6 /lib64/libxcb.so.1 /lib64/libfontconfig.so.1 /lib64/libXrender.so.1 /lib64/libpng15.so.15 /lib64/libXau.so.6 /lib64/libuuid.so.1 /lib64/libffi.so.6

These lib libraries are all installed using yum, but they are still swapped. Can you guide them?

Activity

  1. sbivol commented on Jan 30, 2024

    @sbivol
    Contributor

    Similar issue when building on Ubuntu 22.04, system libraries are in use:

    $ portable-python build 3.11.7
    [...]
            prefix  /build/ppp-marker/3.11.7
              _bz2  *absent* None
           _ctypes  1.1.0 _ctypes*.so ffi:8
           _curses  *absent* None
              _dbm  *absent* None
          _decimal  1.70 _decimal*.so
             _gdbm  *absent* None
             _lzma  *absent* None
          _sqlite3  *absent* None
              _ssl  *absent* None
          _tkinter  *absent* None
             _uuid  *absent* None
               pip  23.2.1 lib/python3.11/site-packages/pip
           pyexpat  2.5.0 pyexpat*.so
          readline  *absent* None
        setuptools  *absent* /build/ppp-marker/3.11.7/lib/python3.11/distutils/core.py
              zlib  1.2.11 zlib*.so z:1
      libpython*.a  87 MB lib/python3.11/config-3.11-x86_64-linux-gnu/libpython3.11.a lib/libpython3.11.a
     libpython*.so  -not used-
      install size  171 MB
    ERROR Build failed: Uses system libs: /lib/x86_64-linux-gnu/libz.so.1 /lib/x86_64-linux-gnu/libffi.so.8
    
  2. sbivol commented on Jan 30, 2024

    @sbivol
    Contributor

    I managed to build it successfully on Ubuntu 22.04 with these commands:

    $ sudo apt install --no-install-recommends tcl libsqlite3-dev libffi-dev zlib1g-dev uuid-dev perl gcc make
    $ portable-python build 3.11.7 -m openssl,readline,zlib,bzip2,sqlite,uuid,xz,libffi
    

    Reading the manual would have helped, I missed the --modules flag from portable-python build --help

  3. zsimic commented on Jan 30, 2024

    @zsimic
    Contributor

    Sorry for the delay in responding.
    This check is here to try and ensure that the produced python is portable, but it is based on a heuristic... If you know these libs are OK to include (ie: people installing your produced python all have those libs), then you can configure it like so for example:

    linux:
      allowed-system-libs: /lib(64)?/.*
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationgood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions