Error running Tutorial example.

0 Allen Wright · May 30, 2014
In the C++ Tutorial #15, I get the following error when I try to build and run the example: 

c:\program files (x86)\codeblocks\mingw\bin\..\lib\gcc\mingw32\4.7.1\..\..\..\libmingw32.a(main.o):main.c:(.text.startup+0xa7)undefined reference to `WinMain@16

I am running Codeblocks ver 13.12 on a Dell M 4700 Laptop, 64 bit with Windows 7 Enterprise. 

Any ideas Please?



Post a Reply

Replies

Oldest  Newest  Rating
-1 Alexander Taylor · June 13, 2014
Problemn is in main.c, you have an undefined reference to WinMain, meaning WinMain is probably not defined.

Try changing your int main() to int WinMain() and see if that fixes it, if not, post again with your main.c code
  • 1

C++

106,979 followers
About

Used in many types of software including music players, video games, and many large scale applications.

Links
Moderators
Bucky Roberts Administrator