I have wrote several ASM programs and compiled it using VS 2008/2010/2013 using the Visual Studio Command Prompt as follows
ml program.asm /link msvcrt.lib
The code
.586
.MODEL FLAT
.STACK 100h
EXTERN _printf :PROC
.DATA
arg BYTE "hello world", 0dh, 0ah, 0
.CODE
_main PROC
push OFFSET arg
call _printf
add esp, 4
xor eax, eax
ret
_main ENDP
END
Up to 2013, I was able to compile it, but for VS 2015, it says that _printf is not found. Doing a dumpbin /exports on msvcrt.dll, it says that printf is an export (but _printf is not found). I tried changing _printf to printf but still no luck.
Does anyone know how to resolve this?