Q. Where and how do I get the Allegro library itself to install?
A. You dont need to install Allegro, it comes with the planet package.

Q. I get errors about the planet download not completing.
A. Planet sometimes has problems with very large packages, like this one. You can always download the latest package from my home page and install it on the command line.


To install on the command line type the following
$ planet -f allegro.plt kazzmir 1 4

Those last two parameters can really be whatever you want, they are just version numbers, but they should probably match the version that you downloaded.

Q. The planet package wont install. I am on Ubuntu.
A. Ubuntu is a binary distribution which doesnt come with the tools necessary to build Allegro from source. To get these tools goto the ubuntu package manager and install the following packages:


Planet wont know if Allegro doesn't build correctly so you will need to uninstall the package before trying to install it again. This can be accomplished like so:
$ planet -r kazzmir allegro.plt 1 4

Replace the last two parameters with the version of Allegro you are trying to use.

Q. I get an error like "Scheme->C: expects argument of type <int32>; given 50.3".
A. This means you passed in a floating point number to an allegro function that requires an integer. You can use the round* method to convert a float to an integer or use the following code:

(define (my-round i)
  (inexact->exact (round i)))

Q. How do I build stand-alone executable that use Allegro?
A. You must use the 'mzc' program to generate executables. Generating executables from drscheme( scheme -> create executable ) is not supported.

The basic setup consists of compiling your program with mzc then create a distribution using mzc. Your program must be inside a module

(module mygame mzscheme

Then assuming this file is called mygame.ss you would do the following

> mzc --exe mygame mygame.ss

Then to package all the required files into a single directory run this command( depending on which platform you are on )

$ mzc --exe-dir mydir 
  ++collects-copy /home/kazzmir/.plt-scheme/planet/300/360/cache/kazzmir/allegro.plt/2/1/native 
  --collects-path native mygame


$ mzc --exe-dir mydir 
  ++collects-copy c:/Documents and Settings/kazzmir/Application Data/PLT Scheme/planet/300/360/cache/kazzmir/allegro.plt/2/1/native
  --collects-path native mygame.exe


$ mzc --exe-dir mydir
  ++collects-copy /Users/jon/Library/PLT Scheme/planet/300/360/cache/kazzmir/allegro.plt/2/1/native
  --collects-path native mygame

Change paths to suit your needs. The most important part of the above commands is the '-collects-path native' which installs the Allegro libaries to a directory named 'native' inside the distribution.