File: compile_examples.sh

package info (click to toggle)
allegro4 2%3A4.0.1-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 17,052 kB
  • ctags: 12,972
  • sloc: ansic: 109,525; asm: 16,672; cpp: 3,221; sh: 1,761; makefile: 556; pascal: 105; perl: 73
file content (15 lines) | stat: -rw-r--r-- 467 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/sh
echo Creating $HOME/allegro.tmp
cd ~
mkdir allegro.tmp
cd allegro.tmp
#cp /usr/share/doc/liballegro-doc/examples/* .
echo "Uncompressing example source from " /usr/share/doc/liballegro-doc/examples/*.tgz
tar zxf /usr/share/doc/liballegro-doc/examples/*tgz
#gunzip -v *.gz
echo "Compiling examples..."
for src in *.c; do
  gcc -g -O2 -o ${src%.c} $src `allegro-config --libs`
#  strip ${src%.c}
done
echo "Compiled example programs are now in ~/allegro.tmp"