public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* PATCH to support native Windows builds
@ 2004-06-11 22:31 Mark Mitchell
  2004-06-11 22:57 ` DJ Delorie
                   ` (3 more replies)
  0 siblings, 4 replies; 21+ messages in thread
From: Mark Mitchell @ 2004-06-11 22:31 UTC (permalink / raw)
  To: gcc-patches; +Cc: dj


This patch provides support for building GCC on native Windows (i.e.,
MinGW) as opposed to Cygwin.  

This patch has been in CodeSourcery's local trees for a long time, and
is on the csl-arm-branch.

The version attached here isn't quite ready for inclusion in GCC,
because (for example) there is no ChangeLog and some functions are
missing comments.  However, my understanding is that the last time
something like this patch was suggested, it was rejected by DJ, so,
before doing the clean-ups, I think we need to get agreement on the
general direction.

The basic change in this code is that some code in collect2.c is
abstracted out and placed in libiberty.  In particular, collect2.c
right now does the usual UNIX pipe/fork/dup2/exec sequence.  This, of
course, does not work on UNIX.  After the patch, libiberty provides
low-level "pmkpipe" and "pexec" functions which encapsulate this logic
for UNIX, and which can also be implemented for Windows.  The existing
high-level "pexecute" functions are still in libiberty; the patch is
intended not to remove or modifying existing libiberty interfaces.

My understanding is that DJ objected to this patch because DOS does
not have pipes.  Of course, this patch would not make the situation
any worse that it already is for DOS, since the code in collect2.c
already cannot be used on DOS.  The objection, I think, was that any
change to this stuff should be in some other direction that would work
better for DOS.  Zack Weinberg and Ian Lance Taylor spent some time
coming up with ideas in that direction, but it doesn't look like
anything definitive happened, and it's not clear that anyone is
motivated enough to spend the time to implement anything else.

My thinking is the following:

1. Windows is a very popular host system, and this patch would allow
   GCC to be built there more easily.

2. Existing DOS functionality would not be adversely affected.

3. There doesn't seem to be any major movement to implement a more
   DOS-compatible interface, so we're sitting on a good improvement in
   the hope that someone will someday present us with an even better
   one.

4. If someone comes up with a better way of doing this stuff that
   works better for DOS, we can always add that in later.

DJ, do you still object to this patch?  If so, would you please
articulate your reasons?

Thanks,

--
Mark Mitchell
CodeSourcery, LLC
mark@codesourcery.com

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

end of thread, other threads:[~2004-06-12  9:50 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-06-11 22:31 PATCH to support native Windows builds Mark Mitchell
2004-06-11 22:57 ` DJ Delorie
2004-06-11 23:21   ` Mark Mitchell
2004-06-12  0:28     ` DJ Delorie
2004-06-11 23:50 ` Aaron W. LaFramboise
2004-06-11 23:56   ` Zack Weinberg
2004-06-12  0:01   ` Mark Mitchell
2004-06-11 23:54 ` Paolo Carlini
2004-06-12  0:10   ` Mark Mitchell
2004-06-12  0:53 ` Danny Smith
2004-06-12  1:08   ` Mark Mitchell
2004-06-12  2:40     ` DJ Delorie
2004-06-12  2:48       ` Mark Mitchell
2004-06-12  3:59         ` Ian Lance Taylor
2004-06-12  4:23           ` Zack Weinberg
2004-06-12  5:57             ` Mark Mitchell
2004-06-12  7:06               ` Ian Lance Taylor
2004-06-12  8:12                 ` Mark Mitchell
2004-06-12  6:02             ` Ian Lance Taylor
2004-06-12  8:14               ` Zack Weinberg
2004-06-12 13:42     ` Danny Smith

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).