From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 130133 invoked by alias); 23 May 2017 19:37:40 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 130114 invoked by uid 89); 23 May 2017 19:37:39 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-11.9 required=5.0 tests=BAYES_00,GIT_PATCH_2,GIT_PATCH_3,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=unavailable version=3.3.2 spammy= X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 23 May 2017 19:37:33 +0000 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id A81A080472; Tue, 23 May 2017 19:37:35 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com A81A080472 Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=dj@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com A81A080472 Received: from greed.delorie.com (ovpn-120-43.rdu2.redhat.com [10.10.120.43]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 760F471C5A; Tue, 23 May 2017 19:37:35 +0000 (UTC) Received: from greed.delorie.com.redhat.com (localhost [127.0.0.1]) by greed.delorie.com (8.14.7/8.14.7) with ESMTP id v4NJbWt6028019; Tue, 23 May 2017 15:37:33 -0400 From: DJ Delorie To: Eli Zaretskii Cc: gcc-patches@gcc.gnu.org, gdb-patches@sourceware.org Subject: Re: MinGW compilation warnings in libiberty's waitpid.c In-Reply-To: <83poezml4x.fsf@gnu.org> (message from Eli Zaretskii on Tue, 23 May 2017 22:24:46 +0300) Date: Tue, 23 May 2017 19:37:00 -0000 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-IsSubscribed: yes X-SW-Source: 2017-05/txt/msg00513.txt.bz2 Eli Zaretskii writes: > Instead of making waitpid an always-failing stub on MinGW, wouldn't it > be better to make it work on MinGW? Like this: That's up to you, if it's target-specific. What about mingw64? > --- libiberty/waitpid.c~0 2016-08-01 18:50:21.000000000 +0300 > +++ libiberty/waitpid.c 2017-05-23 21:19:34.302415000 +0300 > @@ -23,6 +23,11 @@ does the return value. The third argume > #include > #endif > > +#ifdef __MINGW32__ > +#include > +#define wait(s) _cwait(s,pid,_WAIT_CHILD) > +#endif > + > pid_t > waitpid (pid_t pid, int *stat_loc, int options ATTRIBUTE_UNUSED) > {