|
Using Allegro 5 with Code::Blocks 10.05 |
herindes
Member #13,286
August 2011
|
Hi all, I'm trying to use Allegro 5 with Code::Blocks. I initially used MSVC 2010 and got a game running but for prompt reasons I want to use Code::Blocks. I followed the wiki setup tutorial step-by-step until "Now you are ready to code!!!." (although "and a small set of binaries from the DirectX Direct3D library." didn't show up later in the tutorial) Anyway, I am having a problem. When I even try to build the first tutorial example it fails and opens up stdint.h with these errors: Quote: 33 error: 'long long long' is too long for GCC
33typedef long long int64_t;
34typedef unsigned long long uint64_t;
Using Win7 x64, Allegro 5.0.3, Code::Blocks 10.05, MinGW 4.5.2 Did I leave out any other information? My file is called main.cpp Best, H |
AMCerasoli
Member #11,955
May 2010
|
herindes said: although "and a small set of binaries from the DirectX Direct3D library." didn't show up later in the tutorial Well, that's because you didn't click the "installing MinGW" link, but I have been using Allegro without those binaries... So I might modify that... there is really little info about those binaries... About the errors I have no idea, wait for the professionals.
|
Matthew Leverton
Supreme Loser
January 1999
|
Sounds like maybe you are using the MSVC Allegro headers with MinGW. |
herindes
Member #13,286
August 2011
|
AMCerasoli said: Well, that's because you didn't click the "installing MinGW" link, but I have been using Allegro without those binaries... So I might modify that... there is really little info about those binaries... Aha, that's true! I did go through with the tutorial you mention but I forgot I did not copy the dx9mgw.zip files because the link to that file is broken in the tutorial at the end. Matthew Leverton said: Sounds like maybe you are using the MSVC Allegro headers with MinGW. Okay, that fixed it! I redid the setup using the MinGW 4.5.2 files instead and it worked. However, when I redid the C::B setup using the 5.0.4 release I got this error: Quote: C:\allegro\lib\liballegro-5.0.4-static-mt.a(wsystem.o):wsystem.c But 5.0.3 works so I am satisfied. Thanks! H |
Matthew Leverton
Supreme Loser
January 1999
|
When you static link, if you get an undefined reference, just Google the function name (PathFindOnPath) and look up the library it needs. In this case it is "Shlwapi.lib". Or, I suppose it's libshlwapi.a on MinGW. |
|