Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 559460

Summary: net-analyzer/wireshark-1.12.7 - ld: dissectors/.libs/libdissectors.a(libdissectors_la-packet-catapult-dct2000.o): relocation R_X86_64_32S against `.bss' can not be used when making a shared object; recompile with -fPIC
Product: Gentoo Linux Reporter: Alex Orange <crazycasta>
Component: Current packagesAssignee: Gentoo Netmon project <netmon>
Status: RESOLVED WORKSFORME    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: emerge --info '=net-analyzer/wireshark-1.12.7::gentoo'
emerge -pqv '=net-analyzer/wireshark-1.12.7::gentoo'
environment
build.log.bz2

Description Alex Orange 2015-09-02 23:21:21 UTC
I do:

$ sudo emerge -av wireshark

I get the following error message:

/usr/lib/gcc/x86_64-pc-linux-gnu/4.8.4/../../../../x86_64-pc-linux-gnu/bin/ld: dissectors/.libs/libdissectors.a(libdissectors_la-packet-catapult-dct2000.o): relocation R_X86_64_32S against `.bss' can not be used when making a shared object; recompile with -fPIC
dissectors/.libs/libdissectors.a(libdissectors_la-packet-catapult-dct2000.o): error adding symbols: Bad value


Reproducible: Always

Steps to Reproduce:
1. sudo emerge -av wireshark
2.
3.
Actual Results:  
See error message above.

Expected Results:  
No error message, wireshark installs.
Comment 1 Alex Orange 2015-09-02 23:21:51 UTC
Created attachment 410888 [details]
emerge --info '=net-analyzer/wireshark-1.12.7::gentoo'
Comment 2 Alex Orange 2015-09-02 23:22:22 UTC
Created attachment 410890 [details]
emerge -pqv '=net-analyzer/wireshark-1.12.7::gentoo'
Comment 3 Alex Orange 2015-09-02 23:26:32 UTC
Created attachment 410892 [details]
environment
Comment 4 Alex Orange 2015-09-02 23:28:23 UTC
I can't seem to upload my build.log file for some reason. Not sure why but the page just sits there and appears to do nothing. I tried uploading it raw, saw that that was almost 5 MB so then I bzip2'd it to 57k and it still won't let me upload. Let me know how to upload it if you need that file.
Comment 5 Jeroen Roovers (RETIRED) gentoo-dev 2015-09-15 03:56:39 UTC

*** This bug has been marked as a duplicate of bug 552440 ***
Comment 6 Rafał Mużyło 2015-09-21 12:55:52 UTC
(In reply to Jeroen Roovers from comment #5)
> 
> *** This bug has been marked as a duplicate of bug 552440 ***

Interesting conclusion - what seems to have been a linking problem a duplicate of a bug that's triggered at preprocessing stage...

:roll: Still, without the build log, it wasn't getting anywhere.
Comment 7 Alex Orange 2015-09-28 02:04:12 UTC
Upon further investigation, I do not believe this is a duplicate. I do not have the qt5 USE flag set, this is not complaining at compile time and it's not limited to gcc-5 and up (as the other bug claims to be).

I would be very happy to upload the build log, I'll give it another try right now, but assuming you don't see anything then it's the same problem as before, I click to upload and nothing happens.
Comment 8 Alex Orange 2015-09-28 02:05:55 UTC
Created attachment 413120 [details]
build.log.bz2
Comment 9 Alex Orange 2015-09-28 02:06:41 UTC
Hmm, apparently my browser is too stupid to tell me when it can't access the file. Though I could've sworn I bzip2'd it as my user and not root, guess I'm just crazy.
Comment 10 Alex Orange 2015-09-28 16:07:37 UTC
Ok, further information: I tried applying the patch from the 	
a2fec21 patchset mentioned in https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=11230 . It had no effect.

I've tried removing the qt4 flag (as well as the qt5 flag which was never set in the first place). It still fails.
Comment 11 Alex Orange 2015-09-28 16:40:16 UTC
Ok, after trying many things (including a clean configure/make outside of portage) I found the problem seems to be with my use of -O3. I've added a package.env file to handle this for the moment, but what is the long term fix for this?
Comment 12 Rafał Mużyło 2015-09-29 14:21:47 UTC
Well, given your tests and the fact that '-DPIC -fPIC' is already passed to the compiler, it doesn't seem to be a build system bug.

You don't seem to have/use ccache either.

Might be a compiler bug then.

Did you try to narrow this down to a specific optimization switch ?
Comment 13 Alex Orange 2015-09-29 16:32:32 UTC
By specific optimization switch you mean one of the -fblah-blah switches that's under -O3 but not -O2? No, I did not try that. Is there an easier way (i.e. a tool) to do that then brute force?