www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/09/27/21:16:43

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT sourceware DOT cygnus DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
Message-Id: <199909280115.UAA01906@mercury.xraylith.wisc.edu>
To: "Emmanuel STAPF" <manus AT eiffel DOT com>
cc: "Cygwin AT Sourceware. Cygnus. Com" <cygwin AT sourceware DOT cygnus DOT com>
Subject: Re: How to make a Windows program using threads?
In-Reply-To: Your message of "Mon, 27 Sep 1999 15:01:10 PDT."
<NBBBLJDKHPIDCALEEHBCCEBODCAA DOT manus AT eiffel DOT com>
Date: Mon, 27 Sep 1999 20:15:54 -0500
From: Mumit Khan <khan AT thor DOT xraylith DOT wisc DOT edu>

"Emmanuel STAPF" <manus AT eiffel DOT com> writes:
> Thanks for the answer, but my question was more related to how to compile
> it. For example on Windows using MSVC++ you need to compile with the -MD
> or -MT flag. Do you need to do the same with gcc on windows. I should
> mention that I'm using the `-mnocygwin' option in order to link against
                              ^^^^^^^^^^ (you mean -mno-cygwin of course)
> Microsoft Runtime.


Mingw32 port uses only the multithreaded runtime (either CRTDLL or MSVCRT),
so -MT and -MD is implicit (ie., -MD -MT is on by default).

Currently, the C++ runtime is not thread-safe, but I'm planning to release
a runtime update soon that will fix that problem.

Currently, for both Cygwin and Mingw, you need to add -mwindows when 
linking, which provides a few extra libraries and also changes the entry 
point for Mingw32. 
  
  $ gcc -mno-cygwin -o foo.exe foo.c -v -mwindows 

to see what happens.

Regards,
Mumit



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019