What is still to be done?
SNES4EVER

Well, I think I've done everything as said in the document how to build up allegro using
MinGW.
I got the latest MinGW(3.0) and dx_80ming.zip and the latest allegrozipfile.
I have installed MinGW3.0, extracted the allegrozip before and extracted the dx_80mingw.zip to the directory of MinGW.
Laste but not least I have edited MINGDIR and set it to the MInGW directory.
Have I to extract the allergo.zip into the MinGW directory?
How can I start or where can I find allergo to start it?

regards,
SNES4EVER

miran

There is no allegro.zip. There is an allegro-4.2.0.zip though. You extract it wherever you want. Then you go to allegro/docs/build and read mingw32.txt.

SNES4EVER

Well, you're right, but I just didn't remember how the zip-folder of allegro was called.
BUT: I have extracted Allegro and did everything as I was told in the readme.
Is there still to do more to make allegro work?
I can't start allegro, cause I don't know where the exe-file is.
So where's allegro or how can I start it?

regards,
SNES4EVER

miran

You don't start Allegro. Allegro is not a program. Allegro is a programming library intended for making games and other multimedia applications. You link it with programs you write and compile:

1. Include <allegro.h> in your code.
2. Use functions that Allegro provides in your code.
3. Compile your code.
4. Link your compiled code with liballeg.a to produce an executable of your program.

SNES4EVER

Well, I just started with this book about allegro.
There was an example, but nothing about where to write the program.
So I thought I would have to open allergo.
Can you please tell me where I can write the program?
I got Turbopascal, but I guess it will not work(or?)

regards,
SNES4EVER

miran

You write code in a text editor (for example Notepad). There are many text editors that are better than Notepad though, because they are specialized for writing code. They print parts of the code in different colours, they format the code, they show you function parameters and auto-complete function names as you type them, and so on. Personally I use a program called SciTE for this, but there are many more.

To compile the code and create an exe you need a compiler. Because Allegro is a C library, you need to write the code in the language of C (or C++). To compile C code you need a C compiler and to compile C++ code you need a C++ compiler. Turbopascal is a Pascal compiler, so it won't do. A popular compiler for C and C++ in Windows is called MinGW. You need to get it! Once you have it installed on your system, you compile the code by runnin the "gcc" or "g++" program from the command line and give it all the right parameters (i.e. names of the source files, flags, name of the exe file, etc). You can also write a makefile that automates this process so you don't type the same command every time you need to compile.

There are also programs which combine a text editor and compiler (and other tools) in one complete package. Such a package is called "Integrated Development Environment" or IDE for short. One popular IDE for Windows is Dev-C++. Another popular, but a commercial one you need to pay money for, is called MS Visual Studio. So get one of those if you don't want to use a simple text editor and command line interface.

Arthur Kalliokoski

You can still get Visual C for free until end of November (you have to download the SDK as well). I got it a few months ago and it works, although I prefer MingW.

http://msdn.microsoft.com/vstudio/express/visualC/default.aspx

Dennis
Quote:

You can still get Visual C for free until end of November

Not just until the end of November: http://msdn.microsoft.com/vstudio/express/support/faq/#pricing (it's been made price-free permanently)

SNES4EVER

Thanks to miran.
I already got MinGW 3.0, but this book didn't tell anything anout writing programes in the texteditor.

reagrds,
SNES4EVER

HoHo

I'm sorry if this sounds rude but did you actually read the book? I know no other way to use Allegro than to write some code in text editor and compile it to executeable.

GullRaDriel

Hey, HoHo, you were not aware that allegro has a built-in neuronal game developping plugging ?
It just scans your brain to see what game you mean, after what it just starts writting code and building itself !!

That is the new Allegro Brain Utility System Evolution !

On Toppic, I just think the OP needs to read more about programming, compiling, linking, after what, with a few 'hello world' and other basis he will understand what you guys are trying to teach.

SNES4EVER

Well still got a little problem with compiling(and no, I haven't read the book till the end cause there is a step-by step how to do).
There is an example,this program should show some easy message:
#include <stdio.h>
int main(int argc, char* argv[]) {
print("Hallo Welt.\n");
}

The book told to save it as hallo.c and compile it with "gcc hallo.c -o hallo.exe".
I opende the commando line, typed the place where MinGW and gcc was saved.
But the answer was: NO INPUT FILES or that the path was wrong.
I tried it some more times, but it didn't work.
How can I compile this program?(it's saved in Own Data).
My commandoline looked like this

D:\Programme\MinGW\bin\gcc hallo.c -o hallo.exe
(I'm german, so don't wonder about Programme)

How do I attach the place where I saved the text?

LennyLen
Quote:

D:\Programme\MinGW\bin\gcc hallo.c -o hallo.exe

You need to call gcc from the directory that hallo.c is in.

Quote:

How do I attach the place where I saved the text?

At the bottom of the text-window where you write your post is an "attachments" tab.

Thomas Fjellstrom
Quote:

You need to call gcc from the directory that hallo.c is in.

He did, he just used the full path to gcc, making me think its not installed properly.

Thread #587599. Printed from Allegro.cc