Hi Frank -
I tried your wild guess but it didn't work. Here's the command lines:
c:\MinGW\bin\nasm.exe -f win32 -o testpgm.o testpgm.asm
c:\MinGW\bin\gcc.exe -o testpgm.exe testpgm.o
Here's the code:
%define _main WinMain@16
segment .data
msg db "hiya", 0
outfmt db "%s", 0
segment .text
global _test
extern _printf
_test:
enter 0,0
pusha
push msg
push outfmt
call _printf
add esp, 8
popa
mov eax, 0
leave
ret
Doesn't matter to the linker whether the define is in or out. It continues to report "undefined reference to WinMain@16.
I wrote a little tiny C program just to see how much I might have destroyed in the MinGW library. The C program compiled and linked fine and ran as expected....
Thanks for your help.
Mark A.