Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 51942 - lm_sensors-2.8.6 ebuild fails on amd64 w/relocation linker error
Summary: lm_sensors-2.8.6 ebuild fails on amd64 w/relocation linker error
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: AMD64 Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-05-24 13:55 UTC by Morgan Greenwood
Modified: 2004-05-28 09:43 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
ebuild output (lm_sensors-2.8.6-ebuild-output.txt,17.79 KB, text/plain)
2004-05-24 13:58 UTC, Morgan Greenwood
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Morgan Greenwood 2004-05-24 13:55:23 UTC
Noticed some files up above were compiled with both the -fpic and -fno-pic set.

Fails with this message:

/usr/lib/gcc-lib/x86_64-pc-linux-gnu/3.3.3/../../../../x86_64-pc-linux-gnu/bin/ld: lib/data.lo: relocation R_X86_64_32 can not be used when making a shared object; recompile with -fPIC
lib/data.lo: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [lib/libsensors.so.3.0.4] Error 1

Talked with "Lv" in the #gentoo-amd64 channel and he said to file a bug and let them know that "the filter-flags logic screws things up on amd64".
 

Reproducible: Always
Steps to Reproduce:
1. emerge lm_sensors
2.
3.

Actual Results:  
linker fails

Expected Results:  
linked sucessfully and installed
Comment 1 Morgan Greenwood 2004-05-24 13:58:16 UTC
Created attachment 31957 [details]
ebuild output
Comment 2 Rich Thompson 2004-05-26 20:52:16 UTC
Me too! More detail.

bash-2.05b# emerge -p lm-sensors

These are the packages that I would merge, in order:

Calculating dependencies ...done!
[ebuild  N    ] sys-apps/lm-sensors-2.8.6

bash-2.05b# emerge lm-sensors

Results in:

[snip]

gcc -shared -Wl,-soname,libsensors.so.3 -o lib/libsensors.so.3.0.4 lib/data.lo lib/general.lo lib/error.lo lib/chips.lo lib/proc.lo lib/access.lo lib/init.lo lib/conf-parse.lo lib/conf-lex.lo -lc -lm
/usr/lib/gcc/x86_64-pc-linux-gnu/3.4.0/../../../../x86_64-pc-linux-gnu/bin/ld: lib/data.lo: relocation R_X86_64_32 can not be used when making a shared object; recompile with -fPIC
lib/data.lo: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [lib/libsensors.so.3.0.4] Error 1
make: *** Waiting for unfinished jobs....

!!! ERROR: sys-apps/lm-sensors-2.8.6 failed.
!!! Function src_compile, Line 88, Exitcode 2
!!! Could not compile user-mode utilities!



64bit and using gcc 3.4.0-r4 [x86_64-pc-linux-gnu-3.4.0]. Kernel 2.6.5 as well... No 32 bit compat libraries. MSI K8T Master2-FAR dual opteron 244s.

USE="X arts qt kde dvd alsa cdr -gtk gtk2 truetype2 truetype freetype cups divx4linux imagemagick offensive opengl pdflib samba scanner usb xmms xvid"

CHOST="x86_64-pc-linux-gnu"

CFLAGS="-march=k8 -O2 -pipe -fomit-frame-pointer"
Comment 3 BonezTheGoon 2004-05-27 12:51:45 UTC
I am having the same problems, please see the corresponding thread in the Gentoo Forums here -- http://forums.gentoo.org/viewtopic.php?p=1180688

There I placed lots of output and information about my system in hopes of helping get this fixed.

Regards,
BonezTheGoon
Comment 4 Morgan Greenwood 2004-05-27 13:01:16 UTC
FYI, for a temporary work around to get the emerge to work, I commented out the filter-flags line on line 82.
Comment 5 Rich Thompson 2004-05-27 15:19:54 UTC
Morgan, commenting out line 82 in the lm-sensors-2.8.6.ebuild did the trick. lm_sensors compiles without issue and functions without issue.
Comment 6 Danny van Dyk (RETIRED) gentoo-dev 2004-05-28 09:43:28 UTC
I fixed it... someone filtered -fPIC without ${ARCH} check (again.) grml...