gcc 4.2.0 from SUN binary gccfss


 
Thread Tools Search this Thread
Operating Systems Solaris gcc 4.2.0 from SUN binary gccfss
# 1  
Old 09-02-2008
gcc 4.2.0 from SUN binary gccfss

Hi All

I have installed the above version of gcc from the SUN binaries and recieved the following linker error when trying to compile and link a hello world test program written in C++.

ld: fatal: option -z has illegal argument `ld32=-S/export/home/sources/gcc_SUN_b
inary/SUNW0scgfss/4.2.0/prod/lib/libld_annotate.so'
ld: fatal: option -z has illegal argument `ld64=-S/export/home/sources/gcc_SUN_b
inary/SUNW0scgfss/4.2.0/prod/lib/v9/libld_annotate.so'

Breaking the process down I can compile without errors. But linking generates errors.
Using the SUN linker I see

ld: fatal: file file_type_c.o: section .rela.annotate: relocations can not be
applied against section `.annotate'

and with the GNU liner from binutils 2.18 I see

/usr/local/bin/ld: warning: cannot find entry symbol _start; defaulting to 0000000000010054
file_type_c.o: In function `main':
file_type_c.cSmilie.text+0x8): undefined reference to `puts'

Can anyone give me some pointers as to the origins of the above errors.

Thanks
Ed
# 2  
Old 09-02-2008
What happens if you add the following linker option "-xannotate=no" ?
# 3  
Old 09-05-2008
Thanks for the advice.
Finally got this to work using the following flags.
-m32 -pthreads -xannotate=no
Could you advise on the nature of the -xannotate flag or better still I suppose point me in the direction of a documentation source.
Login or Register to Ask a Question

Previous Thread | Next Thread

6 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Convert binary file to csv and then back to the binary format

Hello *nix specialists, Im working for a non profit organisation in Germany to transport DSL over WLAN to people in areas without no DSL. We are using Linksys WRT 54 router with DD-WRT firmware There are at the moment over 180 router running but we have to change some settings next time. So my... (7 Replies)
Discussion started by: digidax
7 Replies

2. Solaris

Need gcc binary for a SPARC machine

The machine I am trying to compile on does have /usr/sfw/bin and all the files in it, EXCEPT gcc !! This is a SUN Sparc-1 machine, so the binary does matter to match this. Can someone send me a gcc so I can put it locally for compilation purposes? Or point me a a site that has a compiled-ready... (17 Replies)
Discussion started by: steve701
17 Replies

3. Solaris

Installing gcc - recieve error message gcc : cannot execute

AIM- Install Oracle 11g on Solaris using VMWare Steps 1.Logged on as root 2.Created subfolders à /usr/local/bin & /usr/local/bin/gcc 3.Downloaded gcc & libiconv & unzipped them on my harddrive & burnt them on CD 4.Copied files from CD to /usr/local/bin/gcc 5.Terminal (root) à pkgadd -d... (8 Replies)
Discussion started by: Ackers
8 Replies

4. UNIX for Dummies Questions & Answers

Sun Solaris 10: How do I create a bootup disc? The Sun website confuses me

Hey there, I am starting a Computer Science Foundation year at the end of this month and am trying to get a little bit ahead of the game. I have always wanted to learn Unix and am currently struggling with creating a boot disc to run Solaris (I have chosen to study this) from as opposed to... (0 Replies)
Discussion started by: Jupiter
0 Replies

5. UNIX for Advanced & Expert Users

Help: Sun Disk partitioning for Sun V240 & StorEdge 3300

Dear Sun gurus, I have Sun Fire V240 server with its StorEdge 3300 disk-array. Following are its disks appeared in format command. I have prepared its partitions thru format and metainit & metattach (may be i have made wrong steps, causing the errors below because I have done thru some document... (1 Reply)
Discussion started by: shafeeq
1 Replies

6. Solaris

compiled binary file gives "cannot execute binary file"

Hi, I have two Solaris machines. 1. SunOS X 5.8 Generic_108528-29 sun4u sparc SUNW,Sun-Blade-1500 2. SunOS Y 5.8 Generic_108528-13 sun4u sparc SUNW,Ultra-60 I am trying to buiild a project on both these machines. The Binary output file compiled on machine 2 runs on both the machines. Where... (0 Replies)
Discussion started by: scgupta
0 Replies
Login or Register to Ask a Question