Bug 1070906

Summary: glibc: Fail to build shared objects that use libmvec.so functions.
Product: [openSUSE] openSUSE Distribution Reporter: Martin Hauke <mardnh>
Component: BasesystemAssignee: E-mail List <bnc-team-screening>
Status: RESOLVED DUPLICATE QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: astieger
Version: Leap 42.3   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Martin Hauke 2017-12-03 13:28:37 UTC
With gcc6 or gcc7 you can build shared objects which are optimized to call libmvec.so functions. When such calls go through the _finite aliases the linker is unable to assemble the final user shared object because the calls contain non-PIC relocs against shared object symbols.

The build failures being seen on Leap systems are:
$ gcc-6 ./log.c -O3 -fopenmp -ffast-math -I/usr/include -fPIC -shared -lm -o log.so
/usr/lib64/gcc/x86_64-suse-linux/6/../../../../x86_64-suse-linux/bin/ld: /usr/lib64/libmvec_nonshared.a(svml_finite_alias.o_X86_64_PC32 against symbol `_ZGVbN2v_log@@GLIBC_2.22' can not be used when making a shared object; recompile with -fPIC
/usr/lib64/gcc/x86_64-suse-linux/6/../../../../x86_64-suse-linux/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status

The bug seems known fixed upstream:
https://sourceware.org/bugzilla/show_bug.cgi?id=19590
https://lists.debian.org/debian-glibc/2016/03/msg00125.html
Comment 1 Andreas Stieger 2017-12-03 13:31:03 UTC
dup

*** This bug has been marked as a duplicate of bug 1070905 ***