[qt5-base] libQt5Core.so cannot be loaded

Problems with packages? Post here, using [tags] of the package name.

[qt5-base] libQt5Core.so cannot be loaded

Postby naums » Sun Dec 31, 2017 1:10 pm

I'm running an Odroid C2, and found that no application seems to be able to load the libQt5Core.so.5-shared object. For example smtube or minitube print the following error-message:

$this->bbcode_second_pass_code('', 'smtube: error while loading shared libraries: libQt5Core.so.5: cannot open shared object file: No such file or directory')

Using file to inspect the shared object (to maybe find problems in the architecture / build process), and for reference my kernel version:

$this->bbcode_second_pass_code('', '$ file /usr/lib/libQt5Core.so.5.10.0
/usr/lib/libQt5Core.so.5.10.0: ELF 64-bit LSB shared object, ARM aarch64, version 1 (GNU/Linux), dynamically linked, interpreter /lib/ld-linux-aarch64.so.1, BuildID[sha1]=56b55670bf27adfd4a75bbc08d4d2daaf24e0112, for GNU/Linux 3.17.0, stripped
$ uname -a
Linux oarch 3.14.79-28-ARCH #1 SMP PREEMPT Tue Nov 28 20:47:59 MST 2017 aarch64 GNU/Linux
')

I also ran strace with smtube to get more information, it looks like that:

$this->bbcode_second_pass_code('', '$ strace smtube
execve("/bin/smtube", ["smtube"], 0x7fc5d7f3c0 /* 26 vars */) = 0
brk(NULL) = 0x55607e9000
faccessat(AT_FDCWD, "/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=166031, ...}) = 0
mmap(NULL, 166031, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f8c366000
close(3) = 0
openat(AT_FDCWD, "/usr/lib/libQt5WebKitWidgets.so.5", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\267\0\1\0\0\0\0\0\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=330040, ...}) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f8c3b8000
mmap(NULL, 393237, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8c305000
mprotect(0x7f8c34b000, 86016, PROT_NONE) = 0
mmap(0x7f8c360000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x4b000) = 0x7f8c360000
close(3) = 0
openat(AT_FDCWD, "/usr/lib/libQt5Widgets.so.5", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0\267\0\1\0\0\0\20f\26\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=6551696, ...}) = 0
mmap(NULL, 6616968, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8bcb5000
mprotect(0x7f8c2ba000, 65536, PROT_NONE) = 0
mmap(0x7f8c2ca000, 241664, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x605000) = 0x7f8c2ca000
close(3) = 0
openat(AT_FDCWD, "/usr/lib/libQt5WebKit.so.5", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\267\0\1\0\0\0\0\0\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=44070552, ...}) = 0
mmap(NULL, 44233744, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f89285000
mprotect(0x7f8babc000, 69632, PROT_NONE) = 0
mmap(0x7f8bacd000, 1896448, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2838000) = 0x7f8bacd000
mmap(0x7f8bc9c000, 99344, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f8bc9c000
close(3) = 0
openat(AT_FDCWD, "/usr/lib/libQt5Gui.so.5", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0\267\0\1\0\0\0\220(\16\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=5616792, ...}) = 0
mmap(NULL, 5700832, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f88d15000
mprotect(0x7f89255000, 61440, PROT_NONE) = 0
mmap(0x7f89264000, 114688, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x53f000) = 0x7f89264000
mmap(0x7f89280000, 19680, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f89280000
close(3) = 0
openat(AT_FDCWD, "/usr/lib/libQt5Network.so.5", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0\267\0\1\0\0\0\2402\4\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1664936, ...}) = 0
mmap(NULL, 1733192, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f88b6d000
mprotect(0x7f88cf9000, 61440, PROT_NONE) = 0
mmap(0x7f88d08000, 49152, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x18b000) = 0x7f88d08000
mmap(0x7f88d14000, 584, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f88d14000
close(3) = 0
openat(AT_FDCWD, "/usr/lib/libQt5Script.so.5", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0\267\0\1\0\0\0\0;\4\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1996928, ...}) = 0
mmap(NULL, 2207928, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f88951000
mprotect(0x7f88b25000, 61440, PROT_NONE) = 0
mmap(0x7f88b34000, 86016, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1d3000) = 0x7f88b34000
mmap(0x7f88b49000, 143544, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f88b49000
close(3) = 0
openat(AT_FDCWD, "/usr/lib/tls/aarch64/libQt5Core.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/tls/aarch64", 0x7fd6a54d40, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/tls/libQt5Core.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/tls", 0x7fd6a54d40, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/aarch64/libQt5Core.so.5", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/aarch64", 0x7fd6a54d40, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/libQt5Core.so.5", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0\267\0\1\0\0\0\330\266\n\0\0\0\0\0"..., 832) = 832
lseek(3, 5678608, SEEK_SET) = 5678608
read(3, "\4\0\0\0\20\0\0\0\1\0\0\0GNU\0\0\0\0\0\3\0\0\0\21\0\0\0\0\0\0\0", 32) = 32
close(3) = 0
newfstatat(AT_FDCWD, "/usr/lib", {st_mode=S_IFDIR|0755, st_size=135168, ...}, 0) = 0
writev(2, [{iov_base="smtube", iov_len=6}, {iov_base=": ", iov_len=2}, {iov_base="error while loading shared libra"..., iov_len=36}, {iov_base=": ", iov_len=2}, {iov_base="libQt5Core.so.5", iov_len=15}, {iov_base=": ", iov_len=2}, {iov_base="cannot open shared object file", iov_len=30}, {iov_base=": ", iov_len=2}, {iov_base="No such file or directory", iov_len=25}, {iov_base="\n", iov_len=1}], 10smtube: error while loading shared libraries: libQt5Core.so.5: cannot open shared object file: No such file or directory
) = 121
exit_group(127) = ?
+++ exited with 127 +++')

This lists that other shared objects like libQt5Network.so.5 can be loaded no problem. Then the loader looks in the wrong places for libQt5Core.so.5, but still manges to find the correct one, and still returns not loading the shared object, but reporting on it missing.

Is there a problem with my set-up or is something wrong with the AARCH64 package?
naums
 
Posts: 27
Joined: Sun Dec 31, 2017 11:11 am

Re: [qt5-base] libQt5Core.so cannot be loaded

Postby saulhidalgoaular » Mon Jan 08, 2018 12:56 am

I have exactly the same error. I tried copying the library from other distro, and then I get this:

relocation error: /usr/lib/libKF5SonnetCore.so.5: symbol _ZNK9QIODevice20isTransactionStartedEv, version Qt_5 not defined in file libQt5Core.so.5 with link time reference
saulhidalgoaular
 
Posts: 2
Joined: Mon Jan 08, 2018 12:48 am

Re: [qt5-base] libQt5Core.so cannot be loaded

Postby saulhidalgoaular » Mon Jan 08, 2018 3:55 am

To solve this I had to downgrade to a kinda old version. You can download the rootfs here.

https://github.com/Preflex/easy-chroot/releases

Don't try to update it.
saulhidalgoaular
 
Posts: 2
Joined: Mon Jan 08, 2018 12:48 am

Re: [qt5-base] libQt5Core.so cannot be loaded

Postby flobe » Wed Jan 10, 2018 9:42 am

Confirmed here too. ldconfig finds libQt5Core.so.5 but ldd on any binary linking against it gives libQt5Core.so.5 => not found.
flobe
 
Posts: 9
Joined: Wed Jan 04, 2017 8:14 am

Re: [qt5-base] libQt5Core.so cannot be loaded

Postby armistice » Tue Jan 16, 2018 7:05 am

I have this problem as well. Downgrading to 5.9.3 seems to fix it, but then I get segfaults.
armistice
 
Posts: 1
Joined: Fri Jan 12, 2018 1:14 am

Re: [qt5-base] libQt5Core.so cannot be loaded [resolved]

Postby paulusx » Wed Jan 17, 2018 5:21 pm

I guess, I know what problem. Library required linux ABI 3.17.0 (see output of file → for GNU/Linux 3.17.0), but kernel on device have earlier version linux ABI. Used linux ABI Version defined by used features. See file qtbase/src/corelib/global/minimum-linux_p.h.

$this->bbcode_second_pass_quote('', '
')/* Minimum Linux kernel version:
* We require the following features in Qt (unconditional, no fallback):
* Feature Added in version Macro
* - inotify_init1 before 2.6.12-rc12
* - futex(2) before 2.6.12-rc12
* - FUTEX_WAKE_OP 2.6.14 FUTEX_OP
* - linkat(2) 2.6.17 O_TMPFILE && QT_CONFIG(linkat)
* - FUTEX_PRIVATE_FLAG 2.6.22
* - O_CLOEXEC 2.6.23
* - eventfd 2.6.23
* - pipe2 & dup3 2.6.27
* - accept4 2.6.28
* - renameat2 3.16 QT_CONFIG(renameat2)
* - getrandom 3.17 QT_CONFIG(getentropy)
*/


Update (resolve):
I appended `-no-feature-renameat2 -no-feature-getentropy -skip webengine` to configure version and rebuild.
I rebuild without webengine, because I have a problem with it. Problem of current subject is resolved.
paulusx
 
Posts: 1
Joined: Wed Jan 17, 2018 5:05 pm


Return to Packages

Who is online

Users browsing this forum: No registered users and 12 guests