Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Stage 1 on Stage 3 -> # emerge glibc binutils gcc[SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
l1ltw1st
n00b
n00b


Joined: 19 Feb 2005
Posts: 12
Location: Boston

PostPosted: Mon Feb 21, 2005 3:25 am    Post subject: Stage 1 on Stage 3 -> # emerge glibc binutils gcc[SOLVED] Reply with quote

I get the following error:

...
checking whether ln works... yes
checking whether ln -s works... yes
checking for gcc... gcc
checking whether the C compiler (gcc -O2 -march=pentium -mtune=pentium -pipe) works... no
configure: error: installation or configuration problem: C compiler canot create executables.

!!! ERROR: sys-devel/binutils-2.15.92.0.2-r1 failed.
!!! Function src_compile, Line 80, Exitcode 1
!!! (no error message)
...

livecd / #emerge info
Portage 2.0.51-r3 (default-Linux/x86/2005.0, gcc-hardened, glibc-2.3.4.20040808-r1, 2.6.10-gentoo-r6 i686)
===========================================
System uname: 2.6.10-gentoo-r6 i686 Intel(R) Pentium(R) 4 CPU 2.40GHz
Gentoo Base System Version 1.4.16
Autoconf: sys-devel/autoconf-2.59-r5
Automake: sys-devel/automake-1.8.5-r1
Binutils: sys-devel/binutils-2.15.92.0.2-r1
Headers: sys-kernel/linux26-headers-2.6.8.1-r2
Libtools: sys-devel/libtool-1.5.2-r7
ACCEPT-KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=pentium -mtune=pentium -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=pentium -mtune=pentium -pipe"
DISTDIR="usr/portage/distfiles"
FEATURES="autoaddcvs utoconfig ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="http://gentoo.osuosl.org"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 apm avi berkb bitmap-fonts cdr cups dv dvdr emboss encode f77 foomaticdb fortran gdbm gif gnome gpm gtk gtk2 imlib ipv6 jpeg libg++ libwww mad mikmod motif mozilla mpeg ncurses nls oggvorbis opengl oss pam perl png python quicktime readline samba sdl spell ssl svga tcpd trutype-fonts type1-fonts xml2 xmms xv zlib"

livecd / #
...

I know I am probably a tad new to gentoo for using this method, I have been working with Libranet, Yoper and FreeBSD (5.x series mostly) over the last few years and have a background of Sun OS 2.x and 3.x (ooof, aging myself now). I enjoy a challenge and want to build a strong version of this, and this appears to fit that desire (along with some learning hopefully).

Any help would be greatly appreciated. :)
_________________
<xterm> The problem with America is stupidity. I'm not saying there should be a capital punishment for stupidity, but why don't we just take the safety labels off of everything and let the problem solve itself?


Last edited by l1ltw1st on Tue Feb 22, 2005 3:48 am; edited 2 times in total
Back to top
View user's profile Send private message
po0f
Apprentice
Apprentice


Joined: 08 Apr 2004
Posts: 162

PostPosted: Mon Feb 21, 2005 3:40 am    Post subject: Reply with quote

Change your cflags. You have them set to PENTIUM when you have a PENTIUM4.
Back to top
View user's profile Send private message
kimchi_sg
Advocate
Advocate


Joined: 26 Nov 2004
Posts: 2915
Location: Singapore

PostPosted: Mon Feb 21, 2005 3:40 am    Post subject: Reply with quote

At which stage are you in the install?

Specifically, have you already done this command?
Code:
emerge gcc-config gcc glibc binutils


If you have not done the above command, you have not upgraded your gcc yet. CFLAGS="-mtune=..." is usable only if you have already emerged gcc and switched to it via gcc-config.

In short, remove -mtune from your CFLAGS and retry.
_________________
Murphy's Law of Gentoo installation: If a compile can fail, it will.

MacGillicuddy's Corollary: At the most inopportune time.

Please search and read the FAQs before posting.
Back to top
View user's profile Send private message
kimchi_sg
Advocate
Advocate


Joined: 26 Nov 2004
Posts: 2915
Location: Singapore

PostPosted: Mon Feb 21, 2005 3:50 am    Post subject: Reply with quote

l1ltw1st wrote:
As to the P4 statement, I was trying to be slightly more general as to avoid as many hiccups as possible, being that all Intel processors are backwards compat, I wouldn't think this to be an issue... ???

