public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* building cross compiler from cygwin windows to linux: crti.o no such file or directory
@ 2003-11-25 10:39 mohanlal jangir
  0 siblings, 0 replies; 6+ messages in thread
From: mohanlal jangir @ 2003-11-25 10:39 UTC (permalink / raw)
  To: cygwin; +Cc: gcc

[Excuse me for sending this mail to both mailing list. I am not very sure,
which mailing list this mail is more suitable]

I am trying to build cross compiler from cygwin window to linux. I did
configured and build binutils as follows:
<source
dir>/binutils-2.14/configure --host=i686-pc-cygwin --target=i686-pc-linux-gn
u --prefix=<tool dir>/host/i686-pc-cygwin  && make

This worked well. Later I tried to compile gcc as follows:
 <source
dir>/gcc-3.3.1-3/configure --host=i686-pc-cygwin --target=i686-pc-linux-gnu 
 --prefix=<tool dir>/host/i686-pc-cygwin --with-newlib --disable-threads

This ended up in following error message:
/usr/local/gnu/tools/host/i686-pc-cygwin/i686-pc-linux-gnu/bin/ld: cannot
open crti.o: No such file or directory
collect2: ld returned 1 exit status
make[2]: *** [libgcc_s.so] Error 1
make[2]: Leaving directory `/usr/local/gnu/obj/gcc-3.3.1-3/gcc'
make[1]: *** [libgcc.a] Error 2
make[1]: Leaving directory `/usr/local/gnu/obj/gcc-3.3.1-3/gcc'
make: *** [all-gcc] Error 2


When I executed "find ./ -name crt?.*" at command prompt, I got following
output:
./src/gcc-3.3.1-3/gcc/config/arm/crti.asm
./src/gcc-3.3.1-3/gcc/config/arm/crtn.asm
./src/gcc-3.3.1-3/gcc/config/fr30/crti.asm
./src/gcc-3.3.1-3/gcc/config/fr30/crtn.asm
./src/gcc-3.3.1-3/gcc/config/h8300/crti.asm
./src/gcc-3.3.1-3/gcc/config/h8300/crtn.asm
./src/gcc-3.3.1-3/gcc/config/ia64/crti.asm
./src/gcc-3.3.1-3/gcc/config/ia64/crtn.asm
./src/gcc-3.3.1-3/gcc/config/ip2k/crt0.S
./src/gcc-3.3.1-3/gcc/config/m68k/crti.s
./src/gcc-3.3.1-3/gcc/config/m68k/crtn.s
./src/gcc-3.3.1-3/gcc/config/mcore/crti.asm
./src/gcc-3.3.1-3/gcc/config/mcore/crtn.asm
./src/gcc-3.3.1-3/gcc/config/mips/crti.asm
./src/gcc-3.3.1-3/gcc/config/mips/crtn.asm
./src/gcc-3.3.1-3/gcc/config/mmix/crti.asm
./src/gcc-3.3.1-3/gcc/config/mmix/crtn.asm
./src/gcc-3.3.1-3/gcc/config/sh/crt1.asm
./src/gcc-3.3.1-3/gcc/config/sh/crti.asm
./src/gcc-3.3.1-3/gcc/config/sh/crtn.asm


Out of these files none belongs to i386 architecture. I am not sure if
corrosponding file is missing from gcc source code or I am making some
mistake in configuration.

Regards
Mohanlal

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: building cross compiler from cygwin windows to linux: crti.o no such file or directory
  2003-11-26 13:50 ` mohanlal jangir
@ 2003-11-29  3:33   ` Jim Wilson
  0 siblings, 0 replies; 6+ messages in thread
From: Jim Wilson @ 2003-11-29  3:33 UTC (permalink / raw)
  To: mohanlal jangir; +Cc: cygwin, gcc

mohanlal jangir wrote:
>I am trying to build cross compiler from cygwin window to linux.

Building a cross to linux is an involved process.  You need to build gcc 
and glibc in parallel, or supply a pre-compiled glibc before building gcc.

I suggest looking at the info available at
	http://www.kegel.com/crosstool
which explains how to build gcc and glibc in parallel.
-- 
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: building cross compiler from cygwin windows to linux: crti.o no such file or directory
  2003-11-25 12:53 qinfeng.zhang
