Sie sind auf Seite 1von 26

Slide 1

Install MinGW 4.8.1 and build Allegro 5.0.11


Slide #

Contents

Download and Install MinGW 4.8.1

Set Windows 'Path' Variable to


newly installed MinGW 4.8.1

Remove conflict if previous


Codeblocks\MinGW 4.7.1 exists

Download & install DirectX

11

Install Freetype library in MinGW

14

Install Allegro source

16

Create deps folder for freetype and


ttf

19

Install Cmake

22

Build Allegro 5

26

Run example program

Install MinGW GCC Compiler

Slide 2
Sourceforge.net/projects/mingw/files/

Slide 3

Slide 4

Note installation to C: root


directory

Slide 5

Install base, g++, and msys base


'Apply changes'

Set the Windows Path variable

Slide 6

to include or change path to C:\MinGW\bin


Select options below
Navigate to this window by
clicking
Windows Start->
Computer(Rt Click)->
Properties->
Advanced system settings->
System Properties->
Environment Variables

Slide 7

Add or change ;C:\MinGW\bin in the path statement


Press OK repeatedly to exit Advanced system settings
Open a CMD prompt and enter 'gcc -v' to confirm correct installation.
Response should be: gcc version 4.8.1

If installed, in Code::Blocks folder rename MinGW to MinGWbak to


prevent conflicts with old 4.7 version

Slide 8

Download dx9mgw.zip and extract files


alleg.sourceforge.net/download.html

Slide 9

Slide 10
Copy include and lib folders from dx9mgw
into C:\MinGW folder.
Merge and overwrite all existing files

Install FreeType fonts server

Slide 11

http://gnuwin32.sourceforge.net/packages/freetype.htm

Download FreeType 'Setup' package installer

Slide 12

Then run the installer that was just downloaded

After installation, copy freetype6.dll library to C:\MinGW\bin folder

Slide 13

Install Allegro source files

Slide 14

Download allegro-5.0.11.zip library


alleg.sourceforge.net/download.html
And uncompress to a working folder

Slide 15

Create a deps folder inside the uncompressed Allegro folder

Create a freetype folder in deps

Slide 16

Slide 17

Copy Freetype 'lib' and 'include' into deps\freetype folder

Slide 18

Copy
allegro\addons\ttf
folder into deps
folder

Install Cmake

Slide 19

www.cmake.org/download/

Download Cmake Win32 installer and install on your computer

Slide 20

Slide 21

Build Allegro Library

Slide 22
Create new 'build' folder in allegro folder

Open CMD prompt as administrator, cd to build folder in allegro

Issue command: cmake .. -G MinGW Makefiles

Slide 23

Slide 24
After build files have been
created, then give command:
mingw32-make

Slide 25

After build is complete, then


give install command:
mingw32-make install
This places libraries in
C:\MinGW\lib and \bin folders

Slide 26
After Allegro build is complete, go to the 'build\examples' folder and run ex_rotate.exe

Turn in screen copy of program


running to demonstrate
successful completion of
Exercise #1

Das könnte Ihnen auch gefallen