From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gnu.wildebeest.org (gnu.wildebeest.org [45.83.234.184]) by sourceware.org (Postfix) with ESMTPS id 8BE703858C00 for ; Thu, 23 Feb 2023 12:35:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8BE703858C00 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=klomp.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=klomp.org Received: from r6.localdomain (82-217-174-174.cable.dynamic.v4.ziggo.nl [82.217.174.174]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by gnu.wildebeest.org (Postfix) with ESMTPSA id A915C30067D6; Thu, 23 Feb 2023 13:35:48 +0100 (CET) Received: by r6.localdomain (Postfix, from userid 1000) id 7471634025A; Thu, 23 Feb 2023 13:35:48 +0100 (CET) Message-ID: Subject: Re: [PATCH v2 10/16] libasm: stdio_ext.h are not present on win32 From: Mark Wielaard To: Yonggang Luo , elfutils-devel@sourceware.org Date: Thu, 23 Feb 2023 13:35:48 +0100 In-Reply-To: <20221217165213.152-11-luoyonggang@gmail.com> References: <20221217165213.152-1-luoyonggang@gmail.com> <20221217165213.152-11-luoyonggang@gmail.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.46.4 (3.46.4-1.fc37) MIME-Version: 1.0 X-Spam-Status: No, score=-3035.6 required=5.0 tests=BAYES_00,GIT_PATCH_0,JMQ_SPF_NEUTRAL,KAM_DMARC_STATUS,KAM_NUMSUBJECT,RCVD_IN_BARRACUDACENTRAL,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hi, On Sun, 2022-12-18 at 00:52 +0800, Yonggang Luo via Elfutils-devel wrote: > Signed-off-by: Yonggang Luo > --- > libasm/asm_begin.c | 7 ++++++- > 1 file changed, 6 insertions(+), 1 deletion(-) >=20 > diff --git a/libasm/asm_begin.c b/libasm/asm_begin.c > index 9e4dfe43..9b6d974e 100644 > --- a/libasm/asm_begin.c > +++ b/libasm/asm_begin.c > @@ -34,10 +34,13 @@ > #include > #include > #include > -#include > #include > #include > =20 > +#if !defined(_WIN32) > +#include > +#endif > + Can we have a configure check instead? > #include > #include "libasmP.h" > =20 > @@ -56,8 +59,10 @@ prepare_text_output (AsmCtx_t *result) > free (result); > result =3D NULL; > } > +#if !defined(_WIN32) > else > __fsetlocking (result->out.file, FSETLOCKING_BYCALLER); > +#endif > } > =20 > return result; __fsetlocking is used in a lot of other places. Cheers, Mark