@ 2003-11-26 13:50 ` mohanlal jangir
  2003-11-29  3:33   ` Jim Wilson
  0 siblings, 1 reply; 6+ messages in thread
From: mohanlal jangir @ 2003-11-26 13:50 UTC (permalink / raw)
  To: qinfeng.zhang; +Cc: cygwin, gcc


>
> oh,
> create a link file for libgcc.a to correct directory, maybe in
/usr/local/gnu/lib/gcc-3.3.1-3/gcc/
>

Thanks a lot to Qinfeng Zhang. Things are quite better now. I could build
gcc-core successfully (I did put dummy crti.o and crtn.o as you told). Later
while building glibc, I got undefined refrence to __open and many other
functions. To get rid of these errors, I reconfigured glibc
with --disable-shared (--enable-shared was giving linking problem, as I
explained). I could build glibc also. When I tried to compile my source
using newly built cross compiler, I got following error:

/usr/local/gnu/tools/host/i686-pc-cygwin/bin/../lib/gcc-lib/i686-pc-linux-gn
u/3.3.1/../../../../i686-pc-linux-gnu/bin/ld: cannot open crt1.o: No such
file or directory
collect2: ld returned 1 exit status
make: *** [a.out] Error 1

Compilation is going ok but linking is yet a problem. While building
gcc-core, I did not get any complain about crt1.o ( I got it for crti.o and
crtn.o). I tried to put a dummy crt1.o in the same directory and built glibc
again but problem still persists. Any clues?

Regards
Mohanlal

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: building cross compiler from cygwin windows to linux: crti.o no such file or directory
@ 2003-11-25 12:53 qinfeng.zhang
  2003-11-26 13:50 ` mohanlal jangir
  0 siblings, 1 reply; 6+ messages in thread
From: qinfeng.zhang @ 2003-11-25 12:53 UTC (permalink / raw)
  To: mohanlal jangir; +Cc: cygwin, gcc


oh,
create a link file for libgcc.a to correct directory, maybe in /usr/local/gnu/lib/gcc-3.3.1-3/gcc/

I am not sure which directory, you can try.
Regards              /)/)
                    (-.-)
Qinfeng Zhang

Optical Storage & Digital TV
Philips Research East Asia - Shanghai
38F Tower 1 office building
218 Tian Mu Xi Rd.
Shanghai, P.R.China 200070

Tel: (86-21) 6354 1088 Ext. 5356
Fax: (86-21) 6354 4954
Email: qinfeng.zhang@philips.com


                                                                                                                                                                 
                                                                                                                                                                 
                                                   To:   <qinfeng.zhang@philips.com>                                                                             
                                                   cc:   <cygwin@cygwin.com>                                                                                     
                                                    <gcc@gcc.gnu.org>                                                                                            
                                                   Subject:    Re: building cross compiler from cygwin windows to linux: crti.o no such file or directory        
               "mohanlal jangir"                                                                                                                                 
               <mohanlaljangir@hotmail.            Classification:                                                                                               
               com>                                                                                                                                              
                                                                                                                                                                 
               2003-11-25 18:38                                                                                                                                  
                                                                                                                                                                 
                                                                                                                                                                 




I tried this option. Seems to be work around for current problem, but new
problem is that it can not fine libc. The error message is
/usr/local/gnu/tools/host/i686-pc-cygwin//i686-pc-linux-gnu/bin/ld: cannot
find -lc
collect2: ld returned 1 exit status
make[2]: *** [libgcc_s.so] Error 1

>
> You try to  create a empty crt0.c file.
>
>
> cross-gcc crt0.c -c -o /usr/local/gnu/obj/gcc-3.3.1-3/gcc/crt0.o
>
>
>
> I am trying to build cross compiler from cygwin window to linux. I did
> configured and build binutils as follows:
> <source
>
dir>/binutils-2.14/configure --host=i686-pc-cygwin --target=i686-pc-linux-gn
> u --prefix=<tool dir>/host/i686-pc-cygwin  && make
>
> This worked well. Later I tried to compile gcc as follows:
>  <source
>
dir>/gcc-3.3.1-3/configure --host=i686-pc-cygwin --target=i686-pc-linux-gnu
>  --prefix=<tool dir>/host/i686-pc-cygwin --with-newlib --disable-threads
>
> This ended up in following error message:
> /usr/local/gnu/tools/host/i686-pc-cygwin/i686-pc-linux-gnu/bin/ld: cannot
> open crti.o: No such file or directory
> collect2: ld returned 1 exit status
> make[2]: *** [libgcc_s.so] Error 1
> make[2]: Leaving directory `/usr/local/gnu/obj/gcc-3.3.1-3/gcc'
> make[1]: *** [libgcc.a] Error 2
> make[1]: Leaving directory `/usr/local/gnu/obj/gcc-3.3.1-3/gcc'
> make: *** [all-gcc] Error 2
>






^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: building cross compiler from cygwin windows to linux: crti.o no such file or directory
       [not found] <OF09A12521.1D901333-ON48256DE9.0036FBF1-48256DE9.00375368@diamond.philips.com>
@ 2003-11-25 12:09 ` mohanlal jangir
  0 siblings, 0 replies; 6+ messages in thread
