WinGit-1.5.3-preview20071010
[msysgit.git] / mingw / bin / sdl-config
blob0244b5a9e069391a091d2213926a3be10c44ba4c
1 #!/bin/sh
3 prefix=/mingw
4 exec_prefix=${prefix}
5 exec_prefix_set=no
7 #usage="\
8 #Usage: sdl-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs]"
9 usage="\
10 Usage: sdl-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs] [--static-libs]"
12 if test $# -eq 0; then
13 echo "${usage}" 1>&2
14 exit 1
17 while test $# -gt 0; do
18 case "$1" in
19 -*=*) optarg=`echo "$1" | LC_ALL="C" sed 's/[-_a-zA-Z0-9]*=//'` ;;
20 *) optarg= ;;
21 esac
23 case $1 in
24 --prefix=*)
25 prefix=$optarg
26 if test $exec_prefix_set = no ; then
27 exec_prefix=$optarg
30 --prefix)
31 echo $prefix
33 --exec-prefix=*)
34 exec_prefix=$optarg
35 exec_prefix_set=yes
37 --exec-prefix)
38 echo $exec_prefix
40 --version)
41 echo 1.2.11
43 --cflags)
44 echo -I${prefix}/include/SDL -D_GNU_SOURCE=1 -Dmain=SDL_main
46 --libs)
47 echo -L${exec_prefix}/lib -lmingw32 -lSDLmain -lSDL -mwindows
49 --static-libs)
50 # --libs|--static-libs)
51 echo -L${exec_prefix}/lib -lmingw32 -lSDLmain -lSDL -mwindows
54 echo "${usage}" 1>&2
55 exit 1
57 esac
58 shift
59 done