From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2119) id E0B1E3858D28; Sun, 17 Dec 2023 04:11:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E0B1E3858D28 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1702786307; bh=znPpE1LNUHPPeiGa1ZPi/IvTOzt3GdkibA6nzuLPs7k=; h=From:To:Subject:Date:From; b=YkwhtwlDAt/kN/lo4m/kNZFrNyuylRIMGjMKyA+6ddn7tAwkORS4VeBOm9IZhQNLF Kyk/sxl2n0Dq3Oyq19CDbfcIzj1lhSAQiPIgmWPBRATt7PEA26TD+pBBt3KPmU3Z4F lWGjjggLsZbYtc2uGAuOEbWk5FZE2fIHodrSdDMQ= Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Jeff Law To: newlib-cvs@sourceware.org Subject: [newlib-cygwin] Re: Fix moxie libgloss issues with c99 X-Act-Checkin: newlib-cygwin X-Git-Author: Jeff Law X-Git-Refname: refs/heads/master X-Git-Oldrev: 17a6aff334a20f63cb7f428a36dad0c8ebbdab5d X-Git-Newrev: 57e311e0deb23492edc94518c78cc57a224dbad9 Message-Id: <20231217041147.E0B1E3858D28@sourceware.org> Date: Sun, 17 Dec 2023 04:11:47 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=3Dnewlib-cygwin.git;h=3D57e311e0deb= 23492edc94518c78cc57a224dbad9 commit 57e311e0deb23492edc94518c78cc57a224dbad9 Author: Jeff Law Date: Sat Dec 16 21:11:10 2023 -0700 Re: Fix moxie libgloss issues with c99 =20 Two libgloss issues specific to moxie-elf that show up build with GCC t= runk. =20 First, putnum.c uses "print" without a prototype. So I added one based= on the function's definition in print.c. Second sim-inbyte.c uses read, which= comes from unistd.h, so this adds a suitable #include. Diff: --- libgloss/moxie/putnum.c | 2 ++ libgloss/moxie/sim-inbyte.c | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/libgloss/moxie/putnum.c b/libgloss/moxie/putnum.c index 0f7e89453..9af5b4d4c 100644 --- a/libgloss/moxie/putnum.c +++ b/libgloss/moxie/putnum.c @@ -14,6 +14,8 @@ */ #include "glue.h" =20 +void print (char *); + /* * putnum -- print a 32 bit number in hex */ diff --git a/libgloss/moxie/sim-inbyte.c b/libgloss/moxie/sim-inbyte.c index 1e7466a8d..4cda6604a 100644 --- a/libgloss/moxie/sim-inbyte.c +++ b/libgloss/moxie/sim-inbyte.c @@ -14,6 +14,10 @@ * they apply. */ =20 +#include + +#include + int inbyte () {