From mboxrd@z Thu Jan 1 00:00:00 1970 From: Harry Kalogirou Subject: Re: bcc question Date: 26 May 2002 15:03:56 +0300 Sender: linux-8086-owner@vger.kernel.org Message-ID: <1022414624.29568.36.camel@cool> References: Mime-Version: 1.0 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: In-Reply-To: List-Id: Content-Type: text/plain; charset="iso-8859-7" To: Ken Martwick Cc: Linux 8086 =D4=E7=ED =CA=F5=F1, 26-05-2002 =F3=F4=E9=F2 04:25, =EF/=E7 Ken Martwic= k =DD=E3=F1=E1=F8=E5: > How does one write inline assembly code in "bcc" to move > a register value to a "C" variable? The following code > is acceptable to "bcc", but "ld86" fails with something > about undefined variables. I couldn't find any examples. > =20 > -------------------------------------------------------- > =20 > int main() > { > int codeseg, datseg; > =20 > #asm > push cs > pop ax > mov codeseg,ax > push ds > pop ax > mov datseg,ax > #endasm > =20 > -------------------------------------------------------- > =20 > Ken Martwick > =20 Replace "mov codeseg,ax" with "mov _codeseg,ax" and "mov datseg,ax" with "mov _datseg,ax" and it should be fine... Harry - 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