X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:subject :references:in-reply-to:content-type; q=dns; s=default; b=uZBm4+ ShG4/mKnbFpb9RyNt9m9f9hDuZSrX7YcangCsLfCjfwwFEsSv+ArUNaTZHi37p09 i00f+jfgW04PFwoDkpgO7rGva6KiqzhqIwJGpE+K+ZA2MA8OjCMa+BmbwO7w5w+D uMJU7YxTyRCQ93a573ZKOBNljEL6c+yKCCnwU= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:subject :references:in-reply-to:content-type; s=default; bh=H4d6dE4/cixS 0TYPlfDAY4u1TvY=; b=uxueII3OJ4iq6r5yS5qafy1HNywKY7J6eqN/roipNr6u mV5IqWzu//DzfkL7DYkFhHYA6xV/RHgYVEYkmWgmkjB0tAKnKxQ8iFWF3Gb4798f jZMeYyAy+Jfqb5TfKMfr5ggLAFK5N6V+ia9htKyWDIJMGjNZFTN+ixg0g5cqCJo= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy=giant, Hx-languages-length:1725, H*f:sk:CAD8GWs, H*i:sk:e4aDyQ@ X-HELO: mail-pa0-f67.google.com X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to; bh=YM9Hh6IDNdVFvfsNEvu8j8AXCM21rFbDXu6d1gkg608=; b=UVy9zavgoOkQbwa51fcLtgOGLZy1nDCO+hyslYv2zyFijvoCNWVQpdUdRckQUHokbG NVwch4R5vaRu24+G1p6aQ7LRfZ7cHWJVKEo9h0W87N3kjzKpmVI7I1T9NNLAyEHdlt8Z yz1uQ6XJ0dCkfWtXmenCPyFHoSwVRzLdg1EsmJj9qraD3ld2xf+HH1jQfApY7IKKZNA8 4RIkWI6cXmGLo5m14agofJgUjN3ErjONiUQWIUVHKSnx9TnxcWYXVB/+YHSO3j2CYUNV 4Q3lnlHSaT9aOHCZ87vlS5oDGRCGjulW3jNoXBNV5ZhL/bBj/J7j/hMK8ndzATm3dM4D Ok5g== X-Gm-Message-State: AOPr4FWVkN5RWA77uvrmu0Hooo35990F27OoWHenFIcRzMhenx69j13dXP3vAkk6ceinKg== X-Received: by 10.66.150.163 with SMTP id uj3mr7326188pab.23.1461711997962; Tue, 26 Apr 2016 16:06:37 -0700 (PDT) Message-ID: <571FF46E.6050603@gmail.com> Date: Wed, 27 Apr 2016 07:06:22 +0800 From: JonY <10walls AT gmail DOT com> User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:25.4) Gecko/20150524 FossaMail/25.1.5 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: converting from -mno-cygwin References: In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Ukxfom2bQWqlAs9QBSIQbOAbGtoqgFX06" X-IsSubscribed: yes --Ukxfom2bQWqlAs9QBSIQbOAbGtoqgFX06 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 4/27/2016 05:08, Lee wrote: > Questions: >=20 > How to tell if I should be using libwinpthread or pthread? I had no > idea so installed both: > /usr/i686-w64-mingw32/sys-root/mingw/bin > $ ls -l *hread* > -rwxr-xr-x 1 root None 47635 Apr 7 08:54 libwinpthread-1.dll > -rwxr-xr-x 1 root None 65024 Jul 6 2013 pthreadGC2.dll >=20 >=20 pthreadGC2 is a compatibility left over. > If I should be using the pthread library, what's the correct library > name to give GCC - ie. in the make file, > PTHREAD_LIB =3D ??what?? >=20 >=20 Just use -lpthread like everyone on *nix does. > Is there a way to get the libraries included as part of the > executable? I'd rather not have to include libwinpthread-1.dll & > zlib1.dll in the distribution package. >=20 >=20 -static? ymmv. > Is there a standard way to figure out if the compiler is gcc-v3 with > the -mno-cygwin flag set? No, don't do this, it'd turn into a giant hairball fast. > I had to make a few changes to the code to get this far & I'd prefer > to have the changes wrapped inside an #IFDEF or something. For > example, I just commented out the include since it conflicts with > something >=20 > #ifdef __MINGW32__ > /* -LR- #include "cygwin.h" */ > /* -LR- const char cygwin_h_rcs[] =3D CYGWIN_H_VERSION; */ > #endif >=20 > Under cygwin 1.5, gcc -mno-cygwin requires cygwin.h to be included. > Using i686-w64-mingw32-gcc if cygwin.h is inculded gcc barfs with a > conflicting definition of [i don't remember]. > It'd be nice if I could build using the old or new method without > having to change the source code, so I'm guessing I want some kind of > ifdef wrapper for the include?? >=20 What are you even trying to do? You shouldn't mix different runtimes. --Ukxfom2bQWqlAs9QBSIQbOAbGtoqgFX06 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQIcBAEBAgAGBQJXH/R5AAoJEHE7X+KcFF1FrG8P/3dZThhv8PAgVKemlqPE2K41 G6hIJu84yqrcjwlEp+nyK09TXwAjnaDcTJppUb/YKqXFZeSUV36HFKpW7G99s9G0 Y8WsyFThPsVi3MPUlvXeu7d1HEnb5JvwyMQJtU2DZUpcU4A9uRLhgGmKTyyKzgZF qfVb/Sl3omLtAJSPkkxVJlVdpg9M5atPgKRE5FT6/6AcRWkiY7m2ZQfNLBKhcCKw noequWh6QFCo3tuPi5+CFf+FV0C4VP9+U8OuCvAjyJEA+HWCn1ZZNTOf38dMYfKW qUDXiVfhQw/NXarC8VwrkyYPt8DZIsiUTUQRlu6D0b0EoJiQjsC2/9R6xWTdHmGv 4U54/x6frx2JtWZJQUbB+pBTN9wXhSh3NVGj7LLAs1ArzFQ7IXY21shj4KmUmob0 x8uLNCiS+hXuIFRBf5iiAkeqedB/XpbA1ITm8q9sP/WWs4N/KftrXxk9DHY3kYOx 9RQozgssagz8uo3oAih/2l4CULSFsmMxenqvAkT9KhW8NT7492NFLzWMcwCb05Pf W5/bfzNdFj4mKQEPsCYtOY22yV2QpC4IFrmXsYabTAjHwLzm5zG62EEICPRdbjaD 3pfPUhy3WplBOHYsk93MsSHXuyrKlcCCgwUS8nKrJbU7JZ0Vgry8l0yZf3tCiT+t /h+GfL5lsL2fE5nU7lnj =9NSm -----END PGP SIGNATURE----- --Ukxfom2bQWqlAs9QBSIQbOAbGtoqgFX06--