-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathinstall.sh
executable file
·55 lines (45 loc) · 1.05 KB
/
install.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
# install g++ openmpi
sudo apt-get update
sudo apt-get -y install libopenmpi-dev
sudo apt-get -y install g++
sudo apt-get -y install openmpi-bin
sudo apt-get -y install make
sudo apt-get -y install cmake
#install openblas
sudo apt-get -y install libopenblas-dev
#install lapack
sudo apt-get -y install liblapack-dev
#install arpack
sudo apt-get -y install libarpack-dev
# install armadillo
if [ ! -f armadillo-8.100.1.tar.xz]
then
wget http://sourceforge.net/projects/arma/files/armadillo-8.100.1.tar.xz
fi
tar xvf armadillo-8.100.1.tar.xz
cd armadillo-8.100.1
cmake .
make
sudo make install
cd ..
rm armadillo-8.100.1.tar.xz
#fetch gflags
git clone https://github.com/gflags/gflags.git
mkdir build
cd build
# generate splitdata
g++ -std=c++11 -o splitdata ../data/split_data.c
# make project
cmake ..
make
cd ..
#distributed setting.
if [ -f Firstkey.pem ]
then
# transfer key
mv Firstkey.pem ~/.ssh/id_rsa
chmod 400 ~/.ssh/id_rsa
#disable key checking.
printf '%s\n %s' 'Host *' 'StrictHostKeyChecking no' >> ~/.ssh/config
chmod 400 ~/.ssh/config
fi