metasurf

view configure @ 7:246260d95415

added /usr/local/lib linker path
author John Tsiombikas <nuclear@mutantstargoat.com>
date Sat, 21 Jan 2012 04:15:30 +0200
parents
children
line source
1 #!/bin/sh
3 prefix=/usr/local
4 opt=true
5 dbg=true
7 while [ $# -ne 0 ]; do
8 case "$1" in
9 --prefix=*)
10 prefix=`echo $1 | sed 's/--prefix=//'`
11 ;;
13 --enable-debug)
14 dbg=true
15 ;;
16 --disable-debug)
17 dbg=false
18 ;;
19 --enable-opt)
20 opt=true
21 ;;
22 --disable-opt)
23 opt=false
24 ;;
25 esac
26 shift
27 done
30 echo 'configuring metasurf...'
31 echo " prefix: $prefix"
32 echo 'debugging symbols:' `$dbg && echo yes || echo no`
33 echo ' optimization:' `$opt && echo yes || echo no`
35 echo 'generating makefile...'
36 echo "# automatically generated by the configure script" >Makefile
37 echo "PREFIX = $prefix" >>Makefile
38 $opt && echo "opt = -O3" >>Makefile
39 $dbg && echo "dbg = -g" >>Makefile
40 cat Makefile.in >>Makefile
42 echo done.