Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
" C compiler cannot create executables"
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC
View previous topic :: View next topic  
Author Message
maekern
n00b
n00b


Joined: 12 Jul 2007
Posts: 3

PostPosted: Thu Jul 12, 2007 4:19 am    Post subject: " C compiler cannot create executables" Reply with quote

I've just installed Gentoo for the first time on a PPC machine. A dual g4 powermac, to be specific. I had to use the manual installation method outlined in http://www.gentoo.org/doc/en/handbook/handbook-ppc.xml?full=1 and everything seemed to go well. When I had booted to the liveCD, and chrooted into my new environment, I was able to emerge left and right with no trouble.

However, once I booted off of the hard drive for the first time, I've found myself unable to emerge anything. emerge fails with the following: (in this example, I was emerging vim)


Code:
checking whether make sets $(MAKE)... yes
checking for powerpc-unknown-linux-gnu-gcc... powerpc-unknown-linux-gnu-gcc
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.

!!! ERROR: app-editors/vim-core-7.0.235 failed.
Call stack:
  ebuild.sh, line 1621:   Called dyn_compile
  ebuild.sh, line 973:   Called qa_call 'src_compile'
  ebuild.sh, line 44:   Called src_compile
  ebuild.sh, line 1311:   Called vim_src_compile
  vim.eclass, line 474:   Called econf '--with-features=tiny' '--enable-gui=no' '--without-x' '--dis
able-perlinterp' '--disable-pythoninterp' '--disable-rubyinterp' '--disable-gpm' '--enable-nls' '--e
nable-acl' '--with-tlib=curses' '--disable-selinux' '--with-modified-by=Gentoo-7.0.235'
  ebuild.sh, line 578:   Called die

!!! econf failed
!!! If you need support, post the topmost build error, and the call stack if relevant.
!!! A complete build log is located at '/var/tmp/portage/app-editors/vim-core-7.0.235/temp/build.log'.



I think that it may have something to do with the flags set in my make.conf file, the contents of which I will also post here:

Code:
# These settings were set by the catalyst build script that automatically
# built this stage.
# Please consult /etc/make.conf.example for a more detailed example.
CFLAGS="-O2 -mcpu=G4 -mtune=G4 -maltivec -mabi=altivec -fno-strict-aliasing -pipe"
CXXFLAGS="${CFLAGS}"
# This should not be changed unless you know exactly what you are doing.  You
# should probably be using a different stage, instead.
CHOST="powerpc-unknown-linux-gnu"
GENTOO_MIRRORS="http://gentoo.osuosl.org/ "
USER="altivec -x -gtk -gnome -kde apache2 dvd dvdread server"


Any help would be appreciated. I was a linux user all through college, but drifted away back around 2001. I'm working my way back into using linux, and am amazed at how far things have progressed. But there are always those small things that stop you dead in your tracks. Small things like being unable to install any software. :)
Back to top
View user's profile Send private message
John R. Graham
Administrator
Administrator


Joined: 08 Mar 2005
Posts: 10286
Location: Somewhere over Atlanta, Georgia

PostPosted: Thu Jul 12, 2007 9:42 am    Post subject: Reply with quote

Check Gentoo's Frequently Asked Questions forum. This issue comes up a lot, but there are multiple causes.

- John
Back to top
View user's profile Send private message
JoseJX
Retired Dev
Retired Dev


Joined: 28 Apr 2002
Posts: 2774

PostPosted: Thu Jul 12, 2007 1:53 pm    Post subject: Reply with quote

You can also check config.log as configure suggests. This might shed some light as to why it's failing.
_________________
Gentoo PPC FAQ: http://www.gentoo.org/doc/en/gentoo-ppc-faq.xml
Back to top
View user's profile Send private message
maekern
n00b
n00b


Joined: 12 Jul 2007
Posts: 3

PostPosted: Thu Jul 12, 2007 2:27 pm    Post subject: Reply with quote

Quote:
You can also check config.log as configure suggests. This might shed some light as to why it's failing.


I actually couldn't find where config.log was located. It wasn't in the current directory, and it wasn't in /var/log

Fortunately, I resolved the problem, and I now feel like an idiot. I'll say how I fixed it, in case anyone else is as foolish as me and encounters the same problem.


While I was emerging a number of packages, I wanted to also look at my kernel and play around a bit with the options in "make menuconfig" for building a better kernel later. Not knowing much about the internals of make, I didn't realize that this would be a problem, but I later deduced that my compilation problems started when I did that. Essentially, I had multiple instances of make trying to do work at the same time.

In short: rebooting resolved the problem, though I suspect that "make clean" would have done so also.
Back to top
View user's profile Send private message
PMcCauley
Apprentice
Apprentice


Joined: 14 Mar 2006
Posts: 283
Location: Alberta, Canada

PostPosted: Thu Jul 12, 2007 4:17 pm    Post subject: Reply with quote

I noticed in your make.conf this line:

USER="altivec -x -gtk -gnome -kde apache2 dvd dvdread server"

Should be USE="altivec -x -gtk -gnome -kde apache2 dvd dvdread server"

Not sure if that is related. Also you may want to check this page http://gentoo-wiki.com/Safe_Cflags and try the CFLAGS recommended there.

Patrick
Back to top
View user's profile Send private message
maekern
n00b
n00b


Joined: 12 Jul 2007
Posts: 3

PostPosted: Thu Jul 12, 2007 8:35 pm    Post subject: Reply with quote

Quote:
I noticed in your make.conf this line:

USER="altivec -x -gtk -gnome -kde apache2 dvd dvdread server"

Should be USE="altivec -x -gtk -gnome -kde apache2 dvd dvdread server"


Oh wow! I really should have noticed that. Thanks. The devil is in the details.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC 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