-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.sh
executable file
·85 lines (67 loc) · 3.38 KB
/
build.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
#! /bin/bash
workspace=$1
hostname=$(hostname)
branch=$3
echo "Directory: $workspace"
echo "Machine: $hostname"
echo "Branch name: $branch"
echo "Branch: $3"
# Make a directory in /tmp/openfpm_data
mkdir /tmp/openfpm_io
mv * .[^.]* /tmp/openfpm_io
mv /tmp/openfpm_io openfpm_io
git clone [email protected]:openfpm/openfpm_devices.git openfpm_devices
cd openfpm_devices
git checkout develop
cd ..
git clone [email protected]:openfpm/openfpm_data.git openfpm_data
cd openfpm_data
git checkout develop
cd ..
git clone [email protected]:openfpm/openfpm_pdata.git openfpm_pdata
cd openfpm_pdata
git checkout develop
cd ..
git clone [email protected]:openfpm/openfpm_vcluster.git openfpm_vcluster
cd openfpm_vcluster
git checkout develop
cd ..
cd "$1/openfpm_io"
#rm -rf $HOME/openfpm_dependencies/openfpm_io/$branch/MPI
#rm -rf $HOME/openfpm_dependencies/openfpm_io/$branch/HDF5
#rm -rf $HOME/openfpm_dependencies/openfpm_io/$branch/BOOST
if [ x"$hostname" == x"cifarm-centos-node.mpi-cbg.de" ]; then
source /opt/rh/devtoolset-7/enable
./install_MPI.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
export PATH="$HOME/openfpm_dependencies/openfpm_io/$branch/MPI/bin/:$PATH"
./install_BOOST.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_HDF5.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_LIBHILBERT.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_VCDEVEL.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4 gcc g++
fi
if [ x"$hostname" == x"cifarm-ubuntu-node" ]; then
./install_MPI.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
export PATH="/opt/bin:$HOME/openfpm_dependencies/openfpm_io/$branch/MPI/bin/:$PATH"
./install_BOOST.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_HDF5.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_LIBHILBERT.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_VCDEVEL.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4 gcc g++
fi
if [ x"$hostname" == x"cifarm-mac-node.mpi-cbg.de" ]; then
export PATH="/usr/local/bin:$PATH"
./install_MPI.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
export PATH="$HOME/openfpm_dependencies/openfpm_io/$branch/MPI/bin/:$PATH"
./install_BOOST.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_HDF5.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_LIBHILBERT.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4
./install_VCDEVEL.sh $HOME/openfpm_dependencies/openfpm_io/$branch/ 4 gcc g++
fi
# Go in the right branch
echo "Compiling on $2"
sh ./autogen.sh
if [ x"$hostname" == x"cifarm-mac-node.mpi-cbg.de" ]; then
sh ./configure CXX=mpic++ --with-vcdevel=$HOME/openfpm_dependencies/openfpm_io/$branch/VCDEVEL --with-libhilbert=$HOME/openfpm_dependencies/openfpm_io/$branch/LIBHILBERT --with-hdf5=$HOME/openfpm_dependencies/openfpm_io/$branch/HDF5 --with-boost=$HOME/openfpm_dependencies/openfpm_io/$branch/BOOST --with-pdata=../../openfpm_pdata/ --enable-cuda-on-cpu
else
sh ./configure CXX=mpic++ --with-vcdevel=$HOME/openfpm_dependencies/openfpm_io/$branch/VCDEVEL --with-libhilbert=$HOME/openfpm_dependencies/openfpm_io/$branch/LIBHILBERT --with-hdf5=$HOME/openfpm_dependencies/openfpm_io/$branch/HDF5 --with-boost=$HOME/openfpm_dependencies/openfpm_io/$branch/BOOST --with-pdata=../../openfpm_pdata/ --with-cuda-on-backend=OpenMP
fi
make VERBOSE=1 -j 4