This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Problem with GCC 3.2 Compiler for 64bit mode compilation on solaris8


Hello Mahaboob,

  You are using the 32 bits version of the libraries instead of the 64 bits ones.

  In solaris they should be at /usr/lib/sparcv9 or /usr/lib/64. Have a look also at /usr/local/lib/sparcv9. Use -L option to pass this directories to gcc if you want static link or add this directories to the environment variable LD_LIBRARY_PATH if you want dynamic link (you can check all dependencies of your executable with 'ldd exec_name').


Miguel Angel



Tuesday, August 23, 2005, 3:28:06 PM, usted escribió:

MSS> Hi ,

MSS> My Name is Mahaboob Saida Shaik.

MSS> I am using GCC 3.2 compiler for compiling our code in 64bit mode. I am
MSS> facing the problems with the libraries.

MSS> The problem I got is given below

MSS>  /home/pub/applications/gcc/3.2/bin/gcc -O2 -Wall -Werror -m64   
MSS> -DOSVERSION=5.8  -c toolLogger.c

MSS>         ar -rcs libtoollogger.a toolLogger.o

MSS>         /home/pub/applications/gcc/3.2/bin/c++ -O2 -Wall -Werror -m64
MSS> -DOSVERSION=5.8  -c toolLoggerServer.cc

MSS>         /home/pub/applications/gcc/3.2/bin/c++ -m64 -r -o 
MSS> toolloggerserver toolLoggerServer.o -lsocket -lnsl
MSS> ld: warning: file /usr/lib/libsocket.a(getservent.o): wrong ELF class:
MSS> ELFCLASS32
MSS> ld: warning: file /usr/lib/libnsl.a(inet_ntoa.o): wrong ELF class:
MSS> ELFCLASS32
MSS> ld: fatal: library -lgcc_s_sparcv9: not found
MSS> ld: warning: file /usr/lib/libc.a(atexit.o): wrong ELF class: ELFCLASS32
MSS> ld: fatal: library -lgcc_s_sparcv9: not found
MSS> ld: warning: file /usr/lib/libc.a(atexit.o): wrong ELF class: ELFCLASS32
MSS> ld: fatal: File processing errors. No output written to toolloggerserver
MSS> collect2: ld returned 1 exit status
MSS> *** Error code 1
MSS> clearmake: Error: Build script failed for "toolloggerserver"

MSS> When I try to compile using Forte compiler I was able to compile with
MSS> out any errors.

MSS> I am using sun solaris 8 environment.

MSS> Could you please let me know what could be the problem and how it could
MSS> be resolved.

MSS> Thanks in advance.

MSS> Regards.,
MSS> Mahaboob Saida Shaik

MSS> Notice: The information contained in this e-mail message
MSS> and/or attachments to it may contain confidential or privileged
MSS> information.   If you are not the intended recipient, any
MSS> dissemination, use, review, distribution, printing or copying of
MSS> the information contained in this e-mail message and/or
MSS> attachments to it are strictly prohibited.   If you have received
MSS> this communication in error, please notify us by reply e-mail or
MSS> telephone and immediately and permanently delete the message and
MSS> any attachments.  Thank you


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]