Thanks for that light in my way, this is the full output of the command that you suggested: # echo 'int main(void) { return 0; }' | gcc -v -x c - && ./a.out && echo Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/lto-wrapper Target: i386-pc-solaris2.11 Configured with: /builds/hudson/workspace/nightly-update/build/i386/components/gcc45/gcc-4.5.2/configure CC=/ws/on11update-tools/SUNWspro/sunstudio12.1/bin/cc CXX=/ws/on11update-tools/SUNWspro/sunstudio12.1/bin/CC --prefix=/usr/gcc/4.5 --mandir=/usr/gcc/4.5/share/man --bindir=/usr/gcc/4.5/bin --libdir=/usr/gcc/4.5/lib --sbindir=/usr/gcc/4.5/sbin --infodir=/usr/gcc/4.5/share/info --libexecdir=/usr/gcc/4.5/lib --enable-languages=c,c++,fortran,objc --enable-shared --with-gmp-include=/usr/include/gmp --with-mpfr-include=/usr/include/mpfr --without-gnu-ld --with-ld=/usr/bin/ld --with-gnu-as --with-as=/usr/gnu/bin/as CFLAGS='-g -O2 ' Thread model: posix gcc version 4.5.2 (GCC) COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=pentium4' /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/cc1 -quiet -v - -quiet -dumpbase - -mtune=generic -march=pentium4 -auxbase - -version -o /var/tmp//cc5Ya4EF.s GNU C (GCC) version 4.5.2 (i386-pc-solaris2.11) compiled by GNU C version 4.5.2, GMP version 4.3.2, MPFR version 2.4.2, MPC version 0.9 GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 ignoring nonexistent directory "/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/../../../../i386-pc-solaris2.11/include" #include "..." search starts here: #include <...> search starts here: /usr/local/include /usr/gcc/4.5/include /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/include /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/include-fixed /usr/include End of search list. GNU C (GCC) version 4.5.2 (i386-pc-solaris2.11) compiled by GNU C version 4.5.2, GMP version 4.3.2, MPFR version 2.4.2, MPC version 0.9 GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 Compiler executable checksum: c173f5ac4c32f3a4622622287aece5a4 COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=pentium4' /usr/gnu/bin/as -v -V -Qy -s -o /var/tmp//cc6Ya4EF.o /var/tmp//cc5Ya4EF.s GNU assembler version 2.23.1 (i386-pc-solaris2.11) using BFD version (GNU Binutils) 2.23.1 COMPILER_PATH=/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/:/usr/ccs/bin/ LIBRARY_PATH=/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/../../../:/lib/:/usr/lib/ COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=pentium4' /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/collect2 -V -Y P,/lib:/usr/lib -Qy /usr/lib/crt1.o /usr/lib/crti.o /usr/lib/values-Xa.o /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/crtbegin.o -L/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2 -L/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/../../.. /var/tmp//cc6Ya4EF.o -lgcc -lgcc_eh -lc -lgcc -lgcc_eh /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/crtend.o /usr/lib/crtn.o ld: Software Generation Utilities - Solaris Link Editors: 5.11-1.2458 ld: fatal: bad section layout: .SUNW_ldynsym must precede and be adjacent to .dynsym collect2: ld returned 1 exit status I am probably in the wrong way, but as I read somewhere else that this error outputs can be caused by the linker, I find out a way to "test" with the gnu linker instead of the solaris one: #/usr/bin/mv /usr/bin/ld /usr/bin/ld.old ; /usr/bin/cp /usr/bin/gld /usr/bin/ld With this output: # echo 'int main(void) { return 0; }' | gcc -v -x c - && ./a.out && echo Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/lto-wrapper Target: i386-pc-solaris2.11 Configured with: /builds/hudson/workspace/nightly-update/build/i386/components/gcc45/gcc-4.5.2/configure CC=/ws/on11update-tools/SUNWspro/sunstudio12.1/bin/cc CXX=/ws/on11update-tools/SUNWspro/sunstudio12.1/bin/CC --prefix=/usr/gcc/4.5 --mandir=/usr/gcc/4.5/share/man --bindir=/usr/gcc/4.5/bin --libdir=/usr/gcc/4.5/lib --sbindir=/usr/gcc/4.5/sbin --infodir=/usr/gcc/4.5/share/info --libexecdir=/usr/gcc/4.5/lib --enable-languages=c,c++,fortran,objc --enable-shared --with-gmp-include=/usr/include/gmp --with-mpfr-include=/usr/include/mpfr --without-gnu-ld --with-ld=/usr/bin/ld --with-gnu-as --with-as=/usr/gnu/bin/as CFLAGS='-g -O2 ' Thread model: posix gcc version 4.5.2 (GCC) COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=pentium4' /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/cc1 -quiet -v - -quiet -dumpbase - -mtune=generic -march=pentium4 -auxbase - -version -o /var/tmp//ccDGaGiG.s GNU C (GCC) version 4.5.2 (i386-pc-solaris2.11) compiled by GNU C version 4.5.2, GMP version 4.3.2, MPFR version 2.4.2, MPC version 0.9 GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 ignoring nonexistent directory "/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/../../../../i386-pc-solaris2.11/include" #include "..." search starts here: #include <...> search starts here: /usr/local/include /usr/gcc/4.5/include /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/include /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/include-fixed /usr/include End of search list. GNU C (GCC) version 4.5.2 (i386-pc-solaris2.11) compiled by GNU C version 4.5.2, GMP version 4.3.2, MPFR version 2.4.2, MPC version 0.9 GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 Compiler executable checksum: c173f5ac4c32f3a4622622287aece5a4 COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=pentium4' /usr/gnu/bin/as -v -V -Qy -s -o /var/tmp//ccEGaGiG.o /var/tmp//ccDGaGiG.s GNU assembler version 2.23.1 (i386-pc-solaris2.11) using BFD version (GNU Binutils) 2.23.1 COMPILER_PATH=/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/:/usr/ccs/bin/ LIBRARY_PATH=/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/:/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/../../../:/lib/:/usr/lib/ COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=pentium4' /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/collect2 -V -Y P,/lib:/usr/lib -Qy /usr/lib/crt1.o /usr/lib/crti.o /usr/lib/values-Xa.o /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/crtbegin.o -L/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2 -L/usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/../../.. /var/tmp//ccEGaGiG.o -lgcc -lgcc_eh -lc -lgcc -lgcc_eh /usr/gcc/4.5/lib/gcc/i386-pc-solaris2.11/4.5.2/crtend.o /usr/lib/crtn.o GNU ld (GNU Binutils) 2.23.1 Supported emulations: elf_i386_sol2 elf_i386_ldso elf_i386 elf_x86_64_sol2 elf_x86_64 elf_l1om elf_k1om Note: I am trying to install the solaris developer studio 12.6 but not success yet, all I have is the default compiler from the repository. -- Sent from: http://gcc.1065356.n8.nabble.com/gcc-Help-f629689.html