EGCS Mingw32 1.0.2 - compilation problem - undefined reference to a function
Mumit Khan
khan@xraylith.wisc.edu
Wed Aug 5 02:07:00 GMT 1998
On Tue, 4 Aug 1998, Inquisitor Nikodemus wrote:
> hey!
>
> I wrote a small win95 program,that simply does nothing.I wanted to compile
> it with egcs (mingw32 native,1.0.2) with command " gcc w.c -o w.exe ".
The command line you've used is appropriate for "Console" programs, but
not quite enough for windows program. Here's how you compile windows
programs:
% gcc w.c -o w.exe -mwindows
which is equivalent to:
% gcc w.c -o w.exe -Wl,--subsystem,windows -luser32 -lgdi32 -lcomdlg32
I have a port of GDB for i386-mingw32 at:
ftp://ftp.xraylith.wisc.edu/pub/khan/gnu-win32/mingw32/ports/
Now, some comments:
1. Have the courtesy to supply correct code. What you have here needs
editing before it will even compile.
2. Please spend the time to study some of the net resources for
gnu-win32 tools (start at http://www.cygnus.com/misc/gnu-win32/ or
http://www.xraylith.wisc.edu/~khan/software/gnu-win32/ and follow
various links) where there is more information on using Gnu-Win32
tools. Colin Peters has the beginning of a tutorial on his web
page.
3. You *definitely* need to belong to gnu-win32 mailing list (see
Cygnus web page above) on how to join where this is discussed
quite a bit. The mailing list archives are at
http://www.cygnus.com/ml/gnu-win32/ where you can do a search
for information such as this.
Regards,
Mumit
More information about the Gcc
mailing list