config-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Support for MinGW compilers in the Cygwin environment


From: Daniel Richard G.
Subject: Support for MinGW compilers in the Cygwin environment
Date: Sun, 20 Oct 2013 21:50:23 -0400

Hello,

Among the many packages Cygwin provides are MinGW builds of GCC and the
associated libraries and tools, making this a convenient alternative to
MSYS and the packages provided directly by the MinGW project.

When one is using the MinGW compiler in this environment, however,
config.guess still identifies the system as *-*-cygwin, instead of the
more appropriate *-*-mingw* which will typically enable Windows-specific
build settings (such as linking against -lws2_32 for networking
functions).

The attached patch (against git master) consolidates the three separate
Cygwin cases in the big case statement, and adds a compiler check. The
output is changed only if the MinGW compiler is in use; otherwise,
*-*-cygwin is returned as before.

Two open questions remain on my part, however:

* I have the 32/64-bit mode of the compiler affect the OS part of the
  triplet ("mingw32" versus "mingw64"); should it also affect the CPU?
  (Is it sensible to return e.g. i686-pc-mingw64 or
  x86_64-unknown-mingw32?)

* The vendor part of the triplet is "pc" for iX86 systems, and "unknown"
  for x86_64; this seems arbitrary. Is there a good reason not to return
  "pc" consistently for 32- and 64-bit x86?


--Daniel


P.S.: Please Cc: any replies to me, as I am not subscribed to this list.


-- 
Daniel Richard G. || address@hidden
My ASCII-art .sig got a bad case of Times New Roman.

Attachment: config-cygwin-mingw.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]