From: mohanlal jangir @ 2003-11-25 12:09 UTC (permalink / raw)
  To: qinfeng.zhang; +Cc: cygwin, gcc

I tried this option. Seems to be work around for current problem, but new
problem is that it can not fine libc. The error message is
/usr/local/gnu/tools/host/i686-pc-cygwin//i686-pc-linux-gnu/bin/ld: cannot
find -lc
collect2: ld returned 1 exit status
make[2]: *** [libgcc_s.so] Error 1

>
> You try to  create a empty crt0.c file.
>
>
> cross-gcc crt0.c -c -o /usr/local/gnu/obj/gcc-3.3.1-3/gcc/crt0.o
>
>
>
> I am trying to build cross compiler from cygwin window to linux. I did
> configured and build binutils as follows:
> <source
>
dir>/binutils-2.14/configure --host=i686-pc-cygwin --target=i686-pc-linux-gn
> u --prefix=<tool dir>/host/i686-pc-cygwin  && make
>
> This worked well. Later I tried to compile gcc as follows:
>  <source
>
dir>/gcc-3.3.1-3/configure --host=i686-pc-cygwin --target=i686-pc-linux-gnu
>  --prefix=<tool dir>/host/i686-pc-cygwin --with-newlib --disable-threads
>
> This ended up in following error message:
> /usr/local/gnu/tools/host/i686-pc-cygwin/i686-pc-linux-gnu/bin/ld: cannot
> open crti.o: No such file or directory
> collect2: ld returned 1 exit status
> make[2]: *** [libgcc_s.so] Error 1
> make[2]: Leaving directory `/usr/local/gnu/obj/gcc-3.3.1-3/gcc'
> make[1]: *** [libgcc.a] Error 2
> make[1]: Leaving directory `/usr/local/gnu/obj/gcc-3.3.1-3/gcc'
> make: *** [all-gcc] Error 2
>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: building cross compiler from cygwin windows to linux: crti.o no such file or directory
@ 2003-11-25 11:11 qinfeng.zhang
  0 siblings, 0 replies; 6+ messages in thread
From: qinfeng.zhang @ 2003-11-25 11:11 UTC (permalink / raw)
  To: gcc


You try to  create a empty crt0.c file.


cross-gcc crt0.c -c -o /usr/local/gnu/obj/gcc-3.3.1-3/gcc/crt0.o


Regards              /)/)
                    (-.-)
Qinfeng Zhang

Optical Storage & Digital TV
Philips Research East Asia - Shanghai
38F Tower 1 office building
218 Tian Mu Xi Rd.
Shanghai, P.R.China 200070

