-
Notifications
You must be signed in to change notification settings - Fork 19
/
bootstrap.sh
executable file
·84 lines (73 loc) · 1.76 KB
/
bootstrap.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
#!/bin/bash
# get third party libs
git submodule init
git submodule update
# install eigen, keyutils, kerberos, sparsehash, gflags, glog
cd third_party
if [ ! -d "eigen_source" ]; then
sh get_eigen.sh
fi
# get keyutils library
KEYUTILS=keyutils-1.5.10
if [ ! -f $KEYUTILS.tar.bz2 ]; then
wget http://people.redhat.com/~dhowells/keyutils/$KEYUTILS.tar.bz2
fi
tar xjf $KEYUTILS.tar.bz2
mv $KEYUTILS keyutils
#rm $KEYUTILS.tar.bz2
cd keyutils
make -j 10
# get kerberos
cd ..
KRBLIB='krb5-1.15.2'
if [ ! -f $KRBLIB.tar.gz ]; then
wget https://kerberos.org/dist/krb5/1.15/$KRBLIB.tar.gz
fi
tar xzf $KRBLIB.tar.gz
#rm $KRBLIB.tar.gz
mv $KRBLIB kerberos
cd kerberos/src
./configure --disable-shared --enable-static
make -j 10
cd lib
for i in *.a; do
ar -x $i
done
ar -qc liball.a *.o # package all .a
find . -name \*.o -delete
cd ..
cd .. # back to third_party
#compile gflags
cd ../gflags
cmake ../gflags -DBUILD_SHARED_LIBS=OFF -DBUILD_STATIC_LIBS=ON -DBUILD_gflags_LIB=ON
make -j 10
#compile glog
cd ../glog
cmake ../glog
make -j 10
#untar and compile curl
cd ..
mkdir curl; cd curl
CURL_TAR=curl-7.60.0.tar.gz
wget https://curl.askapache.com/$CURL_TAR
tar -xvzf $CURL_TAR
mv curl-7.60.0 curl
cd curl
./buildconf
./configure --disable-shared --enable-static --disable-ldap --disable-sspi --without-librtmp --disable-ftp --disable-file --disable-dict --disable-telnet --disable-tftp --disable-rtsp --disable-pop3 --disable-imap --disable-smtp --disable-gopher --disable-smb --without-libidn
make -j 10
cd ../
#compile aws-sdk-cpp
cd ../aws-sdk-cpp
mkdir build
cd build
cmake .. -DBUILD_SHARED_LIBS=OFF -DBUILD_ONLY="s3;core"
make -j 10
cd ../.. # back to third_party
cd .. # back to top_dir
# main compilation
touch config.rpath
autoreconf
automake --add-missing
autoreconf
./configure