From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1643) id 79F993858C98; Thu, 4 Apr 2024 14:04:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 79F993858C98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1712239484; bh=XowAaC5u4sa/LWCexhTQWAVYOKX8d4wZsr2FDN+0wpE=; h=From:To:Subject:Date:From; b=JwTctfFwl3WzSgrQI3/gVrGeYCi3ryIp9rF6AWKJlcvlexyo933ntVCsQ3fqSNGB8 RifierTV+mMtQMCPMSRhp2bjDIhTc2uxMeTlYossezJM1KtBLkzeoRl3MwGGBhvYrE P+2vD/WYmVsK+sFyyJTCxFmuPc6ajaCMwUiGB02g= Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Thomas Schwinge To: newlib-cvs@sourceware.org Subject: [newlib-cygwin/main] amdgcn: Implement proper locks: Fix 'newlib/libc/sys/amdgcn/include/sys/lock.h' for C++ X-Act-Checkin: newlib-cygwin X-Git-Author: Thomas Schwinge X-Git-Refname: refs/heads/main X-Git-Oldrev: db454e9868c09fe3bab434d55a50ea7797b01f2c X-Git-Newrev: ed50a50b9b551ed693d28cd458a49e5196d27f06 Message-Id: <20240404140444.79F993858C98@sourceware.org> Date: Thu, 4 Apr 2024 14:04:44 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=3Dnewlib-cygwin.git;h=3Ded50a50b9b5= 51ed693d28cd458a49e5196d27f06 commit ed50a50b9b551ed693d28cd458a49e5196d27f06 Author: Thomas Schwinge Date: Thu Apr 4 16:01:35 2024 +0200 amdgcn: Implement proper locks: Fix 'newlib/libc/sys/amdgcn/include/sys= /lock.h' for C++ =20 As of commit 7dd4eb1db9e1b1b9f14ef5b743705156e5f370e1 "amdgcn: Implement proper locks", we get, by the thousands, for C++ cod= e: =20 In file included from [...]/newlib/libc/include/stdio.h:60, from [...]: [...]/newlib/libc/include/sys/reent.h:911:1: error: expected declar= ation before '}' token Diff: --- newlib/libc/sys/amdgcn/include/sys/lock.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/newlib/libc/sys/amdgcn/include/sys/lock.h b/newlib/libc/sys/am= dgcn/include/sys/lock.h index 0e0e667e5..1f41cf2f7 100644 --- a/newlib/libc/sys/amdgcn/include/sys/lock.h +++ b/newlib/libc/sys/amdgcn/include/sys/lock.h @@ -4,6 +4,10 @@ #include #include <_ansi.h> =20 +#ifdef __cplusplus +extern "C" { +#endif + typedef unsigned int _LOCK_T; typedef unsigned int _LOCK_RECURSIVE_T;