problem with windows gui program

Henry K. H. Cheung
Fri Sep 25 06:18:00 GMT 1998


I'm new to this.  How do you compile and link a windows program?  I've
this (simplew32.c):

#include <windows.h>
#include <stdio.h>

WinMain (HINSTANCE hInst, HINSTANCE hPrev, LPSTR lpCmd, int nShow)
 char text[80];

  MessageBox (NULL, text, "Test", MB_OK);
  return 0;

and when I use bash this on NT4 (Cygnwin32 Beta 19) with
    'gcc -o simplew32.exe simplew32.c -lgdi32'

I got this:
c:\temp\cc0010481.o(.text+0x1c):simplew32.c: undefined reference to

Please help.


For help on using this list (especially unsubscribing), send a message to
"" with one line of text: "help".

More information about the Cygwin mailing list