-
Notifications
You must be signed in to change notification settings - Fork 0
/
compile-tdbcmysql.sh
executable file
·51 lines (41 loc) · 1.15 KB
/
compile-tdbcmysql.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#!/bin/bash -e
## module
MODULE=tdbcmysql
## load defaults
. ./common.sh
## check debug switch
if [ -n "$SW_DEBUG" ]; then
CONFIGURE_SWITCH+="--enable-symbols "
fi
## check 64bit platform
if [ "$BARCH" == "x86_64" ]; then
CONFIGURE_SWITCH+="--enable-64bit "
fi
## print
echo "** Compiling $MODULE $CONFIGURE_SWITCH"
## delete whole compile sources and start from new
if [ -n "$SW_CLEANUP" ]; then
echo -n "Deleting old sources ... "
rm -rf $COMPILEDIR/$MODULE
echo done
fi
## copy source to temp compile path
if [ ! -d $COMPILEDIR/$MODULE ] || [ -n "$SW_FORCECOPY" ]; then
echo -n "Copying new sources ... "
rsync -a --exclude "*/.git" --exclude "*fossil*" $EXTSRCDIR/$MODULE $COMPILEDIR/
rsync -a --exclude "*/.git" $EXTSRCDIR/tclconfig $COMPILEDIR/$MODULE/
echo done
fi
## change to compile dir
cd $COMPILEDIR/$MODULE
## configure and make
#autoconf
./configure --prefix=$INSTALLDIR --mandir=$iSHAREDIR --enable-threads $CONFIGURE_SWITCH
make
make install
## copy licence file
echo -n "Copying extras ... "
rsync -a $EXTSRCDIR/$MODULE/license.terms $iLICENCEDIR/$MODULE.licence
echo done
## fini
echo "** Finished compile-$MODULE."