Tel: (86-21) 6354 1088 Ext. 5356
Fax: (86-21) 6354 4954
Email: qinfeng.zhang@philips.com


                                                                                                                                                                 
                                                                                                                                                                 
                                                   To:   <cygwin@cygwin.com>                                                                                     
                                                   cc:   <gcc@gcc.gnu.org>                                                                                       
                                                    (bcc: Qinfeng Zhang/SHA/RESEARCH/PHILIPS)                                                                    
                                                   Subject:    building cross compiler from cygwin windows to linux: crti.o no such file or directory            
               "mohanlal jangir"                                                                                                                                 
               <mohanlaljangir@hotmail.            Classification:                                                                                               
               com>                                                                                                                                              
                                                                                                                                                                 
               Sent by:                                                                                                                                          
               gcc-owner@gcc.gnu.org                                                                                                                             
                                                                                                                                                                 
               2003-11-25 15:02                                                                                                                                  
                                                                                                                                                                 
                                                                                                                                                                 




[Excuse me for sending this mail to both mailing list. I am not very sure,
which mailing list this mail is more suitable]

I am trying to build cross compiler from cygwin window to linux. I did
configured and build binutils as follows:
<source
dir>/binutils-2.14/configure --host=i686-pc-cygwin --target=i686-pc-linux-gn
u --prefix=<tool dir>/host/i686-pc-cygwin  && make

This worked well. Later I tried to compile gcc as follows:
 <source
dir>/gcc-3.3.1-3/configure --host=i686-pc-cygwin --target=i686-pc-linux-gnu
 --prefix=<tool dir>/host/i686-pc-cygwin --with-newlib --disable-threads

This ended up in following error message:
/usr/local/gnu/tools/host/i686-pc-cygwin/i686-pc-linux-gnu/bin/ld: cannot
open crti.o: No such file or directory
collect2: ld returned 1 exit status
make[2]: *** [libgcc_s.so] Error 1
make[2]: Leaving directory `/usr/local/gnu/obj/gcc-3.3.1-3/gcc'
make[1]: *** [libgcc.a] Error 2
make[1]: Leaving directory `/usr/local/gnu/obj/gcc-3.3.1-3/gcc'
make: *** [all-gcc] Error 2


When I executed "find ./ -name crt?.*" at command prompt, I got following
output:
./src/gcc-3.3.1-3/gcc/config/arm/crti.asm
./src/gcc-3.3.1-3/gcc/config/arm/crtn.asm
./src/gcc-3.3.1-3/gcc/config/fr30/crti.asm
./src/gcc-3.3.1-3/gcc/config/fr30/crtn.asm
./src/gcc-3.3.1-3/gcc/config/h8300/crti.asm
./src/gcc-3.3.1-3/gcc/config/h8300/crtn.asm
./src/gcc-3.3.1-3/gcc/config/ia64/crti.asm
./src/gcc-3.3.1-3/gcc/config/ia64/crtn.asm
./src/gcc-3.3.1-3/gcc/config/ip2k/crt0.S
./src/gcc-3.3.1-3/gcc/config/m68k/crti.s
./src/gcc-3.3.1-3/gcc/config/m68k/crtn.s
./src/gcc-3.3.1-3/gcc/config/mcore/crti.asm
./src/gcc-3.3.1-3/gcc/config/mcore/crtn.asm
./src/gcc-3.3.1-3/gcc/config/mips/crti.asm
./src/gcc-3.3.1-3/gcc/config/mips/crtn.asm
./src/gcc-3.3.1-3/gcc/config/mmix/crti.asm
./src/gcc-3.3.1-3/gcc/config/mmix/crtn.asm
./src/gcc-3.3.1-3/gcc/config/sh/crt1.asm
./src/gcc-3.3.1-3/gcc/config/sh/crti.asm
./src/gcc-3.3.1-3/gcc/config/sh/crtn.asm


Out of these files none belongs to i386 architecture. I am not sure if
corrosponding file is missing from gcc source code or I am making some
mistake in configuration.

Regards
Mohanlal





^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2003-11-29  3:04 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-11-25 10:39 building cross compiler from cygwin windows to linux: crti.o no such file or directory mohanlal jangir
2003-11-25 11:11 qinfeng.zhang
     [not found] <OF09A12521.1D901333-ON48256DE9.0036FBF1-48256DE9.00375368@diamond.philips.com>
2003-11-25 12:09 ` mohanlal jangir
2003-11-25 12:53 qinfeng.zhang
2003-11-26 13:50 ` mohanlal jangir
2003-11-29  3:33   ` Jim Wilson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).