Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
No 64b executable support in GCC3.3.5?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc
View previous topic :: View next topic  
Author Message
bartg
n00b
n00b


Joined: 23 Sep 2005
Posts: 2

PostPosted: Fri Sep 23, 2005 2:12 am    Post subject: No 64b executable support in GCC3.3.5? Reply with quote

Hello, all. Thanks for putting together such a great distro for reviving old Sun hardware without resorting to Solaris. Before continuing I'll point out that I installed from 2005.01, stage 3.

I've checked out the source for GRUB2 from CVS and am playing with it, looking to do a little testing or the new SPARC64 support and hopefully some bugfixing. But gcc claims to not have 64bit support:

Code:
$ echo "int main(){ return 0; }" | gcc -x c -m64 -
cc1: error: -m64 is not supported by this configuration
cc1: error: -mlong-double-64 not allowed with -m64


I suppose it knows best what it can and cannot do, so the next question is how to upgrade gcc to support 64bit executables?

Can I just tweak a compile flag for gcc (which?) and rebuild it?

Or do I need to do something more involved? Am I going to regret not going with a stage 1 install? :)
Back to top
View user's profile Send private message
wescott
Apprentice
Apprentice


Joined: 18 Feb 2004
Posts: 183
Location: A giant shoe

PostPosted: Fri Sep 23, 2005 4:12 am    Post subject: Reply with quote

I would recomend Bob Predainas stage 3/1 install method for building a more recent toolchain (his howto is in the tips&tricks forum). After completing the proccess, to an emerge -e world, and you should have good 64 bit support.
_________________
Sometimes you feel like a nut, sometimes you don't
Gentoo Forum Member #43303

Yoda of Borg are we: Futile is resistance. Assimilate you, we will.
Back to top
View user's profile Send private message
bartg
n00b
n00b


Joined: 23 Sep 2005
Posts: 2

PostPosted: Fri Sep 23, 2005 10:12 pm    Post subject: Reply with quote

Thanks! For anyone others in the same boat, that howto is here:

https://forums.gentoo.org/viewtopic-t-345229-highlight-gcc.html
Back to top
View user's profile Send private message
squash
Tux's lil' helper
Tux's lil' helper


Joined: 22 Jun 2002
Posts: 79

PostPosted: Sat Sep 24, 2005 12:39 am    Post subject: Reply with quote

I think you'll be disappointed, as those directions will help you build gcc3.4.4 on an x86 system. It certainly won't help you get 64 bit compilation on a sparc platform.

Either way, 64 bitness on sparc is a Frequently Asked Question. The short version is, its slower than 32 bit in almost all cases, and is not officially supported in Gentoo right now. The long version is, use the search function.
Back to top
View user's profile Send private message
wescott
Apprentice
Apprentice


Joined: 18 Feb 2004
Posts: 183
Location: A giant shoe

PostPosted: Sat Sep 24, 2005 3:06 am    Post subject: Reply with quote

squash wrote:
I think you'll be disappointed, as those directions will help you build gcc3.4.4 on an x86 system. It certainly won't help you get 64 bit compilation on a sparc platform.

Either way, 64 bitness on sparc is a Frequently Asked Question. The short version is, its slower than 32 bit in almost all cases, and is not officially supported in Gentoo right now. The long version is, use the search function.
The compilers are just as available for 64-bit systems. You just have to make slight adjustments to the guide for any other arch. The newer compiler is much better in supporting its proclaimed features.
_________________
Sometimes you feel like a nut, sometimes you don't
Gentoo Forum Member #43303

Yoda of Borg are we: Futile is resistance. Assimilate you, we will.
Back to top
View user's profile Send private message
Emphii
n00b
n00b


Joined: 08 Oct 2004
Posts: 46

PostPosted: Sat Sep 24, 2005 11:37 am    Post subject: Reply with quote

Yes please. I did sort of that stage 3/1-install. Somehow following BobP's instruction and somehow following Gentoo Installation manual.
Atleast, I have now
Code:
gcc (GCC) 3.4.4 (Gentoo 3.4.4-r1, ssp-3.4.4-1.0, pie-8.7.8)
Copyright (C) 2004 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

but BartG's little line gave
Code:
echo "int main(){ return 0; }" | gcc -x c -m64 -
:1: error: -m64 is not supported by this configuration
:1: error: -mlong-double-64 not allowed with -m64

This comes to use, if linking make.profile to /usr/portage/profiles/default-linux/sparc/sparc64/dev.

Anyway. I took these flags to use:
Code:
CFLAGS="-O3 -mcpu=ultrasparc -pipe -fomit-frame-pointer -funroll-loops -fforce-addr"
CHOST="sparc-unknown-linux-gnu"
CXXFLAGS="${CFLAGS} -fvisibility-inlines-hidden"
ACCEPT_KEYWORDS="sparc"
USE="gtk gnome -arts -jack -qt -kde dvd dvdr alsa cdr audiofile avi bmp bonobo cups Xav3d divx4linux flac flash ftp gmp gnutls gphoto2 gpm gstreamer imagemagick imap java mime ming mmap mng mozilla quicktime sndfile sockets tcltck tiff usb videos wmf xine xml xp xssl xvid"

NPTL was not able to compile. Perhaps now, when I have kernel 2.6.13-gentoo in use, but let's see, if I'm interested enough some
day. What I followed from Gentoo Installation manual? I did stage1 install, and some minor things to check from there.
As I want to my U10 to boot, I didn't compile grub, as it blaims something.

Well - This is now runnig, but erhm- with Gnome this feels little slow. Last time this machine was running was approx. 6 months ago, so time goldens the memories (not sure straight english phrase, this is straight finnish translation).

There were anyway two reasons to start this project at all. 1 I wanted to have gcc3.4.3 (now 3.4.4) and 2 2.6.x kernel for cinelerra.
Now I decided, that let w- do the video stuff and U10 takes care for mails and www-stuff. (I'm curious about cinelerra anyway, so I give a shot for it shortly).

So 64bit support may need some special options to get out from gcc3-branch. By building this system gcc3.4.4 were compliled at least three times.
_________________
/tmp.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on Sparc 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