697
|
1 #!/bin/bash |
|
2 if [ -z "$1" ]; then |
|
3 echo 'usage: ./configure <python[version]>' |
|
4 exit 1 |
|
5 fi |
|
6 |
|
7 echo -ne 'checking for python...' |
|
8 if which `which "$1"` >/dev/null; then |
|
9 PYPATH=`which "$1"` |
|
10 echo -ne ' OK' |
|
11 echo |
|
12 else |
|
13 echo -ne ' FAILED' |
|
14 exit 1 |
|
15 fi |
|
16 |
|
17 echo -ne 'checking for man...' |
|
18 if which man >/dev/null; then |
|
19 echo -ne ' OK' |
|
20 echo |
|
21 else |
|
22 echo -ne ' FAILED' |
|
23 exit 1 |
|
24 fi |
|
25 |
|
26 echo -ne 'checking for cython...' |
|
27 if which cython >/dev/null; then |
|
28 echo -ne ' OK' |
|
29 echo |
|
30 else |
|
31 echo -ne ' FAILED' |
|
32 exit 1 |
|
33 fi |
|
34 |
|
35 echo -ne 'checking for gcc...' |
|
36 if which gcc >/dev/null; then |
|
37 echo -ne ' OK' |
|
38 echo |
|
39 else |
|
40 echo -ne ' FAILED' |
|
41 exit 1 |
|
42 fi |
|
43 |
700
|
44 echo |
|
45 echo -ne "configuring splicex: " |
|
46 echo |
|
47 echo -e " python version == $1" |
|
48 echo -e " interpreter path == $PYPATH" |
|
49 echo -e " compiler flags == gcc -I/usr/include/$1" |
697
|
50 sed -e s^PYTHON^"$1"^g src/make.in >Makefile |
|
51 sed -e s^PYTHON^"$PYPATH"^g src/splicex.py >build/splicex |
|
52 sed -e s^PYTHON^"$PYPATH"^g src/splicex-deshadow.py >build/splicex-deshadow |
|
53 echo |
700
|
54 echo -e 'splicex configured' |