From mboxrd@z Thu Jan 1 00:00:00 1970 From: MFLD Subject: Re: Question on import symbols generated by BCC Date: Sat, 11 Apr 2015 21:42:34 +0200 Message-ID: <5529792A.3070600@gmail.com> References: <55294997.3090501@gmail.com> Mime-Version: 1.0 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=dFzN73PuvnpZEqOyPTuvsrgI2/Rox/rbvK2il63FctY=; b=ixdp6rl77GB0pfC/m20UhSUVRs0FklZo9DnDpieEq5Uqqz9HfTIU7GE36Gkp0Z8kma lDDIxwAEzCPVBgutKCEVg4kZYYu/pnpGk6YsqJU9orpXVyrWhPWwV3k71fQ5Cmf/s4gt Q8127Gpq0uM1yEzPoimrd/6beKmGhsKT41nvMiK43aFMizsd4f/vuJbVqahGFd7NI41E 6wtBCaXD4xz6WOei3d0oeAUlvUNNHNlrv2wUF6OyjllPFf4wCYEl9Xn2YenQFToxEcnB xXpvQkDEYkwFf+X+5QovK4svcdXiSRpqhPlOm9VH/osaMGx4+3bzrZKvUpGTOVGwP/Au qMQw== In-Reply-To: <55294997.3090501@gmail.com> Sender: linux-8086-owner@vger.kernel.org List-ID: Content-Type: text/plain; charset="iso-8859-1"; format="flowed" To: ELKS -------- Message transf=E9r=E9 -------- Sujet : Re: Fwd: Question on import symbols generated by BCC Date : Sat, 11 Apr 2015 18:19:35 +0200 De : MFLD Pour : Robert de Bath <"robert$"@debath.co.uk> Copie =E0 : lkundrak@v3.sk, Jody Bruchon Hello, Thank you for your quick response, so that it is a bit more clear in my mind. But I am afraid I still don't fully understand the sentence: "But in general it's unlikely to catch many errors because the compiler will give a type error or a redefinition error.", and I feel unconfortable with it (no clear understanding =3D predictable failure in coding :-)). In the case of BCC adding a "extern _entry" in its output file when it scans an extern function declaration, could you explain me deeper why the compiler would generate an error ? Regards, MFLD Le 10/04/2015 23:49, Robert de Bath a =E9crit : Hello, Marc-Fran=E7ois, =46irst some examples... > SYM 0 00000000 ...IT _main # ^------------- This is an import # ^------------ We know it's in the TEXT segment > SYM 1 00000000 ..E.T _entry # ^-------------- External label definition. # ^------------ It is in Text segment < SYM 2 0000000c ....T _test # ^^------------- 'Object internal' (or 'static') label # ^------------ It is in Text segment < SYM 3 00000000 ...ID __end # ^------------- This is an import # ^------------ We know it's in the DATA segment > SYM 0 00000000 ..E.T _main # ^-------------- External label definition. # ^------------ It is in Text segment > SYM 1 00000000 ...IU _entry # ^------------- This is an import # ^------------ The segment is not known. If the label is in a known segment and is different between two objects the linker will generate a warning. For tiny model (CS=3DDS=3DSS) this = isn't significant, but if CS!=3DDS it will be a problem. It would probably be reasonable for BCC to generate the directives to p= ut external labels into the correct segment. But in general it's unlikely to catch many errors because the compiler will give a type error or a redefinition error. So it was never implemented. --=20 Rob. (Robert de Bath ) On Thu, 9 Apr 2015, Marc-Fran=E7ois LUCCA-DANIAU wrote: Hello, I'm Marc-Fran=E7ois, a french guy playing with ELKS and a SBC based on the IBM-PC XT architecture (yes it still exists in production , that's an Advantech device : http://www2.advantech.com/products/1-2JKP2Y/SNMP-1000-B/mod_B01ABE8D-C8= AA-4530-8E3C-9FCD2623D9D6.aspx).=20 I got a problem with DEV86 that I initially submitted to the ELKS mailing list, but Jody Bruchon redirected to you, as the latest deep contributors to DEV86. Would you be so kind to give a piece of advice to the question below (if it is a real problem or not) and suggest where to dig to fix that problem ? Thanks in advance, Regards, MFLD -- To unsubscribe from this list: send the line "unsubscribe linux-8086" i= n the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html