This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more infromation.


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

RE: Building a Cross Compiler On Windows


I had difficulties building arm-elf tools on my Win2k system running Cygwin
1.1.0, so I wrote a Perl script to drive the configure/build procedure. It's
not bullet proof but it got me past some strange problems where I couldn't
build info files  for gcc (which I didn't care about anyway). When
configuring gcc I just created empty .info files to prevent the attempt at
building the texinfo files.

The script assumes that it is in its own directory and all the source
directories for gcc, binutils, gdb, newlib, etc. are at the same level (e.g.
to reference gcc from the directory containing mk, use ../gcc-2.95.2).

Anyway, I've attached the Perl script (named 'mk') which takes a string
argument which can be one of the strings 'configure', 'build', or 'all'
(which does both configure and build). It should be relatively easy to
modify it for a different target.

Hope someone finds it useful.

Clark

P.S. Christopher, like you I got my Cygwin 1.0 CD by ordering, but was able
to upgrade over the net.


-----Original Message-----
From: crossgcc-owner@sources.redhat.com
[mailto:crossgcc-owner@sources.redhat.com]On Behalf Of Christopher Bahns
Sent: Friday, July 07, 2000 4:47 PM
To: crossgcc@sourceware.cygnus.com
Subject: Re: Building a Cross Compiler On Windows


I don't know about your particular problem, but I wrote up my own document /
procedure / bash script (attached) for building a cross-compiler under
Windows 98
or NT using Cygwin. In my case I have a Motorola 68EC000 (MC68306) target,
but I
tried to set the script up to make it easy to change it for any target (just
follow the directions).

It basically starts from scratch and tells you where to get stuff. I'd
recommend
getting binutils-2.10 and ignore the part about the patch in
"gcc-m68k-essentials-r6". I have not tried this yet, but I assume that you
don't
need the patch for 2.9.1 when you move to 2.10. If you follow the directions
exactly as shown then it should work, since this has worked for me, under
both NT
4.0 Workstation and 98SE (it did not work under NT 4.0 Server).

HTH even though it does not really answer your questions (you don't need
glibc if
you're using newlib, right?).

p.s. Did you say you downloaded Cygwin 1.1.0 directly from Cygnus/Red Hat
over the
internet? I thought you could only get Cygwin B20.1 for free that way. I had
to
pay $79 to order Cygwin 1.0 on a CD and have it mailed to me.

Chris

henkel@us.ibm.com wrote:

> Hello,
>
> What I eventually want to do is have a gcc cross compiler for Power PC
code
> from a PC envirionment.
>
> I have dowloaded and ran the setup.exe from
> http://sourceware.cygnus.com/cygwin/ and now have Cygwin1.1.0 installed on
> my NT system.  I created a hello.C program compiled it using gcc and ran
> the a.exe program.  Works fine. I now have gcc for NT on my box.
>
> I've figured out that I now want to download the source for binutils, gcc,
> glibc or newlibc, and gdb and compile them under the Cygwin environment
> using the gcc compiler. To keep things simple, I decided to use the
example
> from http://www.objsw.com/CrossGCC/FAQ-4.html#ss4.1 and follow it word for
> word.  So I'm building a Sun Solaris cross compiler for now just to get
the
> hang of things.
>
> My env vars are:
> host=sparc-sun-solaris2
> target=m68k-coff
> prefix=/bar
> i=$prefix/bin
>
> I ran the configure tool for binutils, ran "make all install" and it looks
> like the binutils built just fine.  At least I see a cygwin/bar directory
> with /bin /include, & /lib where not there before I ran the make.
>
> I then ran the configure tool for gcc, then "make all install". It looks
> like this created /cygwin/m68k-coff  with a bin and lib directory.  I was
> expecting to see gcc.exe in the /bin directory but I don't. It doesn't
look
> like it exists under my /bar directory anywhere.  What's going on here? Is
> this expected?
>
> Also, could someone tell me where I can download the source for glibc?
> I've not been able to find it. I found the other three but not the glibc,

> I'm sure it's staring me in the face but the stars are in my eyes.
>
> Thanks much.
>
> Dean
>
> ------
> Want more information?  See the CrossGCC FAQ,
http://www.objsw.com/CrossGCC/
> Want to unsubscribe? Send a note to
crossgcc-unsubscribe@sourceware.cygnus.com


------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com


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