NASM - The Netwide Assembler

NASM Forum => Using NASM => Topic started by: nobody on March 24, 2009, 08:07:26 PM

Title: adm64 Vista 64 C with asm first
Post by: nobody on March 24, 2009, 08:07:26 PM
Hi ,

Here is my code.

----------------
#include

int main(void)
{
   int x =50;

asm{
      MOV EAX, x
      SHL EAX, 1
   }

printf("x = %d\n", x);

return 0;
}
---------------------
The outputted .exe does not work with:

bcc32 -omyFirst.exe myfirst.c
Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
myfirst.c:
Warning W8002 myfirst.c 16: Restarting compile using assembly in function main
Turbo Assembler  Version 5.0  Copyright (c) 1988, 1996 Borland International

Assembling file:   myFirst.ASM
Error messages:    None
Warning messages:  None
Passes:            1
I tried it with XP and a 32 bits asus machine.  Does not work either.

How could I create a working 32 bits exe?


JPDaviau
How could I create a 64 bits exe?
Title: Re: adm64 Vista 64 C with asm first
Post by: nobody on March 24, 2009, 09:31:21 PM
http://www.viva64.com/links/64-bit-development/ (http://www.viva64.com/links/64-bit-development/)