cygwin Cross-GCC to MIPS

Yann E. MORIN yann.morin.1998@anciens.enib.fr
Mon Dec 8 18:16:00 GMT 2008


Vivek and Dave,
All,

On Thursday 04 December 2008 06:13:03 Vivek Kumar Gupta wrote:
> I will also like to work on Cygwin, I have windowXP and cygwin on it.

Glad you both want to bang on crosstool-NG on Cygwin. :-)

> I am very much impressed by crosstool NG, worked done here is really
> excellent. After 10 days of tuning + understanding of gcc,uclibc 0.9.30
> + binutils ... on Ubunto7 m/c and with the ARM Boards yesterday finally
> I gave a new compiler to  development team. Thanks to Yann and team who
> made this nice tool.

Cheers! :-)

> Infact I have already tried for 1-2 days on cygwin. And came to know
> config.sub in most of places is giving errors.

Yep, Cygwin is... special. :-)

> From my prospective my manager says it is not mandatory but give a try.
> And my attitude is never die and try hard. So I will like to try with
> you guys.
[--SNIP--]
> Thanks Yann - With a bit of guidance, maybe I can help
> get this working on cygwin... Not my full-time job either !
> Can you give me skeletal instructions of how to go about
> this, given I am a very experienced developer but not at
> all fluent with GCC nor the tools to build it ? I'm happy to
> give it a shot...

OK... So what's next?

First off, but might sound obvious, base your work off the svn trunk, and use
the latest version of Cygwin. Update your installation and cygwinn1.dll if
you already have Cygwin installed. Once it's done, create an empty directory
and mount it with the "managed" option and work in there (cf.
http://cygwin.com/cygwin-ug-net/using.html#mount-table). If you don't do that,
you'll be badly hurt when two file names only differ in case, which is what
the "managed" option is expected to handle.

Next, install crosstool-NG with --local, and work in your crosstool-NG
source tree:
  ./configure --local && make && make install

Then, use a working sample ( I like ARM ones ;-) ) and run crosstool-NG:
  ./ct-ng "your-sample-here"
  ./ct-ng build

Then, wherever it breaks, fix it. :-)

Most probably, it will break in components' build procedures. You shouldn't
have to hack the scripts too much, except for some ./configure options, and
if you do so, either try to make it generic, or make it dependent on Cygwin,
like in the attached path (resent) for the MPFR build.

Speaking of MPFR, testing does not work under Cygwin.

Then, when you have clean and proper fixes, send in a patch, with a single,
atomic change in it. That is, don't send a patch that fixes both MPFR, gcc
and gdb at once; make that three patches, one for each. And even then, try
to split each patch into smaller sub-patches, for example one against the
gcc core build and one against the final build (unless they are really,
really dependent one on the other).

On the overall, crosstool-NG by itself should be OK. After all, it's only
shell scripts and Makefiles fragments, so no big deal there. The kcopnfig
stuff is already building and working fine (except for i18n). Where it will
most bprobably hurt is the components build procedures.

> PS: Perhaps a dumb question (and I'm also using QEMU at
> this instant), but have you considered Xen instead, which
> should give closer to full-speed - not just for Windows,
> but any other x86 VMs you need to use for testing ?

Nope. Xen requires the host system to be changed, and I don't want that.
I can't afford to change my host sytem for something I am not ready to use
on a daily basis. qemu is working fine, even with an XP guest, but it is
Cygwin that maakessss iiittt sooooo sloooooowwwwwww... ( read that while
pitching down your voice, it gives a really nice sound :-] )

Speak to each other, and keep us informed! :-)

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +0/33 662376056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| --==< ^_^ >==-- `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
`------------------------------^-------^------------------^--------------------'
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ct-ng.trunk-cygwin-mpfr.patch
Type: text/x-diff
Size: 2107 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/crossgcc/attachments/20081208/7418af34/attachment.bin>
-------------- next part --------------
--
For unsubscribe information see http://sourceware.org/lists.html#faq


More information about the crossgcc mailing list