Skip to contentSkip to conversation

python3: add ldconfig rdepends for python3-ctypes

PATCH New Yu, Mingli 1 participant 1 message Jul 2, 2020

lore
Share & tools
lore

Yu, Mingli

author
#0 lore raw

PATCH v2 1/1 python3: add ldconfig rdepends for python3-ctypes

From: Mingli Yu <[email protected]>

The ctypes module needs to use "ldconfig -p" to find the library path and it simply has below logic if no ldconfig installed.
except OSError:
pass

Before the patch:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

from ctypes.util import find_library
lib_path = find_library('archive')
print(lib_path)

None

After the patch:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

from ctypes.util import find_library
lib_path = find_library('archive')
print(lib_path)

libarchive.so.13

---
 meta/recipes-devtools/python/python3_3.8.3.bb | 1 +
 1 file changed, 1 insertion(+)
meta/recipes-devtools/python/python3_3.8.3.bb +1 -0
index 2eb2a422e6..a7cfbad5cd 100644
@@ -350,6 +350,7 @@ FILES_${PN}-man = "${datadir}/man"
 
 # See https://bugs.python.org/issue18748 and https://bugs.python.org/issue37395
 RDEPENDS_libpython3_append_libc-glibc = " libgcc"
+RDEPENDS_${PN}-ctypes_append_libc-glibc = " ${MLPREFIX}ldconfig"
 RDEPENDS_${PN}-ptest = "${PN}-modules ${PN}-tests unzip bzip2 libgcc tzdata-europe coreutils sed"
 RDEPENDS_${PN}-ptest_append_libc-glibc = " locale-base-tr-tr.iso-8859-9"
 RDEPENDS_${PN}-tkinter += "${@bb.utils.contains('PACKAGECONFIG', 'tk', 'tk tk-lib', '', d)}"
Signature · 1 line
2.26.2