Closed Bug 358559 Opened 13 years ago Closed 13 years ago
_386 _PC32 relocations in libxul .so when building on FC6
When building on Fedora Core 6 (where our system wrappers stuff works, and where the big gcc visibility bug is fixed), SELinux prevents me from starting due to the bad type of relocations in libtracemalloc.so and libxul.so. This bug covers the problem in libxul.so. I don't understand this problem yet, so if you do, feel free to take it, but I'm planning to debug it later today. The problem is a single relocation (as shown by objdump -R libxul.so): 0000de67 R_386_PC32 __cxa_pure_virtual There are plenty of other relocations for __cxa_pure_virtual of the healthier R_386_32 sort, but there's this lonely one relocation that prevents my default build from running with all the SELinux protection enabled.
For what it's worth, objdump -sdR libxul.so shows the relocation in question as being in the midst of code compiled from toolkit/xre/nsAppRunner.cpp . It's in: 0000de60 <__pure_virtual>: de60: 55 push %ebp de61: 89 e5 mov %esp,%ebp de63: 83 ec 08 sub $0x8,%esp de66: e8 fc ff ff ff call de67 <__pure_virtual+0x7> de67: R_386_PC32 __cxa_pure_virtual de6b: c9 leave de6c: c3 ret de6d: 90 nop de6e: 66 90 xchg %ax,%ax which immediately follows the definition of _ZN12nsXULAppInfo9GetVendorER19nsACString_internal (which is the last of a bunch of the nsXULAppInfo methods that are in the binary in reverse order from their order in the source). Following it are lots of things that would normally be inlined (this is a -g -O2 -fno-inline build).
Oh, this is the MOZ_ENABLE_OLD_ABI_COMPAT_WRAPPERS code.
Ah, we have a system wrapper for pk11func.h but not for pk11pub.h .
Er, wrong bug.
Comment on attachment 243936 [details] [diff] [review] patch What were these symbols for? Can they be removed yet?
Attachment #243936 - Flags: review?(benjamin) → review+
They're from bug 154206 -- and I'd sort of expect they're still needed.
And I realize I should land the same patch in xpfe/bootstrap, since this code still lives there too...
Checked in to trunk.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
This is just the previous patch doubled, and what I landed just now.
Comment on attachment 243987 [details] [diff] [review] patch landed This is a low risk patch that will, along with the patches to bug 358558 and bug 358565: * allow Linux distros to take advantage of performance optimizations (prelinking) and security improvements (SELinux) * make it easier for developers to build on new distributions like Fedora Core 6
Comment on attachment 243987 [details] [diff] [review] patch landed FWIW, we could probably have used HAVE_VISIBILITY_ATTRIBUTE instead of doing -DWRAP_SYSTEM_INCLUDES.
Attachment #243987 - Flags: review?(benjamin) → review+
Comment on attachment 243987 [details] [diff] [review] patch landed approved for 1.8/1.8.0 branches, a=dveditz for drivers
You need to log in before you can comment on or make changes to this bug.