delorie.com/archives/browse.cgi | search |
X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f |
X-Recipient: | djgpp AT delorie DOT com |
ARC-Seal: | i=1; a=rsa-sha256; t=1624830619; cv=none; |
d=zohomail.com; s=zohoarc; | |
b=ARygaw+5oTxG5a25qWP243HnubY8GeBjDGlcDhN+j7bJ4lyMrflYUq5dcusQQ7Nt2xdvTuws6WqQ21otiVoMxyp9SwpE0Mxus0Pi3Ol3ARw7lV5Pe6eNNzDnfeMtAoGhoLO2Ng1XCKAXRbxNdwZer6lUbHd3rCBK3eeWioUQSuE= | |
ARC-Message-Signature: | i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; |
t=1624830619; h=Content-Type:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; | |
bh=WLKoiNPndeS6As8GsAdKsQduO92Z2sTNSTGXCpkK44w=; | |
b=liGMInUbAkq95xKO9xW5+LHHbPsb3qe+vypiUEUvwrilo+DJhbEeci7bMhumYeL33yehAtXu7G09M4REbssm58l4E71sCM8xL2A8YKC3Z6kSyfH88+pU2dIc0mUc7nArBOjEdfieIHN2c60Jz/TiLr3ifcbVX9EDYkSeYVg/byQ= | |
ARC-Authentication-Results: | i=1; mx.zohomail.com; |
dkim=pass header.i=zoho.com; | |
spf=pass smtp.mailfrom=dufresnep AT zoho DOT com; | |
dmarc=pass header.from=<dufresnep AT zoho DOT com> | |
DomainKey-Signature: | a=rsa-sha1; q=dns; c=nofws; |
s=zapps768; d=zoho.com; | |
h=date:from:to:cc:message-id:in-reply-to:references:subject:mime-version:content-type:user-agent; | |
b=bs8FfTThGBqpIi6nMsAQAvy/XjRTBrV3BgllKzTpnzN/Ww8k9fbWOE7qB0clAPD4DOhGeWt8rlFg | |
X+omtB76S3mCBGcrOq5SXBbiJXF0kQBAgoU/dZXdLH7Wc5J2nNpB | |
X-Original-DKIM-Signature: | v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1624830619; |
s=zm2020; d=zoho.com; i=dufresnep AT zoho DOT com; | |
h=Date:From:To:Cc:Message-Id:In-Reply-To:References:Subject:MIME-Version:Content-Type; | |
bh=WLKoiNPndeS6As8GsAdKsQduO92Z2sTNSTGXCpkK44w=; | |
b=QZz3Q7d+7buhEbwfypIPYb739h53uhWpo7GKlHQaqL2rm2dceqapOPpa+Rqq7kQm | |
vnDWh77umBupq59K6sFwozK26DCG3WiB8gRS1eU9dxXWmW+uVK5EvxMY6zrXUV7h965 | |
IACMTOAkeqzlmQMdZ0gE75g/duwtLV2fhI1cXvu4= | |
Date: | Sun, 27 Jun 2021 17:50:12 -0400 |
From: | "Paul Dufresne (dufresnep AT zoho DOT com) [via djgpp AT delorie DOT com]" <djgpp AT delorie DOT com> |
To: | "djgpp" <djgpp AT delorie DOT com> |
Cc: | "freedos-devel" <freedos-devel AT lists DOT sourceforge DOT net> |
Message-Id: | <17a4f739486.10f49065955874.8303595826833934174@zoho.com> |
In-Reply-To: | <17a4a690e82.ad5bda6d47674.7543348174997411766@zoho.com> |
References: | <17a309c6725 DOT ee2b33335838 DOT 5210672258564129766 AT zoho DOT com> <CAN1+P_3bouS5PbTdc6jJBKW=zdabEE2-zy5c1F=jR+F+3Tz0eA AT mail DOT gmail DOT com> <17a30b8508b DOT eceb84066270 DOT 6146636058200994488 AT zoho DOT com> <17a49890ca6 DOT 123f188ed46443 DOT 7177863653080197011 AT zoho DOT com> <17a4a690e82 DOT ad5bda6d47674 DOT 7543348174997411766 AT zoho DOT com> |
Subject: | Re: Allegro library would need to be recompiled with -fgnu89-inline |
? | |
MIME-Version: | 1.0 |
Importance: | Medium |
User-Agent: | Zoho Mail |
X-Mailer: | Zoho Mail |
Reply-To: | djgpp AT delorie DOT com |
Errors-To: | nobody AT delorie DOT com |
X-Mailing-List: | djgpp AT delorie DOT com |
X-Unsubscribes-To: | listserv AT delorie DOT com |
------=_Part_153977_1795701965.1624830612614 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit ---- Le sam., 26 juin 2021 18:20:36 -0400 Paul Dufresne <mailto:dufresnep AT zoho DOT com> I wrote ---- >I now think that adding "external" before declarations in .h is the correct solution. >If they were not mark static already, it is that the value is expected to be shared (being global). >The solution is *I now think* to add external, and have the real declaration in a unique place, like in main.c. I can now confirm this is a change in GCC 10 ( from https://gcc.gnu.org/gcc-10/changes.html ): "GCC now defaults to -fno-common. As a result, global variable accesses are more efficient on various targets. In C, global variables with multiple tentative definitions now result in linker errors. With -fcommon such definitions are silently merged during linking." More details in: https://gcc.gnu.org/gcc-10/porting_to.html#common I am now realizing it can be tedious to rearrage the code to initialize stuff only once. -fcommon could allows us to do the bad thing for some time ------=_Part_153977_1795701965.1624830612614 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head>= <meta content=3D"text/html;charset=3DUTF-8" http-equiv=3D"Content-Type"></h= ead><body ><div style=3D"font-family: Verdana, Arial, Helvetica, sans-serif= ; font-size: 10pt;"><div style=3D"" data-zbluepencil-ignore=3D"true" class= =3D"zmail_extra"><div id=3D"Zm-_Id_-Sgn1">---- Le sam., 26 juin 2021 18:20:= 36 -0400 <b>Paul Dufresne <<a target=3D"_blank" href=3D"mailto:dufresnep= @zoho.com">dufresnep AT zoho DOT com</a>></b> I wrote ----<br></div><div>>I = now think that adding "external" before declarations in .h is the correct s= olution.<br></div><blockquote style=3D"margin: 0px;"><div><div style=3D"fon= t-family : Verdana, Arial, Helvetica, sans-serif; font-size : 10pt; ">= <div>>If they were not mark static already, it is that the value is expe= cted to be shared (being global).<br></div><div>>The solution is *I now = think* to add external, and have the real declaration in a unique place, li= ke in main.c.<br></div></div></div></blockquote></div><div><br></div><div>I= can now confirm this is a change in GCC 10 ( from <a target=3D"_blank" hre= f=3D"https://gcc.gnu.org/gcc-10/changes.html">https://gcc.gnu.org/gcc-10/ch= anges.html</a> ):<br></div><div>"GCC now defaults to <code>-fno-common</cod= e>. As a result, global variable accesses are more efficient on various targets. In C, globa= l variables with multiple tentative definitions now result in linker er= rors. With <code>-fcommon</code> such definitions are silently merged durin= g linking."<br></div><div><br></div><div>More details in:<br></div><div= ><a target=3D"_blank" href=3D"https://gcc.gnu.org/gcc-10/porting_to.html#co= mmon">https://gcc.gnu.org/gcc-10/porting_to.html#common</a><br></div><div><= br></div><div>I am now realizing it can be tedious to rearrage the code to = initialize stuff only once.<br></div><div>-fcommon could allows us to do th= e bad thing for some time<br></div></div><br></body></html> ------=_Part_153977_1795701965.1624830612614--
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |