User forums > Help

Using Allegro with CodeBlocks

<< < (2/3) > >>

mattireland:
@Michael: Thanks very, very much! That's really nice of you.
EDIT: Just gave it a go. It didn't work for me but I should be very grateful if you did have a go just in case I am missing something. Thanks.

@PsYhLo:
obj\Debug\main.o(.text+0x27)||In function `Z13_mangled_mainv':|
C:\Documents and Settings\Matt Ireland\My Documents\Programming\CBCPP\Allegro\AllegroTest1\AllegroTest1\main.cpp|6|undefined reference to `_install_allegro_version_check'|
obj\Debug\main.o(.text+0x2c):C:\Documents and Settings\Matt Ireland\My Documents\Programming\CBCPP\Allegro\AllegroTest1\AllegroTest1\main.cpp|7|undefined reference to `install_keyboard'|
obj\Debug\main.o(.text+0x58):C:\Documents and Settings\Matt Ireland\My Documents\Programming\CBCPP\Allegro\AllegroTest1\AllegroTest1\main.cpp|8|undefined reference to `set_gfx_mode'|
obj\Debug\main.o(.text+0x5d):C:\Documents and Settings\Matt Ireland\My Documents\Programming\CBCPP\Allegro\AllegroTest1\AllegroTest1\main.cpp|10|undefined reference to `readkey'|
obj\Debug\main.o(.text+0x92)||In function `WinMain':|
C:\Documents and Settings\Matt Ireland\My Documents\Programming\CBCPP\Allegro\AllegroTest1\AllegroTest1\main.cpp|15|undefined reference to `_WinMain'|
||=== Build finished: 5 errors, 0 warnings ===|

PsYhLo:
you have to linked against allegro.a file
at this moment i can't give you shot to see it how you can do it
but after some time (20 or more minutes) i'll ;)

Edit:
right button at projects name->Build options...->
and after that search the file ->

note i'm with linux but its the same ;)

mattireland:
Hi,

Thanks very much for going to all that effort! I've done all that but get the following in the log:


--- Code: ----------------- Build: Debug in AllegroTest1 ---------------

Linking console executable: bin\Debug\AllegroTest1.exe
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2 -LC:\Dev-Cpp\Packages\lib  -o bin\Debug\AllegroTest1.exe obj\Debug\main.o    C:\Documents: Invalid argument
mingw32-g++.exe: and: No such file or directory
mingw32-g++.exe: Settings\Matt: No such file or directory
mingw32-g++.exe: Ireland\My: No such file or directory
mingw32-g++.exe: Documents\Programming\C++\Libraries: No such file or directory
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2\lib\libaldat.a C:\Documents: Invalid argument
mingw32-g++.exe: and: No such file or directory
mingw32-g++.exe: Settings\Matt: No such file or directory
mingw32-g++.exe: Ireland\My: No such file or directory
mingw32-g++.exe: Documents\Programming\C++\Libraries: No such file or directory
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2\lib\liballd.a C:\Documents: Invalid argument
mingw32-g++.exe: and: No such file or directory
mingw32-g++.exe: Settings\Matt: No such file or directory
mingw32-g++.exe: Ireland\My: No such file or directory
mingw32-g++.exe: Documents\Programming\C++\Libraries: No such file or directory
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2\lib\liballd_s.a C:\Documents: Invalid argument
mingw32-g++.exe: and: No such file or directory
mingw32-g++.exe: Settings\Matt: No such file or directory
mingw32-g++.exe: Ireland\My: No such file or directory
mingw32-g++.exe: Documents\Programming\C++\Libraries: No such file or directory
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2\lib\liballeg.a C:\Documents: Invalid argument
mingw32-g++.exe: and: No such file or directory
mingw32-g++.exe: Settings\Matt: No such file or directory
mingw32-g++.exe: Ireland\My: No such file or directory
mingw32-g++.exe: Documents\Programming\C++\Libraries: No such file or directory
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2\lib\liballeg_s.a C:\Documents: Invalid argument
mingw32-g++.exe: and: No such file or directory
mingw32-g++.exe: Settings\Matt: No such file or directory
mingw32-g++.exe: Ireland\My: No such file or directory
mingw32-g++.exe: Documents\Programming\C++\Libraries: No such file or directory
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2\lib\liballp.a C:\Documents: Invalid argument
mingw32-g++.exe: and: No such file or directory
mingw32-g++.exe: Settings\Matt: No such file or directory
mingw32-g++.exe: Ireland\My: No such file or directory
mingw32-g++.exe: Documents\Programming\C++\Libraries: No such file or directory
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2\lib\liballp_s.a: No such file or directory
mingw32-g++.exe: no input files
Process terminated with status 1 (0 minutes, 0 seconds)
0 errors, 0 warnings

--- End code ---

It says 0 errors, 0 warnings so I don't understand why it won't run? There's nothing in the debug folder either.

dje:
Hi !

As the log tells you :
mingw32-g++.exe: e.t.c\allegro-mingw-4.2.2\allegro-mingw-4.2.2 -LC:\Dev-Cpp\Packages\lib  -o bin\Debug\AllegroTest1.exe obj\Debug\main.o    C:\Documents: Invalid argument
mingw32-g++.exe: and: No such file or directory
mingw32-g++.exe: Settings\Matt: No such file or directory

you've got a problem with spaces in your path.
Try to move your project dir to a dir without spaces in path.

Dje

mattireland:
Thanks very much! Moved them into C:\Allegro and it worked fine.

Thanks again very much everyone!

Matt. I

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version