-
Notifications
You must be signed in to change notification settings - Fork 9
/
compileSubModules.sh
59 lines (44 loc) · 1.44 KB
/
compileSubModules.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
#!/bin/sh
echo "-----Compiling Ph2_ACF-----"
echo "---------------------------"
# Default to Dev unless otherwise specified.
if [ ! $GIT_REF ];
then GIT_REF=Dev;
fi;
# clone Ph2ACF
#git clone --recurse-submodules --single-branch --branch $GIT_REF https://gitlab.cern.ch/cms_tk_ph2/Ph2_ACF.git Ph2_ACF
#export Ph2_ACF_VERSION="v4-14"
export Ph2_ACF_VERSION=$GIT_REF
mkdir Ph2_ACF/build/
cd Ph2_ACF
source ./setup.sh
cd build
cmake3 ..
make -j$(nproc)
cd ..
source ./setup.sh
echo "-----Ph2_ACF Setup Complete-----"
echo " "
echo "-----Settings up GUI Environment-----"
echo "-------------------------------------"
#export DATA_dir=$PWD/data/TestResults
#export GUI_dir=$PWD
if [ ! -d $PH2ACF_BASE_DIR ]; then
echo "Error: PH2ACF_BASE_DIR not found!"
fi;
if [ ! -d $DATA_dir ]; then
echo "DATA_dir not found! Making it now!"
mkdir -p -m777 $DATA_dir
fi;
if [ ! -d $PH2ACF_BASE_DIR/test ]; then
echo "Test directory not found! Making it now!"
mkdir -p -m777 $PH2ACF_BASE_DIR/test;
fi;
#export Ph2_ACF_VERSION=$(git describe --tags --abbrev=0)
cd $GUI_dir
#download and save arduino command line interface into the folder $PWD/bin
curl -fsSL https://raw.githubusercontent.com/arduino/arduino-cli/master/install.sh | sh
#download the compilation tool-kit for UNO board
$PWD/bin/arduino-cli core install arduino:avr
echo "-----GUI Environment Setup Complete-----"
echo " "