Hi On Fri, Jul 29, 2011 at 9:47 AM, Ian Lance Taylor <iant@xxxxxxxxxx> wrote: > esmaeil mirzaee <esmaeil.debian@xxxxxxxxx> writes: > >> apologize in advanced I hope this place is right for this question. >> I try to install gcc-3.4.6 in ubuntu 10.10 but I've got below error >> >> In function ‘open’, >> inlined from ‘collect_execute’ at ./collect2.c:1537:20: >> /usr/include/bits/fcntl2.h:51:24: error: call to ‘__open_missing_mode’ >> declared with attribute error: open with O_CREAT in second argument >> needs 3 arguments >> make[1]: *** [collect2.o] Error 1 >> make[1]: Leaving directory `/home/esmaeil/Documents/software/gcc-3.4.6/gcc' >> make: *** [all-gcc] Error 2 >> >> I did >> ./configure >> make >> >> and the error is appear after several minutes. > > It's a bug in gcc 3.4.6 (you do know that that is a very old release, > right?). > > You can fix it by changing line 1537 of gcc/collect2.c to this: > redir_handle = open (redir, O_WRONLY | O_TRUNC | O_CREAT, 0666); Thank you for your help I did your suggestion and It was the helpful > > Ian but I've got another error /home/esmaeil/Documents/software/gcc-3.4.6/gcc/xgcc -B/home/esmaeil/Documents/software/gcc-3.4.6/gcc/ -B/usr/local/i686-pc-linux-gnu/bin/ -B/usr/local/i686-pc-linux-gnu/lib/ -isystem /usr/local/i686-pc-linux-gnu/include -isystem /usr/local/i686-pc-linux-gnu/sys-include -O2 -DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -I. -I. -I. -I./. -I./../include -g0 -finhibit-size-directive -fno-inline-functions -fno-exceptions -fno-zero-initialized-in-bss -fno-unit-at-a-time -fno-omit-frame-pointer \ -c ./crtstuff.c -DCRT_BEGIN \ -o crtbegin.o In file included from /usr/include/bits/errno.h:25, from /usr/include/errno.h:36, from ./tsystem.h:85, from ./crtstuff.c:62: /usr/include/linux/errno.h:4:23: asm/errno.h: No such file or directory make[1]: *** [crtbegin.o] Error 1 make[1]: Leaving directory `/home/esmaeil/Documents/software/gcc-3.4.6/gcc' make: *** [all-gcc] Error 2 Best Samuel