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

Bug 486774

Summary: sys-libs/glibc-2.15-r3 - configure: error: support for __builtin_expect needed
Product: Gentoo Linux Reporter: Walter <walter>
Component: [OLD] Core systemAssignee: Gentoo Toolchain Maintainers <toolchain>
Status: RESOLVED INVALID    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: gcc-issue-logs.zip
builtin expect log
config.log

Description Walter 2013-10-02 10:12:26 UTC
Installed profile amd64 hardened nomultilib.

Needed to run Skype.

Changed profile to multilib hardened.

Re-emerged a lot of stuff with no problems, but gcc refuses to rebuild with this error.

Reproducible: Always

Steps to Reproduce:
1. emerge glibc
Actual Results:  
configure: error: support for __buildtin_expect needed

Expected Results:  
Build succeeds.


Not sure if this is considered a normal use case but other builds work so I suppose gcc should too. Basically my stage3 is hosed, I am going to install from scratch.
Comment 1 Walter 2013-10-02 10:13:09 UTC
Err, that's 'builtin' not 'build tin'.
Comment 2 Rafał Mużyło 2013-10-03 05:13:05 UTC
At minimum, config.log is needed.
Comment 3 Walter 2013-10-03 05:55:17 UTC
Created attachment 360008 [details]
gcc-issue-logs.zip
Comment 4 Rafał Mużyło 2013-10-03 08:51:48 UTC
(In reply to Walter from comment #3)
> Created attachment 360008 [details]
> build log, config.log, other logs

First of all, the error in the log is different than the one initially reported.

As a side note: I'm not sure if such profile change is supported at all.

Having said that, try reemerging glibc first.
Comment 5 Walter 2013-10-03 15:18:05 UTC
Yeah, tried glibc first. No luck. I guess it's another stage 3 from scratch for me :(

Not sure how the log was different. Here's a retry which seems to be the same.

Anyway, yeah. I figured it'd be something like "not supported". Guess we can close this issue.
Comment 6 Walter 2013-10-03 15:18:33 UTC
Created attachment 360068 [details]
builtin expect log
Comment 7 Rafał Mużyło 2013-10-03 18:33:20 UTC
(In reply to Walter from comment #6)
> Created attachment 360068 [details]
> builtin expect log

So, what about config.log from this build log ?
Comment 8 Walter 2013-10-03 23:39:50 UTC
Created attachment 360088 [details]
config.log
Comment 9 Rafał Mużyło 2013-10-04 03:48:40 UTC
(In reply to Walter from comment #8)
> Created attachment 360088 [details]
> config.log

configure:7204: x86_64-pc-linux-gnu-gcc -m32 -march=i686 -pipe -O2 -fno-strict-aliasing -fno-stack-protector -U_FORTIFY_SOURCE -DPIC -U_FORTIFY_SOURCE -DPIC -U_FORTIFY_SOURCE -DPIC -Wl,-O1 -Wl,--as-needed -nostdlib -nostartfiles
			    -o conftest conftest.c -lgcc >&5
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.3/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-pc-linux-gnu/4.6.3/libgcc.a when searching for -lgcc
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.3/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find -lgcc
collect2: ld returned 1 exit status

So it's a chicken-egg or - more exactly - a bootstrap problem.
You seem to need a multilib gcc to build a multilib gcc.
You might get around that for example by picking up gcc from tinderbox (put the tarball in correct place and use '-K' in emerge).
Comment 10 SpanKY gentoo-dev 2013-10-04 05:42:09 UTC
(In reply to Rafał Mużyło from comment #9)

correct.  if you want to run 32bit things like skype, use a multilib profile.