On Sun, 29 Dec 2013, Jan Engelhardt wrote:
On Sunday 2013-12-29 03:24, Ilya Chernykh wrote:
What causes this package to fail for 32-bit but build for 64-bit in Factory?
https://build.opensuse.org/package/show/KDE:KDE3/kdelibs3
I receive the following error message:
[ 666s] /usr/lib/libc_nonshared.a(stack_chk_fail_local.oS): In function `__stack_chk_fail_local': [ 666s] /home/abuild/rpmbuild/BUILD/glibc-2.18.90/debug/stack_chk_fail_local.c:45: undefined reference to `__stack_chk_fail' [ 666s] collect2: error: ld returned 1 exit status [ 666s] Error creating ./kdeprint/management/libkdeinit_kaddprinterwizard.la. Exit status 1.
__stack_chk_fail is only present in libc.a, but not libc_nonshared.a.
-rw-r--r-- 1 root root 23502316 Dec 10 13:09 libc.a -rw-r--r-- 1 root root 72190 Dec 10 13:14 libc_nonshared.a
Given the huge size difference would indicate to me that whenever you attempt to link in libc_nonshared.a (why would you do that on your own?), you must also link in libc.a — and do so in the proper order, which kdeprint might fail to do.
(And it also raises the question why you are even building statically.)
The symbol is part of libc.so as well, given the name libc_nonshared.a is always linked statically - libc.so is a linker script: /* GNU ld script Use the shared library, but some functions are only in the static library, so try that secondarily. */ OUTPUT_FORMAT(elf64-x86-64) GROUP ( /lib64/libc.so.6 /usr/lib64/libc_nonshared.a AS_NEEDED ( /lib64/ld-linux-x86-64.so.2 ) ) Richard.