How do you use printf from Assembly?
- by bobobobo
I have an MSVC++ project set up to compile and run assembly code.
In main.c:
#include <stdio.h>
void go() ;
int main()
{
go() ; // call the asm routine
}
In go.asm:
.586
.model flat, c
.code
go PROC
invoke puts,"hi"
RET
go ENDP
end
But when I compile and run, I get an error in go.asm:
error A2006: undefined symbol : puts
How do I define the symbols in <stdio.h> for the .asm files in the project?