This is not an issue. Having CFLAGS="-march=pentium4" is perfectly justified when your system IS a pentium 4. There will be no problems introduced just by optimising for your specific processor.

In fact, if you compile for pentium, you are just hamstringing your system by forcing it to be so backward compatible that it cannot compile code optimised for your processor.

As a side note, having both -march and -mtune in CFLAGS is redundant. Read /etc/make.conf.example for the reason why.
_________________
Murphy's Law of Gentoo installation: If a compile can fail, it will.

MacGillicuddy's Corollary: At the most inopportune time.

Please search and read the FAQs before posting.
Back to top
View user's profile Send private message
po0f
Apprentice
Apprentice


Joined: 08 Apr 2004
Posts: 162

PostPosted: Mon Feb 21, 2005 3:52 am    Post subject: Reply with quote

Even if it were backwards compatible (which I don't think it is), what's the point of using a distribution that *optimizes* your computer with all the new features that your p4 can handle?

[edit] Spelling error.
Back to top
View user's profile Send private message
l1ltw1st
n00b
n00b


Joined: 19 Feb 2005
Posts: 12
Location: Boston

PostPosted: Mon Feb 21, 2005 4:02 am    Post subject: Reply with quote

heh, I guess I didn't pull my post fast enough, I rethought my position on that and I am ammeding the make.conf as we speak...
_________________
<xterm> The problem with America is stupidity. I'm not saying there should be a capital punishment for stupidity, but why don't we just take the safety labels off of everything and let the problem solve itself?
Back to top
View user's profile Send private message
po0f
Apprentice
Apprentice


Joined: 08 Apr 2004
Posts: 162

PostPosted: Mon Feb 21, 2005 4:10 am    Post subject: Reply with quote

No worries, just trying to help.

Of course, if you really don't want the p4, I'll swap you for a p3 celeron.
Back to top
View user's profile Send private message
Azzz
n00b
n00b


Joined: 21 Feb 2005
Posts: 4

PostPosted: Mon Feb 21, 2005 3:46 pm    Post subject: Reply with quote

I had this problem when doing the stage 1 on stage 3
To emerge binutils-2.15.92.0.2-r1 I had to remove the -mtune flag just for this package
After I put it back and when reemerging binutils-2.15.92.0.2-r1 with gcc 3.4.3 all went perfectly.

Sorry for my bad english
I hope it will help you
Back to top
View user's profile Send private message
l1ltw1st
n00b
n00b


Joined: 19 Feb 2005
Posts: 12
Location: Boston

PostPosted: Tue Feb 22, 2005 3:47 am    Post subject: Reply with quote

Thanks everyone, removing -mtune=pentium4 did the trick...

CYA on the next hiccup :P
_________________
<xterm> The problem with America is stupidity. I'm not saying there should be a capital punishment for stupidity, but why don't we just take the safety labels off of everything and let the problem solve itself?
Back to top
View user's profile Send private message
Bob P
Advocate
Advocate


Joined: 20 Oct 2004
Posts: 3355
Location: Jackass! Development Labs

PostPosted: Tue Feb 22, 2005 7:33 am    Post subject: Reply with quote

l1ltw1st wrote:
Thanks everyone, removing -mtune=pentium4 did the trick...


was there something unclear in the guide? or did you end up modifying the installation method to make it "better'?

as kimchi noted, if you're following the guide, as of section 7.1, "mtune" should NOT be in your CFLAGS. you shouldn't have mtune in your CFLAGS until section 7.2.

i can't even tell you how many people have fubar'd their Stage 1 on 3 installation by deciding to "change things for the better" instead of following the guide as its written. that installation method is pretty sophisticated, and requires that the user make a number of very subtle yet critical changes to the system. in other words, if you deviate from the guide, its really easy to royally screw it up if you're not highly knowledgeable in gentoo. if you're new to gentoo and you want to follow the guide, please try to resist the temptation to make changes that aren't recommended, so that you don't find youself opening another support thread. :wink:

good luck.
_________________
.
Stage 1/3 | Jackass! | Rockhopper! | Thanks | Google Sucks
Back to top
View user's profile Send private message
Bob P
Advocate
Advocate


Joined: 20 Oct 2004
Posts: 3355
Location: Jackass! Development Labs

PostPosted: Tue Feb 22, 2005 8:54 am    Post subject: Reply with quote

oh yes... regarding the use of "-march=pentium", technically, there's nothing wrong with doing that -- you'll just use your pentium 4 to create code that is optimized for all pentium processors, and the code won't include any machine-specific instructions that will optimize the code for the P4 processor.

this will make highly portable code that you can take to any pentium-brand processor and run without problems (like the gentoo x86 packages). that wouldn't be the case if you used march=pentium4.

i do this all the time on purpose -- i'll compile on a faster PC (like a P3) using march=pentium, and clone the hard disk and put a copy into a PC with any generation of x86 pentium processors. this way, i don't have to go through the trouble of doing an install for every machine. i just copy a pentium-class partition into the PC, change the march cflag, and recompile on the new box.
_________________
.
Stage 1/3 | Jackass! | Rockhopper! | Thanks | Google Sucks
Back to top
View user's profile Send private message
l1ltw1st
n00b
n00b


Joined: 19 Feb 2005
Posts: 12
Location: Boston

PostPosted: Wed Feb 23, 2005 4:58 am    Post subject: Reply with quote

yes, I fubar'd, I read ahead /me slaps own hand...

I see what you are saying and the advantage to doing so as to -march=pentium. I have a couple of P-III's I am looking to move from other various nix to gentoo if this works out, maybe I should use -march=pentium3 (I am once again redoing this as I messed up somewhere and only got *-gnu-3.3.5 on my gcc-config -l ).

Learning a bunch though, and great job on the pdf, which is what I am following (ssh'd in to gentoo system from another machine with pdf up on laptop :p)
_________________
<xterm> The problem with America is stupidity. I'm not saying there should be a capital punishment for stupidity, but why don't we just take the safety labels off of everything and let the problem solve itself?
Back to top
View user's profile Send private message
naviathan
Apprentice
Apprentice


Joined: 12 Dec 2004
Posts: 231

PostPosted: Wed Feb 23, 2005 8:25 am    Post subject: Reply with quote

Where did the -mtune= cflag come from? I have never had that optimization work on any system. It always causes that problem. I tried -mtune=k8 for my AMD64 and it did the same thing. Is this just not an accetable cflag for gcc anymore (if ever)?
_________________
I respect faith, but doubt is what gives you an education.
-- Wilson Mizner
Back to top
View user's profile Send private message
kimchi_sg
Advocate
Advocate


Joined: 26 Nov 2004
Posts: 2915
Location: Singapore

PostPosted: Wed Feb 23, 2005 9:19 am    Post subject: Reply with quote

naviathan01 wrote:
Where did the -mtune= cflag come from? I have never had that optimization work on any system. It always causes that problem. I tried -mtune=k8 for my AMD64 and it did the same thing. Is this just not an accetable cflag for gcc anymore (if ever)?

It will work, but only if you are using gcc-3.4.x. If you upgraded gcc, you will need to explicitly switch to the new version using gcc-config:
Code:
gcc-config -l     <- check which profile has gcc 3.4.x
gcc-config X     <- where X is the number of the profile with gcc-3.4.x
env-update
source /etc/profile

_________________
Murphy's Law of Gentoo installation: If a compile can fail, it will.

MacGillicuddy's Corollary: At the most inopportune time.

Please search and read the FAQs before posting.
Back to top
View user's profile Send private message
Bob P
Advocate
Advocate


Joined: 20 Oct 2004
Posts: 3355
Location: Jackass! Development Labs

PostPosted: Wed Feb 23, 2005 9:24 pm    Post subject: Reply with quote

yes, there are some new flags that have become available with GCC 343, and mtune is one of them. there are quite a few flags that were in widespread use with GCC 334 that are now deprecated in GCC 343, and there are new flags in GCC 343 that will bork if you use them with GCC 334.

if you're experienced with GCC 334 and you're moving to GCC 343, it would probably be worth the time to read through the GCC man page. its painfully long and tedious to read, but there is some very helpful information buried in there.

the sticky "GCC 3.4.3 is Upon Us" thread in Portage and Programming is also a very helpful thread to read. :idea:
_________________
.
Stage 1/3 | Jackass! | Rockhopper! | Thanks | Google Sucks
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum