Bug 990931 - it's not possible to rebuild dts valgrind on ia32 with -march=i386
it's not possible to rebuild dts valgrind on ia32 with -march=i386
Status: CLOSED CURRENTRELEASE
Product: Red Hat Developer Toolset
Classification: Red Hat
Component: doc-Release_Notes (Show other bugs)
DTS 2.0 RHEL 5
i386 Linux
medium Severity medium
: beta2
: 2.0
Assigned To: Eliska Slobodova
Miroslav Franc
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-08-01 04:46 EDT by Miroslav Franc
Modified: 2016-06-17 17:06 EDT (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Release Note
Doc Text:
Valgrind must be rebuilt without Red Hat Developer Toolset's gcc installed, or it will be used in preference to the RHEL system gcc, which will result in different binaries to those built and shipped by Red Hat. For any testing, Red Hat Developer Toolset's gdb should be used.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-08-07 03:16:30 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Miroslav Franc 2013-08-01 04:46:54 EDT
Description of problem:
On rhel5, the packages are build with -march=i386 by default, but this turns out to be very bad for valgrind.  It seems like some gcc buildin is missing there.  Rebuild with i486 fixed that for me.  Not entirely sure why it works in brew.  



Steps to Reproduce:
1. install dts valgrind srpm on rhel5 i386 machine
2. rpmbuild -ba /usr/src/redhat/SPECS/valgrind.spec


Actual results:
...
../coregrind/libcoregrind-x86-linux.a(libcoregrind_x86_linux_a-ticket-lock-linux.o): In function `release_sched_lock':
/usr/src/redhat/BUILD/valgrind-3.8.1/coregrind/m_scheduler/ticket-lock-linux.c:170: undefined reference to `__sync_fetch_and_add_4'
../coregrind/libcoregrind-x86-linux.a(libcoregrind_x86_linux_a-ticket-lock-linux.o): In function `acquire_sched_lock':
/usr/src/redhat/BUILD/valgrind-3.8.1/coregrind/m_scheduler/ticket-lock-linux.c:123: undefined reference to `__sync_fetch_and_add_4'
...

Expected results:
packages are build
Comment 1 Mark Wielaard 2013-08-01 08:09:59 EDT
Could you attach the full build log? Then we can see what configure detected. And we can compare with with the full build log in brew to see what that detected.

In particular it seems in your environment configure seems to think sync and fetch support is available while it really isn't (since it is i386). It should use alternative code that doesn't use sync and fetch.

Note You need to log in before you can comment on or make changes to this bug.