Sign in to follow this  

ALLEGRO errors, please help

This topic is 2545 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Iam using code:blocks, as well as the Allegro library, everything is fully installed with the mingw compiler. Iam attempting to learn the library and have been trying to get this simple program to run for days.

I finally thought i had fixed it when now iam recieving two errors that make no sense to me. Iam positive however that my code is correct, since it works on another machine.

these are the errors=


obj\Debug\Untitled2.o|| In function `mangled_main':|
C:\Users\Mike\Desktop\TICC\Untitled2.c|6 |undefined reference to `_install_allegro_version_check|



||=== Build finished: 1 errors, 0 warnings ===|


iam clueless to what this means. any help is greatly appreciated.

Share this post


Link to post
Share on other sites
No END_OF_MAIN() being used?
Or perhaps you linked the library in the wrong order. I don't know if this can be a problem but try switching the allegro.lib file and the mingw.lib file or whatever like "allegro.lib mingw.lib" instead of "mingw.lib allegro.lib". Perhaps I've had too much wine already but if I remember correctly this could be a problem in some cases.

Share this post


Link to post
Share on other sites
Quote:
Original post by fender0613
im pretty sure i have in project options include liballeg.a in my parameters. could it mean anything else?

As a test, I just wrote a program that simply included allegro.h and called allegro_init(). If I built it without linking to liballeg.a (or one of the other versions of the Allegro library), I received the same error as you. The moment I linked to the library, it went away.

Quote:
Original post by Toadhead
No END_OF_MAIN() being used?

That results in a different error - undefined reference to `WinMain@16'

Share this post


Link to post
Share on other sites

This topic is 2545 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this